ArcTan2

From SCAR Divi Manual
Jump to: navigation, search

Definition

function ArcTan2(Y, X: Extended): Extended;

Availability

SCAR Divi 3.00 > Current

Description

This function calculates the inverse tangent angle and quadrant of a value. ArcTan2(Y, X) produces the same result as ArcTan(Y/X). The value of X can't be 0 and the function returns an angle in the range from -Pi to Pi radians.

Example

begin
  WriteLn(ArcTan2(1, 1));
end.

Output:

0,785398163397448

See Also