C++ help with math library
Posted: 2005-11-03 12:13am
I can not seem to find a C++ function for inverse of sin, cosine and tan in the standard math library. Is there any libraries available on the web which provide such functions ?
Get your fill of sci-fi, science, and mockery of stupid ideas
http://stardestroyer.dyndns-home.com/
http://stardestroyer.dyndns-home.com/viewtopic.php?f=24&t=79876
Only if you're working in degrees, though.Pu-239 wrote:The values are returned in radians though, so you'll have to multiply by 180/pi .
Use cmath.The Shadow wrote:I can not seem to find a C++ function for inverse of sin, cosine and tan in the standard math library. Is there any libraries available on the web which provide such functions ?
Arcsine, arccosine and arctangent are still couple of months away from being taught at school. So I never realised the answer was right below my nose ! I wrote a sample program using atan and it worked exactly as I wanted. Thanks !Dooey Jo wrote:If you have trouble remembering the names for the inverse trigonometric functions in C/C++, you could try to learn the classic names for those functions, which are arcsine, arccosine and so on. That way, the names "atan" and "asin" actually makes some sense, which should make them easier to remember...