Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have to solve for $x$ in the linear equation $Ax=B$. However, $A$ has singular values that are close to zero (very small). So direct inversion is not a good idea. I wanted to solve for $ x$ using one of the numerical equation solvers? Does any one know which is the best one I could use? I used conjugate gradient method but the convergence is not achieved. Any better method?

share|cite|improve this question

Most solvers today use Singular Value Decomposition. See, for example, Numerical Recipes in C, Sec. 2.6.

share|cite|improve this answer
thanks for the reply. The problem is A has singular value that is falling below machine precision. I have tried using truncated SVD and I find that does no better job than conjugate gradient. Even though conjugate gradient does not converge (is unstable) it still looks gives solution that are closer to the expected one. At the moment I dont know where to truncate it and how small a singular value can the algorithm handle. I was wondering if there was some other algorithm that would ensure convergence. – SPB Jan 2 '13 at 15:51

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.