COS() Function - Cosine

Syntax

COS(num{,precis}{,ERR=lineref})

Description

The COS() function returns the cosine of the specified value. The result will be in the range -1 to 1.

Parameter

Description

num

An argument expressed in radians of any value; however, values over 10^16 lose accuracy.

precis

Numeric precision, an integer in the range of 1 to 16 (default is 6). This represents the number of decimal places desired in the result.

Although PRO/5 provides 16-digit decimal arithmetic, it can be costly to compute a 16-digit precision cosine.

ERR=lineref

Branch to be taken if an error occurs during execution.

Examples

1000 LET A=COS(3.14159)
2000 LET A=COS(B,16); REM - MAXIMUM PRECISION

See Also

Functions - Alphabetical Listing