[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack do
From: |
Michael Godfrey |
Subject: |
[Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation |
Date: |
Fri, 28 Sep 2012 20:34:50 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20100101 Firefox/15.0.1 |
Follow-up Comment #15, bug #37379 (project octave):
Well, the code did not apparently make it into
the comment below. In Any case, this code only
handles the exceptions for scalar inputs.
function res = atan2(y, x)
% Test for special cases and quadrants.
if(x == 0)
if(y > 0)
res = pi/2;
elseif (y < 0)
res = -pi/2;
else
res = NaN;
endif
return;
endif
res = atan(y/x);
if(x < 0)
if(y >= 0)
res = res + pi;
else
res = res - pi;
endif
endif
return;
endfunction
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?37379>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, (continued)
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Jordi GutiƩrrez Hermoso, 2012/09/26
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Michael Godfrey, 2012/09/26
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Rik, 2012/09/26
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Michael Godfrey, 2012/09/26
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Michael Godfrey, 2012/09/26
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Rik, 2012/09/26
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Rik, 2012/09/26
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Michael Godfrey, 2012/09/26
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Michael Godfrey, 2012/09/27
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Michael Godfrey, 2012/09/28
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation,
Michael Godfrey <=
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Rik, 2012/09/28
- [Octave-bug-tracker] [bug #37379] atan2 and other trig functions lack documentation, Michael Godfrey, 2012/09/28