Tutorials › Statistical Learning (Graduate) › Preconditioning and Spectral Conditioning

Spectral Regularization Methods · Tutorial 761 of 989

Preconditioning and Spectral Conditioning

Learn how preconditioners reshape singular values, when they leave an estimator unchanged, and how a changed penalty can alter statistical bias and variance.

Advanced 12 min read

What You'll Learn

  • Define spectral conditioning using singular values and compare an operator with its right-preconditioned form.
  • Derive bounds for how an invertible preconditioner can change the condition number.
  • Show why an exact, unregularized least-squares estimator is invariant to an invertible change of coordinates.
  • Distinguish numerical preconditioning from changing a regularization penalty.
  • Derive the bias and covariance of a linearly regularized estimator.
  • Identify when left preconditioning changes a statistical least-squares problem.

Why Conditioning and Statistical Accuracy Are Different

Inverse problems can be difficult for two distinct reasons. A numerical algorithm may converge slowly because the forward operator has singular values spread across a wide range. Separately, an estimator may be statistically unstable because noise is amplified in directions associated with small singular values. Preconditioning is often used to address the first issue, but it does not automatically resolve the second.

The distinction is easiest to see in a finite-dimensional linear model. Let \(A\) be an \(m\)-by-\(p\) matrix with full column rank, and suppose \(y=Ax+\varepsilon\), where \(x\in\mathbb{R}^p\) is the unknown parameter vector and \(E[\varepsilon]=0\), \(\operatorname{Cov}(\varepsilon)=\Sigma\). A right preconditioner is an invertible \(p\)-by-\(p\) matrix \(P\). Writing \(x=Pz\) changes the forward matrix from \(A\) to \(AP\). This can make the new coordinates numerically more convenient; whether it changes the statistical estimator depends on what objective is solved in those coordinates.

Definition: For a full-column-rank matrix \(M\), its spectral condition number in the Euclidean norm is \(\kappa_2(M)=s_{\max}(M)/s_{\min}(M)\), where \(s_{\max}(M)\) and \(s_{\min}(M)\) are its largest and smallest singular values. A right preconditioner \(P\) replaces \(A\) by \(AP\). Its singular values, not those of \(A\) alone, determine the conditioning of the transformed problem.

The Gram matrix of the transformed operator is \((AP)^T(AP)=P^TA^TAP\). Its eigenvalues are the squared singular values of \(AP\). Thus a well-chosen \(P\) can bring these eigenvalues closer together and reduce the condition number of the system an algorithm must solve. If normal equations are used, their condition number is the square of the condition number of the corresponding design matrix.

How a Right Preconditioner Changes the Spectrum

A preconditioner does not generally multiply every singular value by the same constant. It changes the directions as well as the lengths represented by the operator. The following bounds give a general comparison. They are useful for understanding what is possible, but they do not guarantee that an arbitrary preconditioner improves conditioning.

Theorem: If \(A\) has full column rank and \(P\) is invertible, then \(\kappa_2(AP)\leq\kappa_2(A)\kappa_2(P)\) and \(\kappa_2(AP)\geq\kappa_2(A)/\kappa_2(P)\).

Proof. For any vector \(v\), \(\|APv\|_2\leq \|A\|_2\|P\|_2\|v\|_2\). Taking the supremum over unit vectors gives \(s_{\max}(AP)\leq s_{\max}(A)s_{\max}(P)\). Also, for every unit vector \(v\), \(\|APv\|_2\geq s_{\min}(A)\|Pv\|_2\geq s_{\min}(A)s_{\min}(P)\). Taking the infimum gives \(s_{\min}(AP)\geq s_{\min}(A)s_{\min}(P)\). Dividing these inequalities yields the upper bound. For the lower bound, apply that upper bound to \(A=(AP)P^{-1}\): \(\kappa_2(A)\leq\kappa_2(AP)\kappa_2(P^{-1})=\kappa_2(AP)\kappa_2(P)\). Rearranging proves the result. \(\square\)

Worked Example: A Preconditioner That Equalizes Singular Values

Take \(A=\operatorname{diag}(100,1)\). Its singular values are \(100\) and \(1\), so \(\kappa_2(A)=100\). Choose \(P=\operatorname{diag}(0.01,1)\). Then

$$ AP=\begin{pmatrix}100&0\\0&1\end{pmatrix} \begin{pmatrix}0.01&0\\0&1\end{pmatrix} =\begin{pmatrix}1&0\\0&1\end{pmatrix}=I, \qquad \kappa_2(AP)=1. $$

The transformed system is perfectly conditioned in these coordinates. The bounds are consistent: \(\kappa_2(P)=100\), so they give \(1\leq\kappa_2(AP)\leq 10{,}000\). The bounds are broad here; the exact singular values show the improvement.

The choice of preconditioner matters. A matrix that scales one direction helpfully can scale another in the wrong direction. Conditioning is a property of the pair consisting of the operator and the chosen coordinates, not a guarantee attached to the word “preconditioner.”

Worked Example: A Right Preconditioner Can Worsen Conditioning

Let \(A=\operatorname{diag}(4,1)\), for which \(\kappa_2(A)=4\). First choose \(P_1=\operatorname{diag}(1,4)\). Then \(AP_1=\operatorname{diag}(4,4)\), so \(\kappa_2(AP_1)=1\). Instead choose \(P_2=\operatorname{diag}(1,0.25)\). Now \(AP_2=\operatorname{diag}(4,0.25)\), and \(\kappa_2(AP_2)=4/0.25=16\). Both preconditioners are invertible, but only the first improves conditioning. A preconditioner must be judged by the resulting spectrum.

When Reparameterization Leaves the Estimator Unchanged

Suppose the task is unregularized least squares and \(A\) has full column rank. The unique least-squares estimator is \(\hat{x}=(A^TA)^{-1}A^Ty\). Reparameterizing with \(x=Pz\) and minimizing \(\|APz-y\|_2^2\) changes the matrix in the optimization problem but not the fitted estimator in the original coordinates.

Theorem: If \(A\) has full column rank and \(P\) is invertible, then the minimizer in \(x\) of \(\|Ax-y\|_2^2\) equals \(P\) times the minimizer in \(z\) of \(\|APz-y\|_2^2\), for every \(y\).

Proof. The normal equations in the \(z\) coordinates are \(P^TA^TAP\hat{z}=P^TA^Ty\). The matrix \(P^TA^TAP\) is invertible because \(A\) has full column rank and \(P\) is invertible. Its inverse is \(P^{-1}(A^TA)^{-1}P^{-T}\), as is verified by multiplication. Therefore

$$ P\hat{z} =P(P^TA^TAP)^{-1}P^TA^Ty =P P^{-1}(A^TA)^{-1}P^{-T}P^TA^Ty =(A^TA)^{-1}A^Ty =\hat{x}. $$

Thus the exact estimator in the original coordinates is unchanged, even though the transformed problem may be easier for an iterative solver. \(\square\)

This invariance has a statistical consequence. If \(E[\varepsilon]=0\), the estimator’s expectation, bias, and covariance are unchanged by an exact invertible reparameterization followed by an exact unregularized least-squares solution. For example, under \(\Sigma=\sigma^2I\), the covariance remains \(\sigma^2(A^TA)^{-1}\). Improved conditioning can help compute that estimator more reliably; it does not, by itself, add information to the data or reduce its statistical variance.

Worked Example: Better Conditioning, Same Noise Amplification

Use \(A=\operatorname{diag}(100,1)\), \(P=\operatorname{diag}(0.01,1)\), and the model \(y=Ax+\varepsilon\) with \(\operatorname{Cov}(\varepsilon)=\sigma^2I\). The unregularized estimate is

$$ \hat{x}=A^{-1}y =x+A^{-1}\varepsilon =x+\begin{pmatrix}0.01&0\\0&1\end{pmatrix}\varepsilon. $$

Consequently, \(\operatorname{Cov}(\hat{x})=\sigma^2\operatorname{diag}(0.0001,1)\). The preconditioned matrix is \(AP=I\), but the estimate in \(x\) is still \(A^{-1}y\), so its covariance is still \(\sigma^2\operatorname{diag}(0.0001,1)\). In \(z\) coordinates the noise variances are rescaled, but mapping the estimate back by \(P\) restores the same covariance in \(x\). Numerical conditioning and statistical uncertainty are different quantities.

Regularization Can Change Bias and Variance

The invariance result depends on solving the same unregularized problem. If instead one minimizes \(\|APz-y\|_2^2+\lambda\|z\|_2^2\), the penalty in the original \(x\) coordinates is \(\lambda\|P^{-1}x\|_2^2\), not generally \(\lambda\|x\|_2^2\). The transformed problem can therefore define a different estimator, with different bias and variance.

Definition: For a symmetric positive semidefinite penalty matrix \(R\), the linear penalized least-squares estimator is \(\hat{x}_R=(A^TA+\lambda R)^{-1}A^Ty\), when \(A^TA+\lambda R\) is invertible. In the model \(y=Ax+\varepsilon\), with \(E[\varepsilon]=0\) and covariance \(\Sigma\), its bias is \(E[\hat{x}_R]-x\), and its covariance is \(\operatorname{Cov}(\hat{x}_R)\).

Write \(H=A^TA+\lambda R\). Since \(H\) is symmetric and invertible, \(E[\hat{x}_R]=H^{-1}A^TAx\), so the bias is \(-\lambda H^{-1}Rx\). The estimator is a linear function of \(y\), with matrix \(H^{-1}A^T\); hence

$$ \operatorname{Cov}(\hat{x}_R) =H^{-1}A^T\Sigma A H^{-1}. $$

These expressions show that a changed penalty may reduce variance in some directions while increasing bias. The overall mean squared error under squared Euclidean loss is \(\|E[\hat{x}_R]-x\|_2^2+\operatorname{tr}\{\operatorname{Cov}(\hat{x}_R)\}\). This is a statistical trade-off, not a consequence of conditioning alone.

Key identity: The penalty \(\lambda\|z\|_2^2\) after setting \(x=Pz\) is \(\lambda x^TP^{-T}P^{-1}x\). To preserve the original ridge penalty \(\lambda\|x\|_2^2\), use \(\lambda\|Pz\|_2^2\) in the \(z\) coordinates.

For completeness, if \(H_z=P^TA^TAP+\lambda I\), then the estimator from the \(z\)-penalized problem is \(\hat{x}=P H_z^{-1}P^TA^Ty\). Its covariance is

$$ \operatorname{Cov}(\hat{x}) =P H_z^{-1}P^TA^T\Sigma A P H_z^{-1}P^T. $$

The final factor is \(P^T\): the covariance of a linear map \(By\) is \(B\Sigma B^T\), and here \(B=P H_z^{-1}P^TA^T\). This form is symmetric, as a covariance matrix must be.

Worked Example: A Changed Penalty Changes Bias and Variance

Let \(A=I\), \(\lambda=1\), \(P=\operatorname{diag}(2,1)\), and \(\operatorname{Cov}(\varepsilon)=\sigma^2I\). Ordinary ridge regression in \(x\) uses \(R=I\), so its estimator is \(\hat{x}=\tfrac12 y\). Its bias is \(-\tfrac12 x\), and its covariance is \(\tfrac14\sigma^2 I\).

Now minimize \(\|APz-y\|_2^2+\|z\|_2^2\) and set \(x=Pz\). The penalty in \(x\) is \(x^TP^{-T}P^{-1}x\), giving \(R=\operatorname{diag}(1/4,1)\). Since \(A=I\), the estimator is

$$ \hat{x}=(I+R)^{-1}y =\begin{pmatrix}4/5&0\\0&1/2\end{pmatrix}y. $$

Its expectation is \(\operatorname{diag}(4/5,1/2)x\), so its bias is \(\operatorname{diag}(-1/5,-1/2)x\). Its covariance is \(\sigma^2\operatorname{diag}((4/5)^2,(1/2)^2)=\sigma^2\operatorname{diag}(16/25,1/4)\). Relative to ordinary ridge, the penalty transformation shrinks the first coordinate less: its first-coordinate bias magnitude is smaller for fixed \(x_1\), while its first-coordinate variance is larger. The numerical and statistical effects must therefore be assessed separately.

Left Preconditioning and a Common Pitfall

A left preconditioner acts on the equations or residuals rather than on the unknown coordinates. For a square nonsingular system \(Ax=y\), replacing the equation by \(QAx=Qy\), with invertible \(Q\), preserves the exact solution. For an overdetermined least-squares problem, however, minimizing \(\|Q(Ax-y)\|_2^2\) generally changes the objective to a weighted least-squares problem. It can then change the estimator’s bias and covariance. Applying a transformation to an iterative algorithm solely to solve the original objective is not the same as changing the objective itself.

Common mistake: “The preconditioner reduces the condition number, so it reduces the estimator’s variance.” This conclusion does not follow. Conditioning describes sensitivity of the numerical linear system to perturbations and affects algorithmic convergence and roundoff. Statistical variance is determined by the estimator’s map from the random data to the estimate, together with the noise covariance. An exact coordinate change that preserves the estimator leaves its statistical variance unchanged; a changed penalty may alter it, but also changes bias.

1
Identify the transformation.
Check whether it changes coordinates, transforms residuals, or changes the penalty.
2
Check the exact target.
Determine whether the transformed optimization problem has the same minimizer in the original parameter coordinates.
3
Assess numerical and statistical effects separately.
Use the singular spectrum to assess conditioning; derive the estimator’s expectation and covariance to assess bias and variance.

Preconditioning is valuable because a better-conditioned representation can make an inverse problem more tractable computationally. The crucial distinction is whether the method merely changes how the same estimator is computed or changes the estimator itself. In the first case, conditioning may improve without changing statistical risk. In the second, the resulting bias–variance trade-off must be evaluated on its own merits.

Check Your Understanding

Use the definitions and derivations above to answer the following questions.

  1. For a full-column-rank matrix \(A\) and invertible \(P\), what matrix’s singular values determine the condition number after right preconditioning?
  2. Why does an exact unregularized least-squares estimate in \(x\) remain unchanged under the reparameterization \(x=Pz\)?
  3. What penalty in \(x\) corresponds to adding \(\lambda\|z\|_2^2\) when \(x=Pz\)?
  4. In the linear model, which two quantities determine the covariance of a linear estimator \(By\)?
  5. When can left preconditioning change an overdetermined least-squares estimator?
Clinical Biostats