PHP tanh() 函數(shù)
PHP tanh() 函數(shù)
實例
返回不同數(shù)的雙曲正切:
<?php
echo(tanh(M_PI_4) . "<br>");
echo(tanh(0.50) . "<br>");
echo(tanh(-0.50) . "<br>");
echo(tanh(5) . "<br>");
echo(tanh(10) . "<br>");
echo(tanh(-5) . "<br>");
echo(tanh(-10));
?>
echo(tanh(M_PI_4) . "<br>");
echo(tanh(0.50) . "<br>");
echo(tanh(-0.50) . "<br>");
echo(tanh(5) . "<br>");
echo(tanh(10) . "<br>");
echo(tanh(-5) . "<br>");
echo(tanh(-10));
?>
運行實例 ?
定義和用法
tanh() 函數(shù)返回一個數(shù)的雙曲正切,定義為 sinh(x)/cosh(x)。
語法
tanh(number);
參數(shù) | 描述 |
---|---|
number | 必需。規(guī)定一個數(shù)。 |
技術(shù)細節(jié)
返回值: | number 的雙曲正切。 |
---|---|
返回類型: | Float |
PHP 版本: | 4.1+ |

相關(guān)文章
- PHP 教程
- PHP echo 和 print 語句
- PHP 數(shù)據(jù)類型
- PHP Switch 語句
- PHP 超級全局變量
- PHP $_GET 變量
- PHP array_change_key_case() 函數(shù)
- PHP array_diff_uassoc() 函數(shù)
- PHP array_diff_ukey() 函數(shù)
- PHP array_fill() 函數(shù)
- PHP array_key_last() 函數(shù)
- PHP array_merge_recursive() 函數(shù)
- PHP array_search() 函數(shù)
- PHP arsort() 函數(shù)
- PHP in_array() 函數(shù)
- PHP natsort() 函數(shù)
- PHP pos() 函數(shù)
- PHP sort() 函數(shù)
- PHP cURL 函數(shù)
- PHP 5 Directory 函數(shù)