• Post Reply Bookmark Topic Watch Topic
  • New Topic

which is valid ?Math.cos(56)or .......  RSS feed

 
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
which is valid ?Math.cos(56)or Math.cos(Math.toRadians(56))orMath.cos(Math.toDegrees(56))
 
Sheriff
Posts: 11532
181
Android Debian Eclipse IDE IntelliJ IDE Java Linux Mac Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Depends on what the units of 56 are. The API JavaDocs clearly state that the arguments for the trigonometric functions are angles in radians.
(Please bookmark the above link for your future reference -- you'll learn a lot more, a lot faster by trying to look things up yourself)
Junilu
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!