8 LU Factorization
Triangular systems can be solved one unknown at a time. Gaussian elimination transforms a general system into that form by subtracting multiples of rows. Recording those multipliers produces the LU factorization. The factors separate the work of eliminating the matrix from the cheaper work of solving for a particular right-hand side.
The algebraic construction also exposes the numerical difficulty. A small pivot can produce large multipliers, so practical elimination interchanges rows. We study the factorization first, then examine what pivoting controls and what rounding errors remain.
8.1 Gaussian Elimination
A triangular system can be solved one unknown at a time. In an upper triangular system \(\bU\bx = \by\), the final equation contains only \(x_n\). Once \(x_n\) is known, the preceding equation contains only \(x_{n-1}\), and backward substitution continues until all components are resolved. Gaussian elimination systematically transforms a general system into this upper triangular form by subtracting multiples of each row from the rows beneath it.
Consider the coefficient matrix \[ \begin{align} \bA=\begin{pmatrix}2&1&1\\4&3&3\\2&2&3\end{pmatrix}. \end{align} \] Subtracting twice the first row from the second and once the first row from the third produces \[ \begin{align} \begin{pmatrix}2&1&1\\0&1&1\\0&1&2\end{pmatrix}. \end{align} \] The first column now has the zeros needed for an upper triangular matrix. One more row subtraction completes elimination. To solve a system, we apply each subtraction to the right-hand side as well. To reuse the calculation, we store the multipliers instead.
Complete this elimination. Collect the multipliers in the positions below the diagonal of a matrix \(\bL\) with diagonal entries one, and call the final upper triangular matrix \(\bU\). Multiply the two factors to verify \(\bA=\bL\bU\). Why must \(\bL\) record the multipliers with their original signs rather than the minus signs used in the row subtractions?
Let \(\bA \in \fR^{n \times n}\). An LU factorization of \(\bA\) is a decomposition \[ \begin{align} \bA = \bL\bU, \end{align} \] where \(\bL \in \fR^{n \times n}\) is unit lower triangular (\(\ell_{ii} = 1\) and \(\ell_{ij} = 0\) for \(j > i\)) and \(\bU \in \fR^{n \times n}\) is upper triangular (\(u_{ij} = 0\) for \(i > j\)).
The set of \(n \times n\) unit lower triangular matrices forms a group under matrix multiplication. In particular:
The product of two unit lower triangular matrices is unit lower triangular.
The inverse of a unit lower triangular matrix is unit lower triangular.
The determinant of every unit lower triangular matrix equals one.
For \(i<j\), show that every term in \((\bL_1\bL_2)_{ij}\) vanishes. Compute the diagonal. Next solve \(\bL\bx_j=\be_j\) by forward substitution and show that \(x_{ij}=0\) for \(i<j\) and \(x_{jj}=1\). Deduce the assertions about the inverse and determinant.
Let \(\bA^{(0)} = \bA\). At step \(k\) of Gaussian elimination, assuming the pivot entry \(a_{kk}^{(k-1)} \neq 0\), the subdiagonal entries in column \(k\) are annihilated by applying the elementary elimination matrix \[ \begin{align} \bM_k = \bI - \boldsymbol{\ell}_k \be_k^T, \end{align} \] where \(\boldsymbol{\ell}_k = (0, ..., 0, \ell_{k+1,k}, ..., \ell_{n,k})^T\) contains the multipliers \(\ell_{ik} = a_{ik}^{(k-1)} / a_{kk}^{(k-1)}\). After \(n-1\) elimination steps, the upper triangular factor is \(\bU = \bM_{n-1} ... \bM_1 \bA\). The lower triangular factor is the inverse of the accumulated elimination operations: \[ \begin{align} \bL = \bM_1^{-1} \bM_2^{-1} ... \bM_{n-1}^{-1} = \bI + \sum_{k=1}^{n-1} \boldsymbol{\ell}_k \be_k^T. \end{align} \] Consequently, the entries of \(\bL\) strictly below the main diagonal are precisely the multipliers computed during Gaussian elimination.
The inverse of an elementary elimination matrix \(\bM_k = \bI - \boldsymbol{\ell}_k \be_k^T\) is \(\bM_k^{-1} = \bI + \boldsymbol{\ell}_k \be_k^T\). This identity follows from the fact that the first \(k\) entries of \(\boldsymbol{\ell}_k\) are zero, which implies \(\be_k^T \boldsymbol{\ell}_k = 0\) and therefore \[ \begin{align} (\bI - \boldsymbol{\ell}_k \be_k^T)(\bI + \boldsymbol{\ell}_k \be_k^T) = \bI - \boldsymbol{\ell}_k \be_k^T + \boldsymbol{\ell}_k \be_k^T - \boldsymbol{\ell}_k (\be_k^T \boldsymbol{\ell}_k) \be_k^T = \bI. \end{align} \] Writing \(\bN_k=\boldsymbol\ell_k\be_k^T\), the condition \(\be_k^T\boldsymbol\ell_k=0\) says \(\bN_k^2=\bzero\). Hence both \((\bI-\bN_k)(\bI+\bN_k)\) and the product in the reverse order equal the identity. This verifies both sides of the proposed inverse.
Next, consider the product of two successive inverse matrices \(\bM_j^{-1} \bM_k^{-1}\) with \(j < k\). Because \(\be_j^T \boldsymbol{\ell}_k = 0\), the cross term vanishes: \[ \begin{align} (\bI + \boldsymbol{\ell}_j \be_j^T)(\bI + \boldsymbol{\ell}_k \be_k^T) = \bI + \boldsymbol{\ell}_j \be_j^T + \boldsymbol{\ell}_k \be_k^T + \boldsymbol{\ell}_j (\be_j^T \boldsymbol{\ell}_k) \be_k^T = \bI + \boldsymbol{\ell}_j \be_j^T + \boldsymbol{\ell}_k \be_k^T. \end{align} \] By induction, the product \(\bM_1^{-1} ... \bM_{n-1}^{-1}\) simply places each column of multipliers into column \(k\) of the identity matrix without modifying any previously placed multipliers. Multiplying \(\bU = \bM_{n-1} ... \bM_1 \bA\) on the left by \(\bL\) yields \(\bA = \bL\bU\).
The ordering matters. Multiplying the final upper matrix on the left successively by \(\bM_{n-1}^{-1},...,\bM_1^{-1}\) undoes the row operations in reverse order. Grouping the inverses as \(\bL=\bM_1^{-1}\cdots\bM_{n-1}^{-1}\) therefore gives \(\bL\bU=\bA\). The vanishing cross terms show that these inverse operations record precisely the multipliers in the lower triangle.
A matrix \(\bA \in \fR^{n \times n}\) has a unique LU factorization with unit lower triangular \(\bL\) and nonsingular upper triangular \(\bU\) if and only if every leading principal submatrix \(\bA_k = \bA[1:k, 1:k]\) is nonsingular for each \(k = 1, ..., n\).
We proceed by induction on the matrix dimension \(n\). For \(n = 1\), \(\bA = (a_{11})\). Because \(\det(\bA_1) = a_{11} \neq 0\), the unique factorization is \(\bL = (1)\) and \(\bU = (a_{11})\). Assume the result holds for matrices of dimension \(n-1\). Partition the \(n \times n\) matrix \(\bA\) into blocks: \[ \begin{align} \bA = \begin{pmatrix} \bA_{n-1} & \bc \\ \bd^T & a_{nn} \end{pmatrix}, \end{align} \] where \(\bA_{n-1} \in \fR^{(n-1) \times (n-1)}\), \(\bc, \bd \in \fR^{n-1}\), and \(a_{nn} \in \fR\). Every leading principal block of \(\bA_{n-1}\) is also a leading principal block of \(\bA\), so it satisfies the theorem’s hypotheses. This verifies the condition needed to invoke the induction hypothesis on the smaller matrix.
By the induction hypothesis, \(\bA_{n-1}\) has a unique factorization \(\bA_{n-1} = \bL_{n-1} \bU_{n-1}\) with \(\bL_{n-1}\) unit lower triangular and \(\bU_{n-1}\) nonsingular. We seek block factors \[ \begin{align} \bL = \begin{pmatrix} \bL_{n-1} & \bzero \\ \boldsymbol{\ell}^T & 1 \end{pmatrix}, \qquad \bU = \begin{pmatrix} \bU_{n-1} & \bu \\ \bzero^T & u_{nn} \end{pmatrix}. \end{align} \] The zero lower-left block of \(\bU\) and zero upper-right block of \(\bL\) are required by triangularity. The diagonal one in \(\bL\) is required by the unit-diagonal convention. Only the new vectors and the final scalar remain undetermined.
Multiplying \(\bL\) and \(\bU\) and equating block by block gives: \[ \begin{align} \bL_{n-1}\bu = \bc, \qquad \boldsymbol{\ell}^T \bU_{n-1} = \bd^T, \qquad \boldsymbol{\ell}^T\bu + u_{nn} = a_{nn}. \end{align} \] Because \(\bL_{n-1}\) is unit lower triangular (hence invertible), \(\bu = \bL_{n-1}^{-1}\bc\) is uniquely determined. Because \(\bU_{n-1}\) is nonsingular, \(\boldsymbol{\ell}^T = \bd^T \bU_{n-1}^{-1}\) is uniquely determined. Finally, the scalar diagonal entry is uniquely determined by \(u_{nn} = a_{nn} - \boldsymbol{\ell}^T\bu\). Taking determinants of the block decomposition gives \[ \begin{align} \det(\bA) = \det(\bL)\det(\bU) = (1 \cdot \det(\bL_{n-1})) (\det(\bU_{n-1}) \cdot u_{nn}) = \det(\bA_{n-1}) u_{nn}. \end{align} \] Because \(\det(\bA) \neq 0\) and \(\det(\bA_{n-1}) \neq 0\), we have \(u_{nn} = \det(\bA)/\det(\bA_{n-1}) \neq 0\), which ensures that \(\bU\) is nonsingular. This completes the induction.
For necessity, if \(\bA=\bL\bU\) with \(\bU\) nonsingular, its leading block satisfies \(\bA_k=\bL_k\bU_k\). Both triangular factors are nonsingular, so every \(\bA_k\) is nonsingular. This proves the converse as well.
For the converse, triangularity ensures that the first \(k\) rows and columns of the product involve only the leading factors: no omitted trailing index contributes. The diagonal of \(\bU\) is nonzero because its determinant is their product and \(\bU\) is nonsingular. Therefore every leading triangular block \(\bU_k\) is nonsingular. The unit lower block \(\bL_k\) is nonsingular as well, proving every leading block of \(\bA\) is nonsingular.
8.2 Triangular Solves and Computational Complexity
Let \(\bL \in \fR^{n \times n}\) be unit lower triangular and let \(\bU \in \fR^{n \times n}\) be nonsingular upper triangular. Solving \(\bA\bx = \bb\) decouples into two triangular steps:
Forward substitution (\(\bL\by = \bb\)): \[ \begin{align} y_1 = b_1, \qquad y_i = b_i - \sum_{j=1}^{i-1} \ell_{ij} y_j \quad (i = 2, ..., n). \end{align} \]
Backward substitution (\(\bU\bx = \by\)): \[ \begin{align} x_n = \frac{y_n}{u_{nn}}, \qquad x_i = \frac{1}{u_{ii}} \left( y_i - \sum_{j=i+1}^n u_{ij} x_j \right) \quad (i = n-1, ..., 1). \end{align} \]
For a general dense matrix \(\bA \in \fR^{n \times n}\), computing the LU factorization requires asymptotically \(\frac{2}{3}n^3\) floating-point operations. Evaluating the forward and backward triangular substitution steps requires \(2n^2-n\) flops for each right-hand side vector \(\bb\).
At step \(k\) of elimination, calculating the \(n-k\) multipliers \(\ell_{ik} = a_{ik}/a_{kk}\) requires \(n-k\) divisions. Updating the active \((n-k) \times (n-k)\) submatrix via \(a_{ij} \leftarrow a_{ij} - \ell_{ik}a_{kj}\) requires one multiplication and one subtraction for each entry, totaling \(2(n-k)^2\) operations. Summing over all \(n-1\) elimination steps gives \[ \begin{align} \sum_{k=1}^{n-1} \left[ (n-k) + 2(n-k)^2 \right] &=2\sum_{m=1}^{n-1}m^2+\sum_{m=1}^{n-1}m\\ &=\frac{(n-1)n(2n-1)}{3}+\frac{(n-1)n}{2}\\ &=\frac23n^3-\frac12n^2-\frac16n. \end{align} \] The summation index \(m=n-k\) is the active trailing size. Expanding \((n-1)n(2n-1)/3\) gives \((2n^3-3n^2+n)/3\), and adding \((n^2-n)/2\) gives the stated polynomial. Its leading coefficient is \(2/3\), while the remaining terms have smaller order.
For forward substitution with unit diagonal, row \(i\) requires \(i-1\) multiplications and \(i-1\) subtractions, totaling \(\sum_{i=1}^n 2(i-1) = n^2 - n\) flops. For backward substitution, row \(i\) requires \(n-i\) multiplications, \(n-i\) subtractions, and one division, totaling \(\sum_{i=1}^n (2(n-i) + 1) = n^2\) flops. The combined solve phase requires \(2n^2 - n \approx 2n^2\) flops.
The factors can be reused for every new right-hand side. The quadratic solve count is therefore paid once per right-hand side, whereas the cubic factorization count is paid only when the coefficient matrix must be factored again. This is the distinction behind the complexity claim.
8.3 Partial Pivoting and the Growth Factor
In floating-point arithmetic, unpivoted Gaussian elimination fails if a pivot is zero, and it can be unstable when a pivot is small relative to the subdiagonal entries. Dividing by a small pivot creates large multipliers and can amplify rounding errors. Partial pivoting interchanges rows so that the pivot has maximal absolute value in its column. It keeps every multiplier at most one in magnitude and is usually stable, but it does not guarantee a small growth factor. The Wilkinson example below shows the exceptional worst case.
Gaussian elimination with partial pivoting produces the decomposition \[ \begin{align} \bP\bA = \bL\bU, \end{align} \] where \(\bP \in \fR^{n \times n}\) is a permutation matrix recording row swaps, \(\bL \in \fR^{n \times n}\) is unit lower triangular with all subdiagonal entries bounded by \(|\ell_{ij}| \leq 1\), and \(\bU \in \fR^{n \times n}\) is upper triangular.
Hand execution of unpivoted versus pivoted LU. Consider the matrix \[ \begin{align} \bA = \begin{pmatrix} 10^{-4} & 1 \\ 1 & 1 \end{pmatrix}, \qquad \bb = \begin{pmatrix} 1 \\ 2 \end{pmatrix}. \end{align} \]
Compute the unpivoted LU factorization \(\bA = \bL\bU\) in exact arithmetic, and evaluate the multiplier \(\ell_{21}\).
Simulate standard 3-digit floating-point arithmetic with rounding. Show that unpivoted elimination computes the erroneous solution \(\hat{\bx} = (0, 1)^T\).
Compute the pivoted factorization \(\bP\bA = \bL\bU\) using partial pivoting. Verify that in 3-digit arithmetic, the computed solution recovers \((1, 1)^T\) with negligible error.
Let \(\bA \in \fR^{n \times n}\). The growth factor \(\rho\) of Gaussian elimination is defined by \[ \begin{align} \rho = \frac{\max_{i,j,k} |a_{ij}^{(k)}|}{\max_{i,j} |a_{ij}|}, \end{align} \] where \(a_{ij}^{(k)}\) denotes the entries of the active submatrix after step \(k\). For Gaussian elimination with partial pivoting, the growth factor satisfies \[ \begin{align} \rho \leq 2^{n-1}. \end{align} \]
Let \(M_k = \max_{i,j} |a_{ij}^{(k)}|\) denote the maximum absolute entry of the active matrix after \(k\) elimination steps, with \(M_0 = \max_{i,j} |a_{ij}|\). At step \(k\), partial pivoting guarantees that the pivot \(|a_{kk}^{(k-1)}| = \max_{i \geq k} |a_{ik}^{(k-1)}|\), which ensures that all multipliers satisfy \[ \begin{align} |\ell_{ik}| = \left| \frac{a_{ik}^{(k-1)}}{a_{kk}^{(k-1)}} \right| \leq 1 \qquad \text{for all } i = k+1, ..., n. \end{align} \] Swapping rows changes no entry magnitudes. Thus the only possible growth in this step comes from the subtraction update, and the pivot comparison bounds the multiplier used in each such subtraction.
The elimination update rule is \(a_{ij}^{(k)} = a_{ij}^{(k-1)} - \ell_{ik} a_{kj}^{(k-1)}\). Applying the triangle inequality yields \[ \begin{align} |a_{ij}^{(k)}| \leq |a_{ij}^{(k-1)}| + |\ell_{ik}| |a_{kj}^{(k-1)}| \leq M_{k-1} + (1) M_{k-1} = 2 M_{k-1}. \end{align} \] Taking the maximum over all active indices gives \(M_k \leq 2 M_{k-1}\). By induction, \(M_{n-1} \leq 2^{n-1} M_0\). Dividing by \(M_0\) establishes \(\rho \leq 2^{n-1}\).
For every intermediate step \(k\), the same induction gives \(M_k\leq2^kM_0\leq2^{n-1}M_0\). Pivot rows already retained in \(\bU\) were bounded when they left the active matrix. Hence the bound applies to the maximum across all stages, which is the maximum in the growth-factor definition, not only to the final active entry.
The Wilkinson counterexample and exponential growth. Consider the \(n \times n\) matrix \[ \begin{align} \bW_n = \begin{pmatrix} 1 & 0 & 0 & ... & 0 & 1 \\ -1 & 1 & 0 & ... & 0 & 1 \\ -1 & -1 & 1 & ... & 0 & 1 \\ \vdots & \vdots & \vdots & \ddots & \vdots & \vdots \\ -1 & -1 & -1 & ... & 1 & 1 \\ -1 & -1 & -1 & ... & -1 & 1 \end{pmatrix}. \end{align} \]
Assume that ties in pivot selection keep the current row. Show that partial pivoting performs no row swaps on \(\bW_n\) because every diagonal entry already has absolute value 1, matching the maximum in its column.
Compute the entries of the final column after each elimination step \(k = 1, 2, ..., n-1\).
Prove that the final bottom-right entry grows as \(u_{nn} = 2^{n-1}\), confirming that the bound in the referenced result is tight.
The growth factor matters because it controls the rounding errors committed during elimination. The next theorem expresses these errors as a perturbation of \(\bA\). It uses the unit roundoff \(u\) of the referenced result and the constant \(\gamma_k=ku/(1-ku)\), defined whenever \(ku<1\). Absolute values and inequalities between matrices are taken entrywise.
Let \(\bA\in\fR^{n\times n}\) be nonsingular, and suppose Gaussian elimination with partial pivoting runs to completion in floating-point arithmetic. Assume \(3nu<1\), where \(u\) is the unit roundoff, and exclude overflow and underflow from the rounding model. Let \(\bP\) be the computed permutation, let \(\hat{\bL}\) and \(\hat{\bU}\) be the computed factors, and let \(\hat{\bx}\) be the solution of \(\bA\bx=\bb\) computed by forward and backward substitution. Then \[ \begin{align} (\bA+\Delta\bA)\hat{\bx}=\bb, \qquad |\bP\,\Delta\bA|\leq\gamma_{3n}|\hat{\bL}||\hat{\bU}|. \end{align} \]
We use the floating-point model and assume that underflow and overflow do not invalidate it. Absolute values and inequalities between matrices below are entrywise. The standard componentwise analysis is developed in Higham (2002).
We first record how repeated scalar rounding is bounded. If \(|\delta_j|\leq u\) and \(\rho_j=\pm1\), each factor \((1+\delta_j)^{\rho_j}\) lies between \(1-u\) and \((1-u)^{-1}\). A product of at most \(s\) factors therefore lies between \((1-u)^s\) and \((1-u)^{-s}\). Bernoulli’s inequality gives \((1-u)^s\geq1-su\). If \(su<1\), its reciprocal is at most \((1-su)^{-1}=1+\gamma_s\). Thus the product can be written \(1+\theta_s\) with \(|\theta_s|\leq\gamma_s\).
To apply this bound to a row calculation, consider computing \[ \begin{align} x=\frac{a-\sum_{k=1}^{j-1}b_kc_k}{d}. \end{align} \] Let a multiplication have error \(\mu_k\), each successive subtraction error \(\delta_k\), and the final division error \(\delta_d\). Expanding the successive computed subtractions and moving their factors to the other side gives an exact identity of the form \[ \begin{align} a=d\hat x(1+\theta_0)+\sum_{k=1}^{j-1}b_kc_k(1+\theta_k), \qquad |\theta_k|\leq\gamma_j. \end{align} \] Here the coefficient of \(d\hat x\) is \([(1+\delta_d)\prod_{l=1}^{j-1}(1+\delta_l)]^{-1}\). The coefficient of \(b_kc_k\) is \((1+\mu_k)/\prod_{l=1}^{k-1}(1+\delta_l)\). Each involves at most \(j\) rounding factors or inverse factors, so the preceding product bound applies. Omitting the division gives the same bound for a computed upper-factor entry.
For elimination, these are exactly the scalar recurrences determining entries of the computed factors. Applying the identity to entry \((i,j)\) of their product, with at most \(n\) factors, gives \[ \begin{align} \hat{\bL}\hat{\bU}=\bP\bA+\bE, \qquad |\bE|\leq\gamma_n|\hat{\bL}||\hat{\bU}|. \end{align} \] To see the entrywise estimate, subtract the unweighted sum \(\sum_k\hat\ell_{ik}\hat u_{kj}\) from the weighted exact row identity. The error is a sum of these same products times coefficients of magnitude at most \(\gamma_n\). The triangle inequality gives the displayed nonnegative matrix product. Row permutations only relabel entries and introduce no rounding.
Apply the same scalar calculation to forward and backward substitution. It produces triangular perturbations satisfying \[ \begin{align} (\hat{\bL}+\Delta\bL)\hat{\by}&=\bP\bb, &|\Delta\bL|&\leq\gamma_n|\hat{\bL}|,\\ (\hat{\bU}+\Delta\bU)\hat{\bx}&=\hat{\by}, &|\Delta\bU|&\leq\gamma_n|\hat{\bU}|. \end{align} \] Eliminate \(\hat{\by}\) by substituting the second equality into the first. The coefficient matrix of the resulting system is \[ \begin{align} \bP\bA+\bE+\hat{\bL}\Delta\bU +\Delta\bL\hat{\bU}+\Delta\bL\Delta\bU. \end{align} \] Define \(\bP\Delta\bA\) to be the sum of the four perturbation terms. Then \((\bA+\Delta\bA)\hat{\bx}=\bb\), and the triangle inequality gives \[ \begin{align} |\bP\Delta\bA| \leq(3\gamma_n+\gamma_n^2)|\hat{\bL}||\hat{\bU}|. \end{align} \] For \(3nu<1\), \(1+3\gamma_n+\gamma_n^2\leq(1+\gamma_n)^3=(1-nu)^{-3}\leq(1-3nu)^{-1}=1+\gamma_{3n}\). The penultimate inequality follows from \((1-nu)^3\geq1-3nu\). Subtracting one proves the stated bound with \(\gamma_{3n}\).
Under the hypotheses of the referenced result, let \(\rho\) be the growth factor of the computed elimination. Then \[ \begin{align} \frac{\|\Delta\bA\|_\infty}{\|\bA\|_\infty}\leq n^2\gamma_{3n}\,\rho. \end{align} \]
Let \(a_{\max}=\max_{i,j}|a_{ij}|\). Partial pivoting bounds each computed multiplier in magnitude by one under the usual round-to-nearest model. The diagonal entries of \(\hat{\bL}\) are one, so every entry of \(|\hat{\bL}|\) is at most one. By the definition of growth, every entry of \(|\hat{\bU}|\) is at most \(\rho a_{\max}\).
Entry \((i,j)\) of their product is a sum of \(n\) nonnegative terms. Each term is at most \(\rho a_{\max}\), giving \[ \begin{align} (|\hat{\bL}||\hat{\bU}|)_{ij} =\sum_{k=1}^n|\hat\ell_{ik}||\hat u_{kj}| \leq n\rho a_{\max}. \end{align} \] The preceding componentwise theorem therefore bounds each entry of \(|\bP\Delta\bA|\) by \(\gamma_{3n}n\rho a_{\max}\).
The infinity norm is a maximum row sum. Each row contains \(n\) entries, so \[ \begin{align} \|\bP\Delta\bA\|_\infty \leq n(\gamma_{3n}n\rho a_{\max}) =n^2\gamma_{3n}\rho a_{\max}. \end{align} \] A row permutation changes only the order of row sums, not their maximum. Thus \(\|\bP\Delta\bA\|_\infty=\|\Delta\bA\|_\infty\). Finally \(a_{\max}\leq\|\bA\|_\infty\), because the row containing a largest entry has a row sum at least that large. Divide by \(\|\bA\|_\infty>0\) to obtain the claimed relative estimate.
the referenced result shows that partial pivoting is backward stable whenever the growth factor is modest, and the referenced result then bounds the forward error by the condition number. The worst-case bound \(\rho\leq2^{n-1}\) of the referenced result is attained by special matrices such as the Wilkinson matrix in the exercises below, but such growth is rarely observed. For random matrices, Trefethen and Schreiber measured average growth factors of about \(n^{2/3}\) for partial pivoting (Trefethen and Schreiber 1990). The factor \(n^2\) in the corollary is also pessimistic, since the bound assumes that every rounding error takes its worst possible value and sign.
8.4 Iterative Refinement
the referenced result bounds the backward error of the computed solution, but the forward error can still be as large as \(\kappa(\bA)\) times that backward error. Iterative refinement reuses the computed factors to reduce the forward error. Each step costs one residual evaluation and one pair of triangular solves, which is small compared with the factorization.
Let \(\hat{\bx}^{(0)}\) be computed from the factorization \(\bP\bA\approx\hat{\bL}\hat{\bU}\). For \(k=0,1,2,...\):
Compute the residual \(\br^{(k)}=\bb-\bA\hat{\bx}^{(k)}\), if possible in higher precision.
Solve the correction equation \(\bA\bd^{(k)}=\br^{(k)}\) with the existing factors.
Update \(\hat{\bx}^{(k+1)}=\hat{\bx}^{(k)}+\bd^{(k)}\).
Refinement improves the forward error when the factors are accurate enough to give a useful correction and the residual is computed more accurately than the factorization. The precise convergence conditions depend on \(\kappa(\bA)\) and on the precisions used for the factorization, the residual, and the update (Higham 2002).
8.5 Further Exercises
Banded matrices and fill-in. Let \(\bA \in \fR^{n \times n}\) be a tridiagonal matrix (\(a_{ij} = 0\) for \(|i - j| > 1\)).
Prove that without pivoting, the factors \(\bL\) and \(\bU\) retain the tridiagonal sparsity structure, meaning \(\bL\) has bandwidth 1 on the subdiagonal and \(\bU\) has bandwidth 1 on the superdiagonal.
Calculate the flop count for unpivoted tridiagonal LU factorization and forward/backward substitution. Show that the total work is \(O(n)\) instead of \(O(n^3)\).
Explain what happens to the upper bandwidth of \(\bU\) when partial pivoting performs row interchanges.
Block LU decomposition and the Schur complement. Partition a nonsingular matrix \(\bA\) into blocks \[ \begin{align} \bA = \begin{pmatrix} \bA_{11} & \bA_{12} \\ \bA_{21} & \bA_{22} \end{pmatrix}, \end{align} \] where \(\bA_{11} \in \fR^{k \times k}\) is nonsingular.
Show that block Gaussian elimination factors \(\bA\) as \[ \begin{align} \bA = \begin{pmatrix} \bI & \bzero \\ \bA_{21}\bA_{11}^{-1} & \bI \end{pmatrix} \begin{pmatrix} \bA_{11} & \bA_{12} \\ \bzero & \mathbf{S} \end{pmatrix}, \end{align} \] where \(\mathbf{S} = \bA_{22} - \bA_{21}\bA_{11}^{-1}\bA_{12}\) is the Schur complement of \(\bA_{11}\) in \(\bA\).
Prove that \(\det(\bA) = \det(\bA_{11})\det(\mathbf{S})\).
Relate the Schur complement \(\mathbf{S}\) to the active submatrix remaining after \(k\) steps of standard Gaussian elimination.
Determinants and multiple right-hand sides. Let \(\bP\bA = \bL\bU\) be the computed LU factorization with partial pivoting.
Prove that \(\det(\bA) = (-1)^s \prod_{i=1}^n u_{ii}\), where \(s\) is the number of row interchanges recorded by \(\bP\).
Explain why computing the determinant via \(\bP\bA = \bL\bU\) requires \(O(n^3)\) flops, whereas evaluating the Leibniz expansion formula requires \(O(n!)\) flops.
For \(m\) distinct right-hand side vectors \(\bb_1, ..., \bb_m\), analyze the computational cost of solving \(\bA\bx_j = \bb_j\) by reusing the single factorization \(\bP\bA = \bL\bU\) versus computing \(m\) independent solves from scratch.