Re: [math] Complex nth roots

2009-01-06 Thread Phil Steitz
Yeah. Speed probably goes the other way. Accuracy is another issue. On 1/6/09, Luc Maisonobe wrote: > Phil Steitz a écrit : > >> Committed in r731822. I noticed one more thing that I just commented >> for now in the code. It might be faster and/or more accurate to use a >> solver to compute the

Re: [math] Complex nth roots

2009-01-06 Thread Luc Maisonobe
Phil Steitz a écrit : > Committed in r731822. I noticed one more thing that I just commented > for now in the code. It might be faster and/or more accurate to use a > solver to compute the nth root of the modulus. Should we consider doing > this and exposing the associated real function in Math

Re: [math] Complex nth roots

2009-01-05 Thread Phil Steitz
Phil Steitz wrote: Luc Maisonobe wrote: Phil Steitz a écrit : Ted Dunning wrote: I just check on how sbcl handles this. The result was mixed, but instructive as predicted. Positive and negative infinity behave as expected. ** (/ 1 0.0) #.SB-EXT:SINGLE-FLOAT-POSITIVE-INFINITY * (/ -1

Re: [math] Complex nth roots

2009-01-03 Thread Phil Steitz
Luc Maisonobe wrote: Phil Steitz a écrit : Ted Dunning wrote: I just check on how sbcl handles this. The result was mixed, but instructive as predicted. Positive and negative infinity behave as expected. ** (/ 1 0.0) #.SB-EXT:SINGLE-FLOAT-POSITIVE-INFINITY * (/ -1 0.0) * ***#.SB-EXT

Re: [math] Complex nth roots

2009-01-03 Thread Luc Maisonobe
Phil Steitz a écrit : > Ted Dunning wrote: >> I just check on how sbcl handles this. The result was mixed, but >> instructive as predicted. >> >> Positive and negative infinity behave as expected. >> >> ** (/ 1 0.0) >> #.SB-EXT:SINGLE-FLOAT-POSITIVE-INFINITY >> >> * (/ -1 0.0) >> * >> ***#.SB-EXT:

Re: [math] Complex nth roots

2009-01-03 Thread Phil Steitz
Ted Dunning wrote: I just check on how sbcl handles this. The result was mixed, but instructive as predicted. Positive and negative infinity behave as expected. ** (/ 1 0.0) #.SB-EXT:SINGLE-FLOAT-POSITIVE-INFINITY * (/ -1 0.0) * ***#.SB-EXT:SINGLE-FLOAT-NEGATIVE-INFINITY * Square roots of ne

Re: [math] Complex nth roots

2009-01-02 Thread Ted Dunning
I just check on how sbcl handles this. The result was mixed, but instructive as predicted. Positive and negative infinity behave as expected. ** (/ 1 0.0) #.SB-EXT:SINGLE-FLOAT-POSITIVE-INFINITY * (/ -1 0.0) * ***#.SB-EXT:SINGLE-FLOAT-NEGATIVE-INFINITY * Square roots of negative infinity work

Re: [math] Complex nth roots

2009-01-02 Thread Ted Dunning
I think that (2) is the easiest for a user to understand. Obviously, the documentation aspect of (1) should be brought along. The behavior of Common Lisp is always instructive in these regards. The complex arithmetic was generally very well thought out. On Fri, Jan 2, 2009 at 7:14 PM, Phil Stei

Re: [math] Complex nth roots

2009-01-02 Thread Phil Steitz
Phil Steitz wrote: Phil Steitz wrote: Thanks, Bernhard for the contribution in MATH-236. I would like to suggest a couple of improvements. First, I think the return type should be List, not Collection, as there is an order to the elements in the returned collection (as stated in the API doc

Re: [math] Complex nth roots

2009-01-02 Thread Phil Steitz
Phil Steitz wrote: Thanks, Bernhard for the contribution in MATH-236. I would like to suggest a couple of improvements. First, I think the return type should be List, not Collection, as there is an order to the elements in the returned collection (as stated in the API doc, the order is by in

Re: [math] Complex nth roots

2009-01-02 Thread Bernhard Grünewaldt
+1 sounds good :) Phil Steitz schrieb: > Thanks, Bernhard for the contribution in MATH-236. I would like to > suggest a couple of improvements. > > First, I think the return type should be List, not Collection, as there > is an order to the elements in the returned collection (as stated in the

[math] Complex nth roots

2009-01-01 Thread Phil Steitz
Thanks, Bernhard for the contribution in MATH-236. I would like to suggest a couple of improvements. First, I think the return type should be List, not Collection, as there is an order to the elements in the returned collection (as stated in the API doc, the order is by increasing argument).