Python math.cosh() - Hyperbolic Cosine


Python math.cosh()

math.cosh(x) function returns the hyperbolic cosine of x.

cosh(x) = (e^2x + 1)/(2*e^x)

Syntax

The syntax to call cosh() function is

math.cosh(x)

where

ParameterRequiredDescription
xYesA numeric value.

Example

In the following example, we find the hyperbolic cosine of 5, using cosh() function of math module.

Python Program

import math

x = 5
result = math.cosh(x)
print('cosh(x) :', result)

Output

cosh(x) : 74.20994852478785

Summary

In this Python Examples tutorial, we learned the syntax of, and examples for math.cosh() function.