Main Archive Specials Wiki | FAQ Links Submit Forum


Sin, Cos, Tan approximation

References : http://www.wild-magic.com
Linked file : approx.h

Notes :
Code for approximation of cos, sin, tan and inv sin, etc.
Surprisingly accurate and very usable.

[edit by bram]
this code is taken literaly from
http://www.wild-magic.com/SourceCode.html
Go have a look at the MgcMath.h and MgcMath.cpp files in their library...
[/edit]





Comments


Added on : 31/08/02 by asynth[ AT ]io[ DOT ]com
Comment :
It'd be nice to have a note on the domain of these functions. I assume Sin0 is meant to be used about zero and Sin1 about 1. But a note to that effect would be good.
Thanks,

james mccartney




Added on : 31/05/03 by mcodespam[ AT ]gmx[ DOT ]net
Comment :
Sin0 is faster but less accurate than Sin1, same for the other pairs. The domains are:

Sin/Cos [0, pi/2]
Tan [0,pi/4]
InvSin/Cos [0, 1]
InvTan [-1, 1]

This comes from the original header file.




Add your own comment
Comments are displayed in fixed width, no HTML code allowed!
Email:

Comment:

Are you human?



Site created and maintained by Bram
Graphic design by line.out | Server sponsered by fxpansion