atanh()

Dijok243's avatar
Published Aug 9, 2023
Contribute to Docs

The atanh() calculates the inverse hyperbolic tangent of a given number and returns a float.

Syntax

atanh($inputValue)
  • The function atanh() only takes one parameter, $inputValue, and returns a floating point number. The passed value must be a numerical value between -1 and 1 (not inclusive).

Example

The example below demonstrates a basic implementation of atanh().

<?php
echo (atanh(0.5));
?>

The result will be:

0.54930614433405

Codebyte Example

The example below is runnable and demonstrates how to use the function atanh() with a variable, to store and display the result.

Code
Output
Loading...

All contributors

Contribute to Docs

Learn PHP on Codecademy