Home >>Python math Module >Python math.asin() Method

Python math.asin() Method

Python math.asin() Method

Python math.asin() Method in python is used to returns the arc sine value in radians of the given number an accepts number between -1 to 1.

Syntax:
math.asin(x)

Parameter Values

Parameter Description
x It is required that a number to find the arc sine of and it returns a TypeError
Here is an Example of Python math.asin() Method:

import math
print (math.asin(0.17))
print (math.asin(-0.17))
print (math.asin(0))
print (math.asin(2))
print (math.asin(-2))

Output:
import math
print (math.asin(0.17))
print (math.asin(-0.17))
print (math.asin(0))
print (math.asin(1))
print (math.asin(-1))
Example 2:

import math
a = -1
print("asin(",a,") is = ", math.asin(a))
a = 0
print("asin(",a,") is = ", math.asin(a))
a = 0.154
print("asin(",a,") is = ", math.asin(a))
a = 1
print("asin(",a,") is = ", math.asin(a))

Output:
asin( -1 ) is = -1.5707963267948966
asin( 0 ) is = 0.0
asin( 0.154 ) is = 0.15461530016096145
asin( 1 ) is = 1.5707963267948966

No Sidebar ads