tan()

Returns the tangent of the given angle in radians.

Syntax

tan(angle)

Parameters

Parameter Type Description
angle Number Angle in radians to compute tangent.

Return Value

Examples

tan(0);        // returns 0
tan(pi()/4);   // returns 1
tan(pi()/2);   // returns a large value (undefined at exact pi/2)

See also

pi
sin
asin
cos
acos
tan
atan
atan2
rad2deg
deg2rad