[SciPy-dev] banded generalized eigenvalue problems
a.u.r.e.l.i.a.n at gmx.net
Fri Nov 10 02:01:30 CST 2006
On Thursday 09 November 2006 23:11, Robert Kern wrote:
> Jonathan Taylor wrote:
> > I need to solve a banded generalized eigenvalue problem and was going to
> > try to mimic the code in generic_flapack.pyf to generate a wrapper for
> > the appropriate lapack function: dsbgv (and its name variants).
> > Is this the recommended way of using extra lapack functionality that is
> > not presently in scipy? If not, any other suggestions?
> I would say that's a pretty good approach not least because your wrapper
> can then immediately become a contribution to scipy.linalg .
However note that you can not pass a wrapper like in generic_flapack.pyf to
f2py directly. Some preprocessing is done to avoid having to write similar
wrappers for each type (s, d, c, z) separately. Looking at
generic_flapack.pyf, you will note terms like <tchar=s,d,c,z>, <type_in>,
etc., which are expanded accordingly.
Be careful, probably you can not put the real and complex routines together.
Preprocessing is done by $SCIPY_DIR/Lib/linalg/interface_gen.py. You will need
this if you want to test your wrapper before inclusion in scipy.
More information about the Scipy-dev