leftSolve
Solve a linear system, falling back to a pseudoinverse if needed.
Developer documentation: this item describes internal implementation details.
Declaration
x = leftSolve(A,b)
Parameters
Asystem matrixbright-hand side
Returns
xsolution vector or matrix
Discussion
This is a defensive wrapper around left division. Sparse systems are solved directly with A\b. Dense systems first check the reciprocal condition number; if the matrix is effectively singular, the function falls back to pinv(A)*b.