Home >>Java Math Methods >Java Math.cosh() method
The java.lang. Math.cosh() is used to return a value of the hyperbolic cosine. You may define the hyperbolic cosine of any value x as (ex + e -x)/2, where e is the number of an Euler.
public static double cosh(double x)
x = This parameter is used to the number whose hyperbolic cosine is to be returned.
It is used to returns the hyperbolic cosine of x.
public class MyClass
{
public static void main(String[] args)
{
double x = 20.0;
System.out.println(Math.cosh(x));
}
}
public class MyClass
{
public static void main(String[] args)
{
double x = 1.0;
System.out.println(Math.cosh(x));
}
}