[SciPy-User] faster expm

Craig Jones craig.bulk at brechmos.org
Sat Oct 30 10:02:57 EDT 2010


Hi All,

I have been using scipy etc for just over a year now and am now exclusively
using it.  One application I have been doing requires a matrix exponential
(in lieu of integration).  In Matlab it was very fast but using
scipy.linalg.expm it is quite slow (as the actual algorithm is implemented
in python).  In fact about 50% of the code is spent in expm.  My matrix is
typically 9x9 to 12x12 and is about 50% zeros (most nonzero are along the
diagonal and just off diagonal).

What I would really like is a faster expm.  I am on a MacBook Pro and use
Enthought.  I know of things like pyrex, etc.  I was thinking that gsl might
be good as it is compiled but I was having problems with libraries and gsl.
Really I just want a solution and don't want to spend time on all these
things.  The other option, I guess, is to use a Fortran solution and then
merge that into python.

Has anyone got any ideas faster solutions (both for expm and for me to get
going :-) ).

Craig
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.scipy.org/pipermail/scipy-user/attachments/20101030/1a574fad/attachment.html>


More information about the SciPy-User mailing list