On 16/12/2007, Hans Meine <[EMAIL PROTECTED]> wrote: > (*: It's similar with math.hypot, which I have got to know and appreciate > nowadays.)
I'd like to point out that math.hypot is a nontrivial function which is easy to get wrong: In [6]: x=1e200; y=1e200; In [7]: math.hypot(x,y) Out[7]: 1.414213562373095e+200 In [8]: math.sqrt(x**2+y**2) --------------------------------------------------------------------------- <type 'exceptions.OverflowError'> Traceback (most recent call last) /home/peridot/<ipython console> in <module>() <type 'exceptions.OverflowError'>: (34, 'Numerical result out of range') Anne _______________________________________________ Numpy-discussion mailing list [email protected] http://projects.scipy.org/mailman/listinfo/numpy-discussion
