PHP cosh() Function
Example
Return the hyperbolic cosine of different numbers:
"); echo(cosh(-3) . ""); echo(cosh(0) . "
"); echo(cosh(M_PI) . "
"); echo(cosh(2*M_PI)); ?>
Run Example »
Definition and Usage
The cosh() function returns the hyperbolic cosine of a number, defined as ((exp(number) + exp(-number))/2).
Syntax
cosh(
number
);
| Parameters | Description |
|---|---|
| number | Required. Specifies a number. |
Technical Details
| Return Value: | number The hyperbolic cosine of. |
|---|---|
| Return Type: | Float |
| PHP Version: | 4.1+ |
PHP Math Reference Manual