A Radian is a unit of measurement (Just like a degree is a measurement) used by the trigonometry functions to work out an angle. The following functions return a value in radians rather than degrees: Math.acos, Math.asin, Math.atan and Math.atan2. |
1 degree is approximately 0.01745 radians. Half a circle is 180 degrees or pi radians (i.e. approx. 3.1415) A full circle is 360 degrees or 2 pi (i.e. pi multiplied by 2). To convert degrees to radians – divide pi by 180 and then multiply by the number of degress. For example, to covert 45 degrees to radians |
DegToRad = (math.PI/180)*45 |
To covert radians to degrees – divide radians by (Math.PI/180). For example, to convert 0.785398 radians to degrees |
RadToDeg = 0.785398/(Math.PI/180) |
Note: You may need to do a conversion from radians to degrees if you want to rotate an object using the Rotate function which sets the angle by degrees and not radians. |