Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

PHP atan() Function

PHP atan() Function

PHP Math Reference Manual PHP Math Reference Manual

Example

Return the arc tangent of different numbers via atan():

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

Run Example »


Definition and Usage

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


Syntax

atan(

arg

);

Parameters Description
arg Required. Specifies the argument to handle.

Technical Details

Return Value: arg The arc tangent of, in radians.
Return Type: Float
PHP Version: 4+

PHP Math Reference Manual PHP Math Reference Manual