Returns the arctangent (in radians) of a number.
Math
atan(x)
x
The atan method returns a numeric value between -pi/2 and pi/2 radians.
atan is a static method of Math. As a result, you always use it as Math.atan(), rather than as a method of a Math object you create.
The following function returns the arctangent of the variable x:
If you pass getAtan the value 1, it returns 0.7853981633974483; if you pass it the value .5, it returns 0.4636476090008061.
Math.acos, Math.asin, Math.atan2, Math.cos, Math.sin, Math.tan