MySQL ATAN() Function

In MySQL, the ATAN() function returns the arc tangent of the specified number.

ATAN() Syntax

Here is the syntax of MySQL ATAN() function:

ATAN(number)
ATAN(x, y)

Parameters

number
Required. The value whose arc tangent is to be returned.
x, y
Required. The two values.

Return value

In MySQL, the ATAN() function returns the arc tangent of the specified number.

If any parameter is NULL, the ATAN() function will return NULL.

ATAN() Examples

SELECT
    ATAN(2.5),
    ATAN(0.2),
    ATAN(-0.5),
    ATAN(-0.2),
    ATAN(-0.9, 2),
    ATAN(PI(), 2),
    ATAN(NULL)\G

output

*************************** 1\. row ***************************
    ATAN(2.5): 1.1902899496825317
    ATAN(0.2): 0.19739555984988078
   ATAN(-0.5): -0.4636476090008061
   ATAN(-0.2): -0.19739555984988078
ATAN(-0.9, 2): -0.4228539261329407
ATAN(PI(), 2): 1.0038848218538872
   ATAN(NULL): NULL