Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Finding Inverse Cosine in Radians

Tags:

java

This gives me the answer in degrees but I want the answer in Radians for Inverse Cosine. For example if I pick 0.5 for invCosineVal it will return 60 deg but not sure how I can find the answer in Radians which should be 1.047.

ans = Math.acos(invCosineVal) * (180/Math.PI);
like image 272
ivesingh Avatar asked Dec 01 '22 18:12

ivesingh


1 Answers

ans = Math.acos(invCosineVal)

There you go, 180/Math.PI converts it to degrees

like image 123
Ryan S Avatar answered Dec 14 '22 06:12

Ryan S