atan2(3I)

ATAN2, DATAN2, QATAN2, ATAN2D, DATAN2D, QATAN2D - Computes arc tangent (inverse tangent) for two arguments

Showing IRIX 6.5.30 (default release). Last changed in IRIX 6.5.19.

NAME
     ATAN2, DATAN2, QATAN2, ATAN2D, DATAN2D, QATAN2D - Computes arc tangent
     (inverse tangent) for two arguments

SYNOPSIS
     ATAN2 ([Y=]y,[X=]x)
     DATAN2 ([Y=]y,[X=]x)
     QATAN2 ([Y=]y,[X=]x)

     ATAN2D ([Y=]y,[X=]x)
     DATAN2D ([Y=]y,[X=]x)
     QATAN2D ([Y=]y,[X=]x)

STANDARDS
     Fortran

     Fortran extensions:  QATAN2, ATAN2D, DATAN2D, QATAN2D

DESCRIPTION
     ATAN2, DATAN2, and QATAN2 return the arc tangent, for two arguments,
     in radians.  ATAN2D, DATAN2D, and QATAN2D return the arc tangent, for
     two arguments, in degrees.  These intrinsics accept the following
     arguments:

     y         Must be type real.  For DATAN2 and DATAN2D, must be of type
               double precision.  For QATAN2 and QATAN2D, must be of type
               quad precision.  See the RETURN VALUES section for
               information on input data types and return values.

               The terms single precision, double precision, and quad
               precision differ depending on your platform.  For
               platform-specific information, see the TERMINOLOGY section
               of the INTRO_INTRIN(3I) man page.

               For ATAN2, DATAN2, and QATAN2, the following rules apply:

               * If y is positive, the result is positive.

               * If y is negative, the result is negative.

               * If y is positive or negative zero, and if x is positive,
                 the result is positive or negative zero.

               * If y is positive or negative zero, and if x is negative,
                 the result is positive or negative pi.

               * If y is zero, x cannot also be zero.

               For ATAN2D, DATAN2D, and QATAN2D, the following rules apply:

               * If y is positive, the result is positive.

               * If y is negative, the result is negative.

               * If y is zero, and if x is positive, the result is zero.

               * If y is zero, and if x is negative, the result is 180.0.

               * If y is zero, x cannot also be zero.

     x         Must be of type real.  For DATAN2 and DATAN2D, must be of
               type double-precision.  For QATAN2 and QATAN2D, must be of
               type quad-precision.  See the RETURN VALUES section for
               information on input data types and return values.

               The terms single precision, double precision, and quad
               precision differ depending on your platform.  For
               platform-specific information, see the TERMINOLOGY section
               of the INTRO_INTRIN(3I) man page.

               For ATAN2, DATAN2, and QATAN2, the following rules apply:

               * If x is zero, y cannot also be zero.

               * If x is zero, the value of the absolute value of the
                 result is pi/2.

               For ATAN2D, DATAN2D, and QATAN2D, the following rules apply:

               * If x is zero, y cannot also be zero.

               * If x is zero, the absolute value of the result is 90.0.

     ATAN2 and ATAN2D are generic function names; the others are specifics.
     These are elemental intrinsic functions.

     These functions evaluate y = arctan(y/x).

     The result range, in radians, for ATAN2, DATAN2, and QATAN2 is
     -pi <= result <= pi.

     The result range, in degrees, for ATAN2D, DATAN2D, and QATAN2D is
     -180 <= result <= 180.

NOTES
     The ATAN2 and DATAN2 intrinsic function names can be passed as
     arguments; the others cannot.

RETURN VALUES
     ATAN2 and ATAN2D return the real arc tangent of the quotient of their
     real arguments.

     DATAN2 and DATAN2D return the double-precision arc tangent of the
     quotient of their double-precision arguments.

     QATAN2 and QATAN2D return the quad-precision arc tangent of the
     quotient of their quad-precision arguments.