09.12.2012 Views

Basic Characteristics RAPID

Basic Characteristics RAPID

Basic Characteristics RAPID

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

ATan2 Calculates the arc tangent2 value<br />

Example<br />

ATan2 (Arc Tangent2) is used to calculate the arc tangent2 value.<br />

VAR num angle;<br />

VAR num x_value;<br />

VAR num y_value;<br />

.<br />

.<br />

angle := ATan2(y_value, x_value);<br />

Return value Data type: num<br />

Arguments<br />

Syntax<br />

The arc tangent value, expressed in degrees, range [-180, 180].<br />

The value will be equal to ATan(y/x), but in the range [-180, 180], since the function<br />

uses the sign of both arguments to determine the quadrant of the return value.<br />

ATan2 (Y X)<br />

Y Data type: num<br />

The numerator argument value.<br />

X Data type: num<br />

The denominator argument value.<br />

ATan2’(’<br />

[Y ’:=’] ’,’<br />

[X ’:=’] <br />

’)’<br />

A function with a return value of the data type num.<br />

<strong>RAPID</strong> Reference Manual 9-ATan2-1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!