How to use atan2 in PHP
This article describe about atan2() Function in PHP.
atan2() Function
The angle theta of an (x,y) point as a numeric value between -PI and PI radians return by the atan2() function.
Syntax
Parameter |
Description |
a |
Required. A number |
Example
<html>
<body>
<?php
echo(atan2(0.60,0.60) . "<br />");
echo(atan2(-0.60,-0.60) . "<br />");
echo(atan2(6,6) . "<br />");
echo(atan2(12,24) . "<br />");
echo(atan2(-6,-6) . "<br />");
echo(atan2(-12,12))
?>
</body>
</html> |
Output

You may also want to read these related articles Click here
Ask Your Question
Got a programming related question? You may want to post your question here
Programming Answers here