日本語 English

Finding the Four-Quadrant Angle with ATAN2

What Is ATAN2?

ATAN2 is a function that finds an angle from X and Y coordinates.
Unlike the normal ATAN, it can determine all four quadrants, so it is used for
- vector direction calculation
- robot control
- servo position calculation
- AGV heading calculation
and more.

ATAN2 four-quadrant angle
ATAN2 four-quadrant angle

Differences between ATAN and ATAN2

FunctionCharacteristics
ATANFinds the angle from Y/X
ATAN2Finds the angle taking the four quadrants into account

Symbols

atan2Func
Input
Y
Y coordinate
X
X coordinate
In-out
out
Result

Download

Comments