Jump to content
Wikipedia The Free Encyclopedia

Minimal residual method

From Wikipedia, the free encyclopedia
Computational method
A comparison of the norm of error and residual in the CG method (blue) and the MINRES method (green). The matrix used comes from a 2D boundary-value problem.

The Minimal Residual Method or MINRES is a Krylov subspace method for the iterative solution of symmetric linear equation systems. It was proposed by mathematicians Christopher Conway Paige and Michael Alan Saunders in 1975.[1]

In contrast to the popular CG method, the MINRES method does not assume that the matrix is positive definite, only the symmetry of the matrix is mandatory.

GMRES vs. MINRES

[edit ]

The GMRES method is essentially a generalization of MINRES for arbitrary matrices. Both minimize the 2-norm of the residual and do the same calculations in exact arithmetic when the matrix is symmetric. MINRES is a short-recurrence method with a constant memory requirement, whereas GMRES requires storing the whole Krylov space, so its memory requirement is roughly proportional to the number of iterations. On the other hand, GMRES tends to suffer less from loss of orthogonality.[1] [2]

Properties of the MINRES method

[edit ]

The MINRES method iteratively calculates an approximate solution of a linear system of equations of the form A x = b , {\displaystyle Ax=b,} {\displaystyle Ax=b,} where A R n × n {\displaystyle A\in \mathbb {R} ^{n\times n}} {\displaystyle A\in \mathbb {R} ^{n\times n}} is a symmetric matrix and b R n {\displaystyle b\in \mathbb {R} ^{n}} {\displaystyle b\in \mathbb {R} ^{n}} a vector.

For this, the norm of the residual r ( x ) := b A x {\displaystyle r(x):=b-Ax} {\displaystyle r(x):=b-Ax} in a k {\displaystyle k} {\displaystyle k}-dimensional Krylov subspace V k = x 0 + span { r 0 , A r 0 , A k 1 r 0 } {\displaystyle V_{k}=x_{0}+\operatorname {span} \{r_{0},Ar_{0}\ldots ,A^{k-1}r_{0}\}} {\displaystyle V_{k}=x_{0}+\operatorname {span} \{r_{0},Ar_{0}\ldots ,A^{k-1}r_{0}\}} is minimized. Here x 0 R n {\displaystyle x_{0}\in \mathbb {R} ^{n}} {\displaystyle x_{0}\in \mathbb {R} ^{n}} is an initial value (often zero) and r 0 := r ( x 0 ) {\displaystyle r_{0}:=r(x_{0})} {\displaystyle r_{0}:=r(x_{0})}.

More precisely, we define the approximate solutions x k {\displaystyle x_{k}} {\displaystyle x_{k}} through x k := a r g m i n x V k r ( x ) , {\displaystyle x_{k}:=\mathrm {argmin} _{x\in V_{k}}\|r(x)\|,} {\displaystyle x_{k}:=\mathrm {argmin} _{x\in V_{k}}\|r(x)\|,} where {\displaystyle \|\cdot \|} {\displaystyle \|\cdot \|} is the standard Euclidean norm on R n {\displaystyle \mathbb {R} ^{n}} {\displaystyle \mathbb {R} ^{n}}.

Because of the symmetry of A {\displaystyle A} {\displaystyle A}, unlike in the GMRES method, it is possible to carry out this minimization process recursively, storing only two previous steps (short recurrence). This saves memory.

MINRES algorithm

[edit ]

Note: The MINRES method is more complicated than the algebraically equivalent Conjugate Residual method. The Conjugate Residual (CR) method was therefore produced below as a substitute. It differs from MINRES in that in MINRES, the columns of a basis of the Krylov space (denoted below by p k {\displaystyle p_{k}} {\displaystyle p_{k}}) can be orthogonalized, whereas in CR their images (below labeled with s k {\displaystyle s_{k}} {\displaystyle s_{k}}) can be orthogonalized via the Lanczos recursion. There are more efficient and preconditioned variants with fewer AXPYs. Compare with the article.

First you choose x 0 R n {\displaystyle x_{0}\in \mathbb {R} ^{n}} {\displaystyle x_{0}\in \mathbb {R} ^{n}} arbitrary and compute r 0 = b A x 0 p 0 = r 0 s 0 = A p 0 {\displaystyle {\begin{aligned}r_{0}&=b-Ax_{0}\\p_{0}&=r_{0}\\s_{0}&=Ap_{0}\end{aligned}}} {\displaystyle {\begin{aligned}r_{0}&=b-Ax_{0}\\p_{0}&=r_{0}\\s_{0}&=Ap_{0}\end{aligned}}}

Then we iterate for k = 1 , 2 , {\displaystyle k=1,2,\dots } {\displaystyle k=1,2,\dots } in the following steps:

  • Compute x k , r k {\displaystyle x_{k},r_{k}} {\displaystyle x_{k},r_{k}} through

    α k 1 = r k 1 , s k 1 s k 1 , s k 1 {\displaystyle \alpha _{k-1}={\frac {\langle r_{k-1},s_{k-1}\rangle }{\langle s_{k-1},s_{k-1}\rangle }}} {\displaystyle \alpha _{k-1}={\frac {\langle r_{k-1},s_{k-1}\rangle }{\langle s_{k-1},s_{k-1}\rangle }}} x k = x k 1 + α k 1 p k 1 {\displaystyle x_{k}=x_{k-1}+\alpha _{k-1}p_{k-1}} {\displaystyle x_{k}=x_{k-1}+\alpha _{k-1}p_{k-1}} r k = r k 1 α k 1 s k 1 {\displaystyle r_{k}=r_{k-1}-\alpha _{k-1}s_{k-1}} {\displaystyle r_{k}=r_{k-1}-\alpha _{k-1}s_{k-1}} if r k {\displaystyle \|r_{k}\|} {\displaystyle \|r_{k}\|} is smaller than a specified tolerance, the algorithm is interrupted with the approximate solution x k {\displaystyle x_{k}} {\displaystyle x_{k}}. Otherwise, a new descent direction p k {\displaystyle p_{k}} {\displaystyle p_{k}} is calculated through p k s k 1 {\displaystyle p_{k}\leftarrow s_{k-1}} {\displaystyle p_{k}\leftarrow s_{k-1}}

    s k A s k 1 {\displaystyle s_{k}\leftarrow As_{k-1}} {\displaystyle s_{k}\leftarrow As_{k-1}}
  • for l = 1 , 2 {\displaystyle l=1,2} {\displaystyle l=1,2} (the step l = 2 {\displaystyle l=2} {\displaystyle l=2} is not carried out in the first iteration step) calculate: β k , l = s k , s k l s k l , s k l {\displaystyle \beta _{k,l}={\frac {\langle s_{k},s_{k-l}\rangle }{\langle s_{k-l},s_{k-l}\rangle }}} {\displaystyle \beta _{k,l}={\frac {\langle s_{k},s_{k-l}\rangle }{\langle s_{k-l},s_{k-l}\rangle }}} p k p k β k , l p k l {\displaystyle p_{k}\leftarrow p_{k}-\beta _{k,l}p_{k-l}} {\displaystyle p_{k}\leftarrow p_{k}-\beta _{k,l}p_{k-l}} s k s k β k , l s k l {\displaystyle s_{k}\leftarrow s_{k}-\beta _{k,l}s_{k-l}} {\displaystyle s_{k}\leftarrow s_{k}-\beta _{k,l}s_{k-l}}

Convergence rate of the MINRES method

[edit ]

In the case of positive definite matrices, the convergence rate of the MINRES method can be estimated in a way similar to that of the CG method.[3] In contrast to the CG method, however, the estimation does not apply to the errors of the iterates, but to the residual. The following applies:

r k 2 ( κ ( A ) 1 κ ( A ) + 1 ) k r 0 , {\displaystyle \|r_{k}\|\leq 2\left({\frac {{\sqrt {\kappa (A)}}-1}{{\sqrt {\kappa (A)}}+1}}\right)^{k}\|r_{0}\|,} {\displaystyle \|r_{k}\|\leq 2\left({\frac {{\sqrt {\kappa (A)}}-1}{{\sqrt {\kappa (A)}}+1}}\right)^{k}\|r_{0}\|,}

where κ ( A ) {\displaystyle \kappa (A)} {\displaystyle \kappa (A)} is the condition number of matrix A {\displaystyle A} {\displaystyle A}. Because A {\displaystyle A} {\displaystyle A} is normal, we have κ ( A ) = | λ max ( A ) | | λ min ( A ) | , {\displaystyle \kappa (A)={\frac {\left|\lambda _{\text{max}}(A)\right|}{\left|\lambda _{\text{min}}(A)\right|}},} {\displaystyle \kappa (A)={\frac {\left|\lambda _{\text{max}}(A)\right|}{\left|\lambda _{\text{min}}(A)\right|}},} where λ max ( A ) {\displaystyle \lambda _{\text{max}}(A)} {\displaystyle \lambda _{\text{max}}(A)} and λ min ( A ) {\displaystyle \lambda _{\text{min}}(A)} {\displaystyle \lambda _{\text{min}}(A)} are maximal and minimal eigenvalues of A {\displaystyle A} {\displaystyle A}, respectively.

Implementation in GNU Octave / MATLAB

[edit ]
function[x, r] = minres(A, b, x0, maxit, tol)
x=x0;
r=b-A*x0;
p0=r;
s0=A*p0;
p1=p0;
s1=s0;
foriter=1:maxit
p2=p1;p1=p0;
s2=s1;s1=s0;
alpha=r'*s1/(s1'*s1);
x=x+alpha*p1;
r=r-alpha*s1;
if(r'*r<tol^2)
break
end
p0=s1;
s0=A*s1;
beta1=s0'*s1/(s1'*s1);
p0=p0-beta1*p1;
s0=s0-beta1*s1;
ifiter>1
beta2=s0'*s2/(s2'*s2);
p0=p0-beta2*p2;
s0=s0-beta2*s2;
end
end
end

References

[edit ]
  1. ^ a b Christopher C. Paige, Michael A. Saunders (1975). "Solution of sparse indefinite systems of linear equations" . SIAM Journal on Numerical Analysis. 12 (4): 617–629. doi:10.1137/0712047.
  2. ^ Nifa, M. Naoufal (24 November 2017). Efficient solvers for constrained optimization in parameter identification problems (PDF) (Doctoral Thesis). Université Paris Saclay (COmUE). pp. 51–52.
  3. ^ Sven Gross, Arnold Reusken (6 May 2011). Numerical Methods for Two-phase Incompressible Flows. section 5.2: Springer. ISBN 978-3-642-19685-0.{{cite book}}: CS1 maint: location (link)
[edit ]

AltStyle によって変換されたページ (->オリジナル) /