Java Math.sinh() method returns hyperbolic sine of the given value. This method accepts double type value as an argument and returns the hyperbolic sine of this value as a result. Hyperbolic sine of a value x is defined as (ex – e-x)/2, where e is the Euler’s number whose value is 2.718281828459045.
public class JavaExample
{
public static void main(String[] args)
{
double a = 1;
System.out.println(Math.sinh(a));
}
}
Output:
1.1752011936438014
Syntax of Math.sinh() method
Math.sinh(90); //returns 6.102016471589204E38
sinh() Description
public static double sinh(double a): It returns hyperbolic sine of the given value(argument) a.
sinh() Parameters
- a: A double value whose hyperbolic sine is to be determined.
sinh() Return Value
- Returns hyperbolic sine of argument
a. - If the argument is NaN (Not a number), then it returns NaN.
- If the argument is infinity, then it returns infinity with the same sign.
- If the argument is zero, then it returns zero with the same sign.
Example 1
public class JavaExample
{
public static void main(String[] args)
{
double a1 = 1.0;
double a2 = 0;
double a3 = -1.0;
//hyperbolic sine of different double values.
System.out.println(Math.sinh(a1));
System.out.println(Math.sinh(a2));
System.out.println(Math.sinh(a3));
}
}
Output:

Example 2
public class JavaExample
{
public static void main(String[] args)
{
double a1 = Double.MAX_VALUE;
double a2 = Double.MIN_VALUE;
double a3 = 0.0/0; //NaN
System.out.println(Math.sinh(a1));
System.out.println(Math.sinh(a2));
System.out.println(Math.sinh(a3));
}
}
Output:

Example 3
public class JavaExample
{
public static void main(String[] args)
{
double a1 = Double.POSITIVE_INFINITY;
double a2 = Double.NEGATIVE_INFINITY;
double a3 = Math.PI;
System.out.println(Math.sinh(a1));
System.out.println(Math.sinh(a2));
System.out.println(Math.sinh(a3));
}
}
Output:
