Type Function Library math.* Return value Number Revision Release 2024.3703 Keywords tan, tangent See also math.atan()
math.atan2()
Returns the tangent of x
(the angle in radians).
print(math.tan(-math.pi/2)) ---> a very large negative number print(math.tan(math.pi/4)) ---> 1 print(math.tan(math.pi/2)) ---> a very large number