float cos ( float $arg )
cos() returns the cosine of $arg. The $arg is in radians.
※ available F/W version : all
Returns the cosine of $arg
<?php
$rad = 1.0;
$val1 = cos($rad);
$val2 = acos($val1);
echo "cos($rad) = $val1\r\n"; // OUTPUT: cos(1) = 0.54030230586814
echo "acos($val1) = $val2\r\n"; // OUTPUT: acos(0.54030230586814) = 1
?>
This function is identical to the PHP group’s cos() function.