<?Php
echo acosh(6); // Output 2.4778887302885
echo "<br>";
echo acosh(2.5); // Output 1.5667992369724
echo "<br>";
echo acosh(0); // Output NAN
echo "<br>";
echo acosh(2); // Output 1.3169578969248
echo "<br>";
echo acosh(-2.5); // Output NAN
echo "<br>";
echo acosh(-4); // Output NAN
?>
Syntax
acosh(float X);
X is the input
acosh returns an EDOM error if called with an argument less than 1.0
The acosh() function can be used to find the inverse hyperbolic cosine for values greater than or equal to 1:
$value = 10;
$result = acosh($value);
echo "The acosh of $value is: " . $result;
// Outputs: The acosh of 10 is: 2.99322284612638
You can use acosh() in more complex mathematical expressions:
$value = 20;
$result = pow(acosh($value), 2) + sqrt($value);
echo $result;
Author
🎥 Join me live on YouTubePassionate about coding and teaching, I publish practical tutorials on PHP, Python, JavaScript, SQL, and web development. My goal is to make learning simple, engaging, and project‑oriented with real examples and source code.