Syntax math.atan(num) The atan() method calculates the arctangent of a number.The return value is a numeric value between -PI/2 and PI/2 radians. This example calculates the arctangent of the input number. Enter Number: The arctan is: