Jochen Küpper | 14 May 17:56 2002
X-Face
Picon

Re: build problem using cygwin

On Tue, 14 May 2002 15:36:02 +0200 Geza Groma wrote:

Geza> Is there any single tool to build _both_ Atlas and scipy on
Geza> Windows?

Are you using the cygwin python or do you wanna use the Windows
Python?

I use Cygwin:)) Latest cygwin (incl. python and gcc) and scipy cvs...
It didn't work all time, but lately I don't have many problems.

Greetings,
Jochen
--

-- 
University of North Carolina                       phone: +1-919-962-4403
Department of Chemistry                            phone: +1-919-962-1579
Venable Hall CB#3290 (Kenan C148)                    fax: +1-919-843-6041
Chapel Hill, NC 27599, USA                            GnuPG key: 44BCCD8E
A.Schmolck | 15 May 13:57 2002
Picon
Picon

problems building scipy from cvs

Hi,

Is scipy meant to work with Atlas 3.4.0? I haven't managed to build
yesterday's CVS version with it successfully (haven't tried the Atlas 3.3.x
versions, 3.4 should do everything those do, is that right?). Anyway after
building , here is what I get  when I do ``import scipy``:

exceptions.ImportError:
/usr/lib/python2.2/site-packages/scipy/linalg/clapack.so: undefined symbol:
clapack_sgetri

> nm /usr/lib/liblapack.a |grep sgetri
sgetri.o:
00000000 T sgetri_

I'm running Linux Mandrake 8.1 on an Athlon and used gcc 2.95.3 to build
atlas, according to the instructions on the atlas pages.

Cheers,

alex

--

-- 
Alexander Schmolck     Postgraduate Research Student
                       Department of Computer Science
                       University of Exeter
A.Schmolck <at> gmx.net     http://www.dcs.ex.ac.uk/people/aschmolc/
Pearu Peterson | 15 May 18:37 2002
Picon
Picon

Re: problems building scipy from cvs


On 15 May 2002, A.Schmolck wrote:

> Hi,
> 
> Is scipy meant to work with Atlas 3.4.0? 

I think so. From Atlas 3.4.0 announcement:
   <snip>

   3.4.0 is 3.3.15 with some doc changes.

   <snip>

> I haven't managed to build
> yesterday's CVS version with it successfully (haven't tried the Atlas 3.3.x
> versions, 3.4 should do everything those do, is that right?). Anyway after
> building , here is what I get  when I do ``import scipy``:
> 
> exceptions.ImportError:
> /usr/lib/python2.2/site-packages/scipy/linalg/clapack.so: undefined symbol:
> clapack_sgetri
> 
> > nm /usr/lib/liblapack.a |grep sgetri
> sgetri.o:
> 00000000 T sgetri_

Where did you install your atlas? What's the output of

  python scipy_distutils/system_info.py
(Continue reading)

A.Schmolck | 15 May 21:06 2002
Picon
Picon

Re: problems building scipy from cvs

Pearu Peterson <pearu <at> cens.ioc.ee> writes:

> 
> ? Are you sure that scipy was built against atlas 3.4.0 and not against
> the system atlas?
> 
> For example, in my case (Atlas 3.3.14)
> 
> nm /path/to/my/atlas/liblapack.a | grep clapack_sgetri
> clapack_sgetri.o:
> 00000000 T clapack_sgetri
> 
> HTH,
> 
> Pearu

Yes, that helped indeed, thanks. I must have made some mistake when I ar'ed
the atlas stuff into my lapack library -- I did it again and now it works.

Thanks.

alex

--

-- 
Alexander Schmolck     Postgraduate Research Student
                       Department of Computer Science
                       University of Exeter
A.Schmolck <at> gmx.net     http://www.dcs.ex.ac.uk/people/aschmolc/
tinu | 16 May 10:24 2002
Picon

NNTP access to scipy-dev and scipy-user

Dear list members

There is now NNTP access to the scipy lists at

news://news.gmane.org

The lists scipy-mailing lists are named

gmane.comp.python.scientific.user 
gmane.comp.python.scientific.devel 

If everything works out, this message should be sent 
through the news server at www.gmane.org

Enjoy

Martin

--

-- 
Martin Lüthi              VAW Glaciology, ETH Zürich, Switzerland
                          mel: luthi <at> vaw.baug.ethz.ch
Nils Wagner | 16 May 15:43 2002
Picon

Numerical integration of a matrix

Hi all,

How do I integrate the following matrix elements in an efficient manner
with scipy

c_{j,k} = \int\limits_0^\pi \varepsilon a(x) \sin (k x) \sin (j x) dx   
(Latex notation)

j, k = 1, ..., 9

\varepsilon = 0.1

a(x) = x^2 (\pi-x)^2 - \delta, \delta = 201.0

Thanks in advance.

                   Nils
Nils Wagner | 16 May 16:14 2002
Picon

quadpack.error: Supplied function does not return a valid float.

Hi,

I have experienced a problem while using quad

Traceback (most recent call last):
  File "quad.py", line 9, in ?
    print m,n,sinint(m,n,1)
  File "quad.py", line 6, in sinint
    return quad(integrand,0.,pi,args=(m,n,x))
  File
"/usr/local/lib/python2.1/site-packages/scipy/integrate/quadpack.py",
line 180, in quad
    retval = _quad(func,a,b,args,full_output,epsabs,epsrel,limit,points)
  File
"/usr/local/lib/python2.1/site-packages/scipy/integrate/quadpack.py",
line 244, in _quad
    return
_quadpack._qagse(func,a,b,args,full_output,epsabs,epsrel,limit)
quadpack.error: Supplied function does not return a valid float.

from scipy import *
from scipy.integrate import quad
def integrand(t,m,n,x):
   return sin(m*x*t)*sin(n*x*t)
def sinint(m,n,x):
   return quad(integrand,0.,pi,args=(m,n,x))
for m in arange(0,9):
   for n in arange(0,9):
      print m,n,sinint(m,n,1)

(Continue reading)

Pearu Peterson | 16 May 19:59 2002
Picon
Picon

Re: Numerical integration of a matrix


On Thu, 16 May 2002, Nils Wagner wrote:

> Hi all,
> 
> How do I integrate the following matrix elements in an efficient manner
> with scipy
> 
> c_{j,k} = \int\limits_0^\pi \varepsilon a(x) \sin (k x) \sin (j x) dx   
> (Latex notation)
> 
> j, k = 1, ..., 9
> 
> \varepsilon = 0.1
> 
> a(x) = x^2 (\pi-x)^2 - \delta, \delta = 201.0

I think you can do it also analytically (use some CAS, for example).
But if you insist it to be done numerically then look at quadpack
functions QAWO and QAWF. Or disrcetize a(x) and use FFT.

Pearu
clee | 16 May 20:48 2002
Picon

Re: Numerical integration of a matrix


On Thu, 16 May 2002, Nils Wagner wrote:

> Hi all,
> 
> How do I integrate the following matrix elements in an efficient manner
> with scipy
> 
> c_{j,k} = \int\limits_0^\pi \varepsilon a(x) \sin (k x) \sin (j x) dx   
> (Latex notation)
> 
> j, k = 1, ..., 9
> 
> \varepsilon = 0.1
> 
> a(x) = x^2 (\pi-x)^2 - \delta, \delta = 201.0

Pearu's mail caught me while I was actually  in Mathematica, so I went ahead and
tried it. -chris

--mathematica code--
a[x_] := x^2 (Pi-x)^2 - 201.0; 
cm[j_,k_] := Integrate[a[x] Sin[j x] Sin[k x], {x, 0, Pi}];
results = Table[cm[j,k], {j,1,9}, {k,1,9}];
TeXForm[TableForm[results]]

--Here's the answer, embeded in latex.--

\documentclass[8pt]{report}
\usepackage[active]{srcltx}
(Continue reading)

Travis Oliphant | 16 May 21:21 2002
Picon

Re: quadpack.error: Supplied function does not return a valid float.

On Thu, 2002-05-16 at 08:14, Nils Wagner wrote:
> Hi,
> 
> I have experienced a problem while using quad
> 
> Traceback (most recent call last):
>   File "quad.py", line 9, in ?
>     print m,n,sinint(m,n,1)
>   File "quad.py", line 6, in sinint
>     return quad(integrand,0.,pi,args=(m,n,x))
>   File
> "/usr/local/lib/python2.1/site-packages/scipy/integrate/quadpack.py",
> line 180, in quad
>     retval = _quad(func,a,b,args,full_output,epsabs,epsrel,limit,points)
>   File
> "/usr/local/lib/python2.1/site-packages/scipy/integrate/quadpack.py",
> line 244, in _quad
>     return
> _quadpack._qagse(func,a,b,args,full_output,epsabs,epsrel,limit)
> quadpack.error: Supplied function does not return a valid float.
> 
> from scipy import *
> from scipy.integrate import quad
> def integrand(t,m,n,x):
>    return sin(m*x*t)*sin(n*x*t)
> def sinint(m,n,x):
>    return quad(integrand,0.,pi,args=(m,n,x))
> for m in arange(0,9):
>    for n in arange(0,9):
>       print m,n,sinint(m,n,1)
(Continue reading)


Gmane