Next: , Previous: CMPLX, Up: Intrinsic Procedures


7.29 COS — Cosine function

Description:
COS(X) computes the cosine of X.
Option:
f95, gnu
Class:
elemental function
Syntax:
X = COS(X)
Arguments:

X The type shall be REAL(*) or COMPLEX(*).

Return value:
The return value has same type and kind than X.
Example:
          program test_cos
            real :: x = 0.0
            x = cos(x)
          end program test_cos
     

Specific names:

Name Argument Return type Option
DCOS(X) REAL(8) X REAL(8) f95, gnu
CCOS(X) COMPLEX(4) X COMPLEX(4) f95, gnu
ZCOS(X) COMPLEX(8) X COMPLEX(8) f95, gnu
CDCOS(X) COMPLEX(8) X COMPLEX(8) f95, gnu