Purpose:    Calculates the trigonometric tangent of a numeric value.

Format:     TAN( value )

Notes:     value  must be a constant or a numeric variable name.  value  is an angle specified in radians.  To convert radians to degrees,  multiply by  180 / pi .  To convert degrees to radians,  multiply by   pi / 180 . (See the discussion of radians under the  COS  statement.)


# This script will calculate the tangent
# of a user inputted angle in degrees.

input deg " Enter Angle in degrees"

# Convert degrees to radians
rad = deg * 0.017453

# Perform Tangent Calculation
tangent = tan(rad)

# Print out results

print "The Tangent of " deg " is " tangent


See Also:  COS    SIN   ATAN