[SciPy-user] sparse solver for large non-sqaure A matrix
Dwishen Ramanah
d.ramanah at uq.edu.au
Mon Jul 31 19:50:08 EDT 2006
Dear list,
I have to solve the system of equations, Ax = b . A is large and non-square.
In matlab one will do the following :
A= spalloc(neqns,npts,nzeros);
..
B= zeros(neqns,1)
..
x= full(a \ b)
Is there a similar way to solve this using scipy/numpy? I have worked
through the recent scipy.sparse tutorial.
a = csc_matrix((neqns, npts))
..
b = zeros((neqns,1),dtype=float)
..
phi = linalg.solve(a,b)
error :
ValueError: expected square matrix
Can this library be used for a non-square matrix?
Regards
Dwishen
More information about the SciPy-User
mailing list