17.9 KB · commit a9602da
← Previous: NM-2 Lower Tier | 🏠 Index | Next: NM-3.5 Gauss-Seidel Iteration →
Section: A (Numerical Methods) | Priority: 🔴 | Exam Frequency: 4/8 years Sources: Jain Ch.7 §7.5.2, Topicwise NM-3.2, Shishir Notes §02
Pivoting appears in four papers, always as a short theory question. The shapes are: define pivoting, discuss partial and complete pivoting, or say why pivoting matters. The marks are cheap. Learn one definition, the two search rules, and the stability-versus-conditioning distinction, and all four questions are covered. The topic also pays rent in every elimination answer: any Gauss elimination solution in this course is expected to mention pivoting.
Pivot: "the first equation in the system (7.30) is called the pivot equation, and a11 is called the pivot ... The method obviously fails if a11=0." — Jain, §7.5 (p. 264)
Necessity for pivoting: "We now come to the important case of the pivot being zero or very close to zero. If the pivot is zero, the entire process fails and if it is close to zero, round-off errors may occur. These problems can be avoided by adopting a procedure called pivoting." — Jain, §7.5.2 (p. 265)
Partial pivoting: "we find the largest available coefficient in the columns below the pivot equation and then interchange the two rows ... Such a process is called partial pivoting, since in this case we search only the columns below for the largest element." — Jain, §7.5.2 (p. 265)
Complete pivoting: "If, on the other hand, we search both columns and rows for the largest element, the procedure is called complete pivoting." — Jain, §7.5.2 (p. 265)
Every elimination step divides. At step k the entry akk is the pivot, and the multiplier that clears the entries below it is
mik=akkaikThe pivot sits in the denominator of every multiplier in that column. So a small pivot forces large multipliers. Each multiplier scales what gets subtracted, and subtracting large nearly equal numbers cancels away the significant digits. The computation still runs. It returns a wrong answer with no warning.
Two failure sizes exist, and they are not equally dangerous:
The silent failure is the dangerous one. A zero pivot is obvious; a tiny pivot is not.
At step k, search column k in rows k through n for the entry of largest absolute value. Exchange that row into position k. Then form the multipliers.
The search must include the diagonal itself, rows k to n. On later steps the entries above the diagonal have already been used, so they are not candidates. Searching only rows k+1 to n and leaving a small diagonal in place is the single most common implementation error. It silently reintroduces the instability pivoting exists to remove.
Two properties make partial pivoting the default choice:
The cost is one comparison per candidate row, and no extra arithmetic.
At step k, search the whole remaining sub-matrix, rows k to n and columns k to n, for the entry of largest absolute value. Bring it to position (k,k) by a row exchange and a column exchange.
The column exchange reorders the unknowns. The order in which the solution vector is finally written must be restored afterwards. The extra search costs about n2 comparisons per step, against roughly n for partial pivoting. So complete pivoting is reserved for systems that are nearly singular or where stability is critical.
Plain partial pivoting can treat a row unfairly. A row with large entries elsewhere and a small pivot in this column looks bad, even though its pivot is reasonable for its own scale.
The fix is to divide each candidate by its own row's largest magnitude first, then compare. Choose the row k maximising
maxj∣aij∣∣aik∣In engineering practice, scaled partial pivoting is the default and complete pivoting is rare. The n2 cost per step buys stability that scaled partial pivoting already provides for all but nearly singular systems.
Pivoting improves stability, not conditioning. The condition number κ(A) is a property of the problem. No reordering changes it.
The practical consequence is sharp. A perfectly pivoted elimination of an ill-conditioned system returns a confidently wrong answer. Pivoting decides whether the arithmetic keeps its digits. It says nothing about whether the problem deserves those digits.
Pivoting also cannot rescue a singular matrix. If a whole column of the remaining submatrix is zero, no rearrangement helps. Pivoting makes a bad pivot large. It cannot manufacture a nonzero pivot where none exists.
This is the textbook's own demonstration of why the tiny-pivot case matters. The exact solution is x1=1 and x2=0.5.
With pivoting. Swap the rows so the larger coefficient leads:
0.5000x1+0.8942x20.000312x1+0.006032x2=0.9471=0.003328Eliminate x1 from row 2. The multiplier is 0.50000.000312=0.000624, so
0.5000x1+0.8942x20.005474x2=0.9471=0.002737Back substitution gives x2=0.5 and x1=1.0. Both correct.
Without pivoting. Use the printed order:
0.000312x1+0.006032x20.5000x1+0.8942x2=0.003328=0.9471The multiplier is 0.0003120.5000=1602.56. Eliminating x1 gives
0.000312x1+0.006032x2−8.7725x2=0.003328=−5.3300Back substitution gives x2=0.6076 and x1=−1.0803. Both wrong, and the second is wrong by more than its own magnitude. The effect of pivoting is clearly seen.
| Year | Question | Data Given | Key Answer |
|---|---|---|---|
| 2017 Q.4(a) | Define pivots, partial and complete pivoting | none (03 marks) | Pivot is the divisor; partial searches a column, complete searches the sub-matrix |
| 2019 Q.3(b) | Discuss partial and complete pivoting in brief | none (04 marks) | Search region, exchanges, stability, cost |
| 2021 Q.7(a) | Why is pivoting important? | none (02 marks) | Pivoting avoids a zero or tiny divisor, which is where elimination accuracy is lost |
| 2022 Q.3(c) | What is pivoting? | none (02 marks) | Pivoting reorders rows or columns so the divisor is as large as possible, avoiding a tiny pivot and its round off |
Appeared: 2017 Q.4(a) — (03 marks)
Full Answer:
Pivots. In Gauss elimination, the pivot is the element used to eliminate the entries below it. At step k the entry akk, in the k-th row and k-th column of the transformed matrix, is the pivot. The multipliers are
mik=akkaikThe pivot enters the denominator of every multiplier at that step. A small pivot produces large multipliers, which amplify rounding error. That is the problem pivoting is designed to prevent.
(i) Partial pivoting. At each step, search the k-th column below and including the diagonal, rows k to n, for the entry of largest absolute value. Exchange it into position (k,k). Only row exchanges are used, so the order of the unknowns is unchanged. This keeps ∣mik∣≤1 for all i>k, which controls the magnitude of what is subtracted. The cost is O(n2) comparisons over the whole elimination.
(ii) Complete pivoting. At each step, search the entire remaining sub-matrix, rows k to n and columns k to n, for the entry of largest absolute value. Bring it to position (k,k) by a row exchange and a column exchange. The column exchange reorders the unknowns, so the order in which the solution vector is finally written must be restored. The extra search costs about n2 comparisons per step, so O(n3) over the whole elimination, twice the work of partial pivoting.
When the difference matters. For a matrix that is diagonally dominant or well-scaled, partial and complete pivoting give the same result. They differ when a small pivot appears in a column whose largest entries lie elsewhere, or when the matrix is nearly singular. Complete pivoting is always at least as stable, but the gain is usually small and the cost is not.
Appeared: 2019 Q.3(b) — (04 marks)
Full Answer:
Partial pivoting. At step k of the elimination, search column k of the rows k through n for the entry of largest absolute value. Exchange it with the entry in position (k,k) before forming the multipliers. The multiplier is then
mik=akkaik,∣mik∣≤1So no multiplier exceeds one in magnitude, and the rounding introduced by the multiplier is controlled. Partial pivoting searches one column only, and it is sufficient for the great majority of systems.
Complete pivoting. At step k, search the whole remaining sub-matrix, rows k through n and columns k through n, for the entry of largest absolute value. Bring it to position (k,k) by a row exchange and a column exchange. Column exchanges reorder the unknowns, so the order in which the solution vector is written must be restored afterwards. The extra search raises the cost by a factor of about n2 per step. That is why complete pivoting is reserved for systems that are nearly singular or where numerical stability is critical.
| Partial pivoting | Complete pivoting | |
|---|---|---|
| Search region | column k, rows k to n | sub-matrix, rows and columns k to n |
| Row exchange | yes | yes |
| Column exchange | no | yes, unknown order changes |
| Stability | adequate for most systems | best available |
| Cost | low | higher by a factor of about n2 |
When it matters. If the pivot akk is small relative to the entries below it, the multiplier mik is large. The row Ri−mikRk then carries a value dominated by rounding. Choosing the largest available pivot keeps the magnitude of what is subtracted under control, and prevents a small physical quantity from being lost against a large one.
Appeared: 2021 Q.7(a) — (02 marks, CO: 1)
Full Answer:
Every elimination step divides by the pivot, the element chosen as divisor. Pivoting reorders rows or columns so that pivot is as large in magnitude as possible.
Two reasons.
Partial pivoting, the usual choice, selects the largest ∣aik∣ in column k below the diagonal and swaps it up. It costs one comparison per candidate and no extra arithmetic.
Pivoting avoids a zero or tiny divisor, which is where elimination accuracy is lostAppeared: 2022 Q.3(c) — (02 marks, CO: 1)
Full Answer:
Definition. In Gaussian elimination, pivoting is the act of interchanging rows, or columns, so that the element chosen as the pivot (the next divisor) is as large as possible in magnitude, or at least not negligibly small.
Why it is needed. Every elimination step divides by the pivot. If the pivot happens to be 0 the step is impossible. If it is merely tiny, say 10−9, the multiplier aik/akk becomes enormous, and the elimination floods the remaining rows with round off error.
Two kinds.
Scaled partial pivoting chooses k maximising
maxj∣aij∣∣aik∣A third form. Complete pivoting searches the whole remaining submatrix and permutes both rows and columns. It is the most stable but costs more and scrambles the variable order, so its use is confined largely to research codes.
When pivoting cannot help. If a whole column of the remaining submatrix is zero, the matrix is singular and no rearrangement helps. Pivoting cannot create a nonzero pivot where none exists.
Pivoting reorders rows or columns so the divisor is as large as possible, avoiding a tiny pivot and its round off← Previous: NM-2 Lower Tier | 🏠 Index | Next: NM-3.5 Gauss-Seidel Iteration →