[SciPy-user] Solving complex RHS for real matrix using umfpack and scipy.sparse.linalg.dsolve.factorized

Anne Archibald peridot.faceted at gmail.com
Tue Oct 7 16:12:37 EDT 2008


2008/10/7 Neilen Marais <nmarais at sun.ac.za>:

> I have a real sparse matrix that I factorized using
> scipy.sparse.linalg.dsolve.factorized(). When I solve it with a complex
> RHS, I always get a real return. Do I need to set the matrix type as
> complex in this case, or is there a better way?

If all you're doing is solving  y = A*x, then you can simply solve for
the real and imaginary parts separately, since a real matrix won't mix
them and the problem is linear.

Anne



More information about the SciPy-User mailing list