Function Cos(x)

Cos

Cos(
   x             ! (input) numerical expression
   )

Arguments

x

A scalar numerical expression in radians.

Return Value

The Cos function returns the cosine of x in the range \(-1\) to 1.

Graph

../../_images/cos.png

Example

_p_returnM1 := Cos(-p_pi); ! cos(-pi) = -1
_p_returnZ  := Cos( 0   ); ! cos( 0 ) =  1
_p_returnP1 := Cos( p_pi); ! cos( pi) = -1

Note

The function Cos can be used in constraints of nonlinear mathematical programs.

See also