Re: Current implementation of exp() is faulty.

new topic     » goto parent     » topic index » view thread      » older message » newer message

Jeremy Cowgar wrote:
> 
> Are my expected values in the unit tests wrong as the unit tests pass. To get
> the values for the test, I used Python and took the values they reported and
> plugged them into the unit test.
> 
> --
> Jeremy Cowgar
> <a href="http://jeremy.cowgar.com">http://jeremy.cowgar.com</a>

I don't understand either of the two tests. Why rounding the returned value?
Using atom_to_float64() and the parser built in the interpreter is much better.
Don't compare strings, so that you avoid more false negatives. This had already
hit you about deg2rad iirc.
The arguments you used (2 and 2.3) are in the range where power(x,E) returns the
proper value. Try x=10 without rounding.

CChris

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu