How to use tan in PHP

This article describe about tan() Function in PHP.
  • 1303

tan() Function

This function return a number that show the tangent of angle.

Syntax

tan(x)

 

Parameter Description
x Required. A number

Example

<html>
<body>
<?php
echo(tan(M_PI_4) . "<br />");
echo(tan(0.70) . "<br />");
echo(tan(-0.70) . "<br />");
echo(tan(7) . "<br />");
echo(tan(14) . "<br />");
echo(tan(-7) . "<br />");
echo(tan(-14))
?>
</body>
</html>

 

Output


tan-php.jpg

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

Categories

More Articles

© 2019 DotNetHeaven. All rights reserved.