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

Can we use partial pivoting when obtaining the upper triangular matrix using Gaussian elimination? If so, how can we do it?

Let $Ax=B$ and $A=LU$

To determine $L$, it seems fancy to use pivoting as we interchange rows in $A$, since we are using the factors used in Gaussian elimination which were found during the search for $U$.

share|cite|improve this question
"Urgent" is not a good word to use here when asking us questions. We are not your horses to be whipped. – J. M. Nov 26 '11 at 14:03
In any event: yes, you can do Gaussian elimination with partial pivoting. The decomposition goes like $\mathbf P\mathbf A=\mathbf L\mathbf U$, where $\mathbf P$ is a permutation matrix. – J. M. Nov 26 '11 at 14:05

If you have $A=L U$ then solving $Ax = b$ is equivalent to solving first $L y = B$ and then $U x=y$. The point being, both of those can be done very easily since they are triangular systems.

share|cite|improve this answer
Thanks, but my question was not how to decompose a matrix into LU. I wanted to know how to use pivoting when doing LU decomposition. – Tharindu Rusira Nov 26 '11 at 15:58
@Tharindu: You'll want to see this. – J. M. Nov 26 '11 at 16:55
Got it. thanks all... – Tharindu Rusira Nov 26 '11 at 17:57

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.