bugl
bugl
HomeLearnPatternsPathsSearchPremium
HomeLearnPatternsPaths

Loading lesson path

Learn/Java/Java Reference
Java•Java Reference

Java Math cosh() Method

❮ Math Methods

Example

System.out.println(Math.cosh(3));
System.out.println(Math.cosh(-3));
System.out.println(Math.cosh(0));
System.out.println(Math.cosh(1));

Definition and Usage

The cosh() method returns the hyperbolic cosine of a number.

The hyperbolic cosine is equivalent to (Math.exp(number) + Math.exp(-number)) / 2 .

Syntax

public static double cosh(double
number )

Parameter Values

ParameterDescription
numberRequired. A number to find the hyperbolic cosine of.

Technical Details

Returns:A double value representing the hyperbolic cosine of a number.
Java version:1.5+

Previous

Java Math cos() Method

Next

Java Math decrementExact() Method