help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Index expressions: .* vs &


From: c.
Subject: Re: Index expressions: .* vs &
Date: Fri, 6 Aug 2010 10:47:38 +0200


On 6 Aug 2010, at 10:43, Mike B. wrote:

Thanks Carlo.

I wasn't aware there is a difference. Thought that octave treated a real-type zero as a boolean.

If you want you can force that behaviour by casting the result of your product to logical:

z1 = logical ((a > 0) .* (a > 1));

c.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]