From Clomosy Docs

Revision as of 10:23, 7 October 2024 by ClomosyManager (talk | contribs)

Calculates the arctangent of a given number.
In Clomosy code, ArcTan returns the arctangent of X.
X is a real-type expression that gives an angle in radians.

Example
TRObject Syntax

var
   floatValue : single;
 
 const
   PI = 3.14;
 
 {
   // The ArcTan of PI/2 should give 1.0
   floatValue = ArcTan(PI/2);
   ShowMessage('ArcTan of PI/2 = '+FloatToStr(floatValue));
 }

Base Syntax

 var
   floatValue : single;
 
 const
   PI = 3.14;
 
 {
   // The ArcTan of PI/2 should give 1.0
   floatValue = ArcTan(PI/2);
   ShowMessage('ArcTan of PI/2 = '+FloatToStr(floatValue));
 }

Output:

See Also