function tan
Returns the trigonometric tangent of its argument. The returned value will be real, complex, or a matrix, depending on the argument. By default, the argument is in radians. This can be changed by specifying the switch /deg.
Syntax
result = tan(angle [, /deg])
Arguments
angle: | a number (integer, real, complex) or a matrix, specifying the angle for which the tangent is to be calculated. If X is a matrix, a matrix of the same size is returned where each element represents the result of the operation. |
Switches
/deg: | The argument is in degrees |
Examples
To find the tangent of the angle 45 degrees, type:
print tan(45, /deg)
See also
function sin
function cos
category index: trigonometry