Re: [Numpy-discussion] Dealing with roundoff error

2010-03-27 Thread Pauli Virtanen
Mike Sarahan wrote: > However, even linspace shows roundoff error: > > a=np.linspace(0.0,10.0,endpoint=False) > b=np.linspace(0.1,10.1,endpoint=False) > np.sum(a[1:]==b[:-1])  # Gives me 72, no 100 Are you sure equally spaced floating point numbers having this property even exist? 0.1 does not ha

Re: [Numpy-discussion] numpy.trapz() doesn't respect subclass

2010-03-27 Thread josef . pktd
On Sat, Mar 27, 2010 at 11:37 PM, Ryan May wrote: > On Sat, Mar 27, 2010 at 8:23 PM,   wrote: >> Matrices have been part of numpy for a long time and your patch would >> break backwards compatibility in a pretty serious way. > > Yeah, and I should admit that I realize that makes this particular >

Re: [Numpy-discussion] numpy.trapz() doesn't respect subclass

2010-03-27 Thread Ryan May
On Sat, Mar 27, 2010 at 8:23 PM, wrote: > Matrices have been part of numpy for a long time and your patch would > break backwards compatibility in a pretty serious way. Yeah, and I should admit that I realize that makes this particular patch a no-go. However, that to me doesn't put the issue to

Re: [Numpy-discussion] numpy.trapz() doesn't respect subclass

2010-03-27 Thread josef . pktd
On Sat, Mar 27, 2010 at 2:31 PM, Ryan May wrote: > On Sat, Mar 27, 2010 at 11:12 AM,   wrote: >> On Sat, Mar 27, 2010 at 1:00 PM, Ryan May wrote: >>> On Mon, Mar 22, 2010 at 8:14 AM, Ryan May wrote: On Sun, Mar 21, 2010 at 11:57 PM,   wrote: > On Mon, Mar 22, 2010 at 12:49 AM, Ryan May

Re: [Numpy-discussion] Interpolation question

2010-03-27 Thread josef . pktd
On Sat, Mar 27, 2010 at 8:24 PM, Andrea Gavana wrote: > Hi All, > >    I have an interpolation problem and I am having some difficulties > in tackling it. I hope I can explain myself clearly enough. > > Basically, I have a whole bunch of 3D fluid flow simulations (close to > 1000), and they are a

[Numpy-discussion] Interpolation question

2010-03-27 Thread Andrea Gavana
Hi All, I have an interpolation problem and I am having some difficulties in tackling it. I hope I can explain myself clearly enough. Basically, I have a whole bunch of 3D fluid flow simulations (close to 1000), and they are a result of different combinations of parameters. I was planning to

[Numpy-discussion] Dealing with roundoff error

2010-03-27 Thread Mike Sarahan
Hi all, I have run into some roundoff problems trying to line up some experimental spectra. The x coordinates are given in intervals of 0.1 units. I read the data in from a text file using np.loadtxt(). I think Robert's post here explains why the problem exists: http://mail.scipy.org/pipermail/

Re: [Numpy-discussion] numpy.trapz() doesn't respect subclass

2010-03-27 Thread Ryan May
On Sat, Mar 27, 2010 at 11:12 AM, wrote: > On Sat, Mar 27, 2010 at 1:00 PM, Ryan May wrote: >> On Mon, Mar 22, 2010 at 8:14 AM, Ryan May wrote: >>> On Sun, Mar 21, 2010 at 11:57 PM,   wrote: On Mon, Mar 22, 2010 at 12:49 AM, Ryan May wrote: > Hi, > > I found that trapz() doesn

Re: [Numpy-discussion] numpy.trapz() doesn't respect subclass

2010-03-27 Thread josef . pktd
On Sat, Mar 27, 2010 at 1:00 PM, Ryan May wrote: > On Mon, Mar 22, 2010 at 8:14 AM, Ryan May wrote: >> On Sun, Mar 21, 2010 at 11:57 PM,   wrote: >>> On Mon, Mar 22, 2010 at 12:49 AM, Ryan May wrote: Hi, I found that trapz() doesn't work with subclasses: http://projects.

Re: [Numpy-discussion] numpy.trapz() doesn't respect subclass

2010-03-27 Thread Ryan May
On Mon, Mar 22, 2010 at 8:14 AM, Ryan May wrote: > On Sun, Mar 21, 2010 at 11:57 PM,   wrote: >> On Mon, Mar 22, 2010 at 12:49 AM, Ryan May wrote: >>> Hi, >>> >>> I found that trapz() doesn't work with subclasses: >>> >>> http://projects.scipy.org/numpy/ticket/1438 >>> >>> A simple patch (attache

Re: [Numpy-discussion] f2py: "could not crack entity declaration"

2010-03-27 Thread Kevin Jacobs
On Fri, Mar 26, 2010 at 7:07 PM, David Warde-Farley wrote: > On 26-Mar-10, at 4:25 PM, David Warde-Farley wrote: > > > That said, I gave that wrapper a whirl and it crashed on me... > > > > I noticed you added an 'njd' argument to the wrapper for elnet, did > > you modify the elnet Fortran functi

Re: [Numpy-discussion] numpy.array(arr.flat) mutates arr if arr.flags.fortran: bug?

2010-03-27 Thread Zachary Pincus
> You should open a ticket for this. http://projects.scipy.org/numpy/ticket/1439 On Mar 26, 2010, at 11:26 AM, Charles R Harris wrote: > > > On Wed, Mar 24, 2010 at 1:13 PM, Zachary Pincus > wrote: > Hello, > > I assume it is a bug that calling numpy.array() on a flatiter of a > fortran-strid