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

Python math.radians() Method

Python math.radians() Method

Python math.radians() method in python is used to returns the angle (degree) value in radians and it accepts a number.

Syntax:
math.radians(x)

Parameter Values

Parameter Description
x It is required a number to convert a degree value into radians.
Here is an example of Python math.radians() Method:

import math
print(math.radians(79))
print(math.radians(34.334))
print(math.radians(-75))

Output:
1.3788101090755203
0.5992413453797332
-1.3089969389957472
Example 2:

import math 
a = 10
print("math.radians(",a,"): ", math.radians(a))
a = 0
print("math.radians(",a,"): ", math.radians(a))
a = 14.15
print("math.radians(",a,"): ", math.radians(a))
a = -3.15
print("math.radians(",a,"): ", math.radians(a))

Output:
math.radians( 10 ): 0.17453292519943295
math.radians( 0 ): 0.0
math.radians( 14.15 ): 0.24696408915719764
math.radians( -3.15 ): -0.05497787143782138

No Sidebar ads