Latest web development tutorials

PHP atan () function

PHP Math Reference PHP Math Reference

Examples

By atan () function returns the arctangent of different numbers:

<?php
echo(atan(0.50) . "<br>");
echo(atan(-0.50) . "<br>");
echo(atan(5) . "<br>");
echo(atan(-5) . "<br>");
echo(atan(100) . "<br>");
echo(atan(-100));
?>

Running instance »

Definition and Usage

atan () function returns the arc tangent of arg, the return value is a number between -Pi / 2 and Pi / 2 between.


grammar

atan( arg );

参数 描述
arg 必需。规定要处理的参数。

technical details

return value: arc tangent of arg in radians.
Return type: Float
PHP version: 4+


PHP Math Reference PHP Math Reference