atan2

atan2()

Overview

The atan2() function returns the angle (in radians) between the positive x-axis and the ray from (0,0) to the specified point (x,y).

Return Type

Syntax

<variable> = atan2(<y-axis>, <x-axis>);
(or)
<variable> = <y-axis>.atan2(<x-axis>);
ParameterData typeDescription
<variable>NUMBERVariable which will contain the returned value.
<y-axis>NUMBERThe y-axis value of the point whose atan2 value needs to be returned.
<x-axis>NUMBERThe x-axis value of the point whose atan2 value needs to be returned.

Examples

number = 1;
atan2Value = number.atan2(2);       // returns 0.4636476090008061

Share this post : FacebookTwitter

Still can't find what you're looking for?

Write to us: support@zohodeluge.com