help-octave
[Top][All Lists]
Advanced

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

Re: detecting a sign change in a vector


From: Jordi Gutiérrez Hermoso
Subject: Re: detecting a sign change in a vector
Date: Thu, 31 Jan 2013 13:41:41 -0500

On 31 January 2013 12:52, dirac <address@hidden> wrote:
> This might be trivial but I am stuck on this.
> I have a vector, V, which basically contains the values of a cos/sin
> function. The signs of the elements in the vector change from + to -
> occasionally.

idx_changes = diff(sign(vector)) != 0)

HTH,
- Jordi G. H.


reply via email to

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