C# - Math Sinh() Method
The C# Math Sinh() method is used to return hyperbolic sine of a value. The hyperbolic sine of x is defined as:
where e is an Euler's number.
In special cases it returns the following:
- If the argument is NaN, the method returns NaN.
- If the argument is PositiveInfinity or NegativeInfinity, the method returns a Double equal to argument.
Syntax
public static double Sinh(double arg);
Parameters
arg |
Specify the value. |
Return Value
Returns the hyperbolic sine of a value.
Example:
In the below example, Sinh() method is used to find out the hyperbolic sine of a value.
using System; class MyProgram { static void Main(string[] args) { Console.WriteLine(Math.Sinh(0)); Console.WriteLine(Math.Sinh(2)); Console.WriteLine(Math.Sinh(4)); } }
The output of the above code will be:
0 3.62686040784702 27.2899171971278
❮ C# Math Methods