GNU Info

Info Node: (g77-295.info)Abs Intrinsic

(g77-295.info)Abs Intrinsic


Next: Access Intrinsic Prev: Abort Intrinsic Up: Table of Intrinsic Functions
Enter node , (file) or (file)node

Abs Intrinsic
.............

     Abs(A)

Abs: `INTEGER' or `REAL' function.  The exact type depends on that of
argument A--if A is `COMPLEX', this function's type is `REAL' with the
same `KIND=' value as the type of A.  Otherwise, this function's type
is the same as that of A.

A: `INTEGER', `REAL', or `COMPLEX'; scalar; INTENT(IN).

Intrinsic groups: (standard FORTRAN 77).

Description:

   Returns the absolute value of A.

   If A is type `COMPLEX', the absolute value is computed as:

     SQRT(REALPART(A)**2, IMAGPART(A)**2)

Otherwise, it is computed by negating the A if it is negative, or
returning A.

   Note: Sign Intrinsic, for how to explicitly compute the positive
or negative form of the absolute value of an expression.


automatically generated by info2www version 1.2.2.9