Export (0) Print
Expand All
Expand Minimize

ATAN2 function

ATAN2 function

This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release.

See also

Returns the angle between the vector represented by x,y and the direction of the x-axis. The result is a number in the current unit of measure for angles.

Syntax

ATAN2(y,x)

Remarks

The arctangent is the angle measured counterclockwise from the positive x-axis to a line that intersects the origin (0,0) and the point represented by x and y. In Microsoft Visio, ATAN2(0,0) returns 0. To force the result of ATAN2 into a different angular measurement, use the DEG or RAD function.

The ATAN2 function is the antifunction of the TAN function. The ATAN2 function returns the angle whose angle is equal to y divided by x. If ATAN2(y,x) represents an angle in a right triangle, then y is the "opposite side" and x is the "adjacent side," so the function could be written as ATAN2(opposite,adjacent).

Example 1

ATAN2(1.25,2.25)

Returns 29.0456 degrees.

Example 2

ATAN2(1,SQRT(3))

Returns 30 degrees.

Example 3

ATAN2(1,1)

Returns 45 degrees.

Show:
© 2015 Microsoft