[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Why is different ^ and .^?
From: |
Ted Harding |
Subject: |
Re: Why is different ^ and .^? |
Date: |
Mon, 23 May 2005 23:29:37 +0100 (BST) |
On 23-May-05 Javier Arantegui Jimenez wrote:
> Mike Miller said:
>> a^2 means a*a
>> a.^2 means "square every element of a"
>>
>> a^2 therefore requires that 'a' be a square matrix or scalar.
>> a.^2 does not require that 'a' have any particular dimensions
>
> OK. I understand it. But, could Octave be smart enough to
> distinguish between those cases? I think that other programs,
> like Euler, don't need to do this distinction.
"Smart enough" is possible in cases where one interpretation
is impossible (e.g. A is not a square matrix, so "A*A" is not
possible). But if A is square, then how can octave be smart
enough to know whether you mean "A*A" or "The matrixx of
squared elements of A"? Clairvoyant is hyper-smart!
Best wishes,
Ted.
--------------------------------------------------------------------
E-Mail: (Ted Harding) <address@hidden>
Fax-to-email: +44 (0)870 094 0861
Date: 23-May-05 Time: 23:29:25
------------------------------ XFMail ------------------------------
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------