octave-patch-tracker
[Top][All Lists]
Advanced

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

[Octave-patch-tracker] [patch #8827] mapping package: new functions wrap


From: Philip Nienhuis
Subject: [Octave-patch-tracker] [patch #8827] mapping package: new functions wrapTo 360, 2Pi, 180, Pi
Date: Mon, 21 Dec 2015 21:54:45 +0000
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:41.0) Gecko/20100101 Firefox/41.0 SeaMonkey/2.38

Follow-up Comment #6, patch #8827 (project octave):

Thanks for the patches.

I now get:

>> wrapToPi ([-pi, -3*pi])
ans =
  -3.1416  -3.1416


which is still incorrect, expected answer = [ -3.1416  3.1416 ]
wrapTo2Pi.m has the same issue.


>> wrapTo360 ([0, 180, 360, -1, 361])
error: 'sgn' undefined near line 36 column 11
error: called from
    wrapTo360 at line 36 column 9


Did you use the "sgn" function from Matlab File Exchange?
http://nl.mathworks.com/matlabcentral/fileexchange/23571-short-time-energy-and-zero-crossing-rate/content/stezcr/sgn.m
=> we cannot use functions from there as the terms of use forbid usage with
any other program than Matlab.


>> wrapTo180 ([0, 180, -180, -1, 181])
ans =
     0   180  -180    -1  -179


That one looks good.


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/patch/?8827>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

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