Latest web development tutorials

PHP asin () function

PHP Math Reference PHP Math Reference

Examples

Returns the arcsine of different numbers:

<?php
echo(asin(0.64) . "<br>");
echo(asin(-0.4) . "<br>");
echo(asin(0) . "<br>");
echo(asin(-1) . "<br>");
echo(asin(1) . "<br>");
echo(asin(2));
?>

Running instance »

Definition and Usage

asin () function returns the arc sine of a number.

Tip: asin (1) returns the value Pi / 2 in.


grammar

asin( number );

参数 描述
number 必需。规定一个数,范围在 -1 到 1 之间。

technical details

return value: arc sine of number. If the number is not in the range between -1 and 1, then return to NAN.
Return type: Float
PHP version: 4+


PHP Math Reference PHP Math Reference