??? 10/25/07 23:57 Read: times |
#146231 - Adding FP's accurately Responding to: ???'s previous message |
Christoph Franck said:
Do you know the algorithm to "accurately" add more than two floating point numbers ? Hi Christoph, My apologies, I misunderstood your question, to keep the FP errors to a minimum, I would try and keep the FP number excursions as small as possible, but I'm guessing here. To be honest, I don't recall having any accuracy problems using FP but I agree they do exist. My compiler unfortunately does not support transcandential math functions like sqrt,e^x,ln,sin,cos,..etc, so I wrote my own using the Pade algorithm and Newtons root finder. I tried using Taylors algorithm and also cordics but found the latter two to be less accurate. Cheers for now. Jason |