Rogue Wave banner
Previous fileTop of DocumentContentsIndexNext file

10.6 atan() and atan2()

PrototypesHeader File(s)
template <class T>
RWMathVec<T>
atan(const RWMathVec<T>&)
<rw/math/mathvec.h>
RWMathVec<T>
atan2(const RWMathVec<T>&
const RWMathVec<T>&)
<rw/math/mathvec.h>
RWGenMat<T>
atan(const RWGenMat<T>&)
<rw/math/genmat.h>
RWGenMat<T>
atan2(const RWGenMat<T>&,
const RWGenMat<T>&)
<rw/math/genmat.h>
RWMathArray<T>
atan(const RWMathArray<T>&)
<rw/math/mtharray.h>
RWMathArray<T>
atan2(const RWMathArray<T>&,
const RWMathArray<T>&)
<rw/math/mtharray.h>

10.6.1 Description

The function atan() takes x and returns y of arc tangents (in radians), such that yi = tan-1xi, where -/2 < yi /2.

The function atan2() takes two arguments and returns quadrant correct arc tangents z (in radians), such that zi = tan-1 ( xi / yi ). For each element i, the expression atan2(xi, yi) is mathematically equivalent to:

At least one of the arguments xi or yi must be nonzero.


Previous fileTop of DocumentContentsIndexNext file

©Copyright 1999, Rogue Wave Software, Inc.
Contact Rogue Wave about documentation or support issues.