![]() |
VOOZH | about |
The JavaScript Math sin( ) method in Javascript is used to return the sine of a number. The Math.sin() method returns a numeric value between -1 and 1, which represents the sine of the angle given in radians. The sin() is a static method of Math, therefore, it is always used as Math.sin(), rather than as a method of a Math object created.
Math.sin(value)This method accepts a single parameter as mentioned above and described below:
The Math.sin() method returns the sine of the given numbers between 1 and -1.
Example 1: Below is an example of the Math sin() Method.
When zero is passed as a parameter: 0
Example 2: When 1 is passed as a parameter.
Result : 0.8414709848078965
Example 3: When PI is passed as a parameter.
Result : 1
We have a complete list of Javascript Math Objects methods, to check those please go through this Javascript Math Object Complete reference article.