Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def rad2deg(value):
- if value < 0.0:
- rad = 180 + 180 * (math.pi + value) / math.pi
- else:
- rad = 180 * value / math.pi
- return rad
- def deg2rad(value):
- if value > 180:
- deg = (value - 180) * math.pi / 180 - math.pi
- else:
- deg = value * math.pi / 180
- return deg
Advertisement
Add Comment
Please, Sign In to add comment