Re: [opendx-dev] cbrt (Cube Root)?

2004-09-22 Thread Chris Pelkie
I just Echo'd Compute(8**(1/3.0)) and got 2. The trick was (as always) to force the denominator to float, else you get 1. On Tuesday, Sep 21, 2004, at 19:19 America/New_York, David Thompson wrote: I was going to add the cbrt function to Compute, I really needed it today--so I did. Problem is,

Re: [opendx-dev] cbrt (Cube Root)?

2004-09-22 Thread David Thompson
Thanks Chris. One thing to note is that this would be slower than the cbrt c function that can be hardware optimized. But it does solve my problem. One thing I was thinking was that if a were a complex, can you take a**(1/3.0)? What is the cube root of a complex? Its been a long time since

[opendx-dev] cbrt (Cube Root)?

2004-09-21 Thread David Thompson
I was going to add the cbrt function to Compute, I really needed it today--so I did. Problem is, that cbrt is not available on all platforms. Anybody know of a good place to look for an algorithm for cbrt that could be included in OpenDX? David --