[SciPy-user] Left hand sparse matrix multiplication

James Philbin philbinj@gmail....
Wed Oct 8 10:41:48 CDT 2008


I'm trying to compute x*A where x is a dense row vector and A is a
sparse CSC matrix. A.rmatvec seems to do what I want but is wasteful
as it computes:
self.transpose().matvec( other )
i.e. it computes A^T * x^T.

It seems there should be a much more efficient overload for csc's
rmatvec which doesn't involve computing the transpose. I hope i'm
understanding things correctly.


On Tue, Oct 7, 2008 at 9:12 PM, Anne Archibald
<peridot.faceted@gmail.com> wrote:
> 2008/10/7 Neilen Marais <nmarais@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
> _______________________________________________
> SciPy-user mailing list
> SciPy-user@scipy.org
> http://projects.scipy.org/mailman/listinfo/scipy-user

More information about the SciPy-user mailing list