Trusted answers to developer questions
Trusted Answers to Developer Questions

Related Tags

javascript
math
communitycreator

# What is Math.sinh() in JavaScript? Arslan Bajwa

Grokking Modern System Design Interview for Engineers & Managers

Ace your System Design Interview and take your career to the next level. Learn to handle the design of applications like Netflix, Quora, Facebook, Uber, and many more in a 45-min interview. Learn the RESHADED framework for architecting web-scale applications by determining requirements, constraints, and assumptions before diving into a step-by-step design process.

Math in JavaScript is a built-in object that contains different methods and properties to perform mathematical operations. It contains a sinh() function , which is used to compute the hyperbolic sine of a specified angle.

## Syntax

Math.sinh(param);

## Parameter

• param: This is the angle for which we want to compute the hyperbolic sine. Its type is Number, and it is measured in radians.

Number in JavaScript is a 64-bit double-precision value which is the same as a double in C# or Java.

## Return value

• Number: It returns the hyperbolic sine of the given angle stored in param. It is of the Number type.

• +Infinity: The function returns this for positive Infinity as input.

• -Infinity: The function returns this for negative Infinity as input.

Use the following formula to convert degrees to radians.

• Radians = Degrees x π /180

where π = 3.14159, approximately.

## Code

console.log("sinh(-1) = " + Math.sinh(-1));console.log("sinh(0) = " + Math.sinh(0));console.log("sinh(1) = " + Math.sinh(1));console.log("sinh(∞) = " + Math.sinh(Infinity));console.log("sinh(-∞) = " + Math.sinh(-Infinity));

RELATED TAGS

javascript
math
communitycreator

CONTRIBUTOR Arslan Bajwa

Grokking Modern System Design Interview for Engineers & Managers

Ace your System Design Interview and take your career to the next level. Learn to handle the design of applications like Netflix, Quora, Facebook, Uber, and many more in a 45-min interview. Learn the RESHADED framework for architecting web-scale applications by determining requirements, constraints, and assumptions before diving into a step-by-step design process.

Keep Exploring

Learn in-demand tech skills in half the time 