43.11.01 · numerical-analysis / 11-finite-difference-pdes

Finite differences for the elliptic BVP: the 5-point Laplacian and its convergence

shipped3 tiersLean: none

Anchor (Master): LeVeque 2007 *Finite Difference Methods for Ordinary and Partial Differential Equations* (SIAM) Ch. 3 (the elliptic discretisation, the M-matrix structure, the discrete Green's function, and the $O(h^2)$ convergence theorem); Hackbusch 1992 *Elliptic Differential Equations: Theory and Numerical Treatment* (Springer) §4.1-4.7 (the discrete maximum principle, M-matrices, the inverse-monotone stability bound, and the explicit eigensystem of the discrete Laplacian); Varga 2000 *Matrix Iterative Analysis* 2e (Springer) Ch. 1, 3 (M-matrices, monotonicity, and the diagonally dominant irreducible structure of $A_h$)

Intuition Beginner

Many physical balance laws say the same plain thing: at every interior point, a quantity sits at the average of its neighbours, nudged by whatever source is pushing on it. The steady temperature in a metal plate, the shape of a stretched drum at rest, the electric potential between charged plates — all obey a rule of this kind. The continuous form of that rule is the Poisson equation from 02.13.02, and on its own it lives at infinitely many points at once.

A computer cannot hold infinitely many points. So we lay a grid over the region, like graph paper, and keep only the values at the crossing points. The trick is to replace the smooth bending of the solution by a simple comparison among grid neighbours. In one direction, the bending at a point is measured by how much the point sits below the average of its left and right neighbours. In two directions, you compare a point against its four neighbours: left, right, up, and down. That four-neighbour comparison is the famous five-point stencil, and it turns the equation into a finite list of linear relations you can actually solve.

Once you write down one such relation at every interior grid point, you have a large system of linear equations. Solving it gives a number at each grid point that approximates the true solution there. The system is enormous but mostly empty: each equation touches only five values, so almost every entry is zero. That sparseness is what makes the method practical, and the solve itself uses the elimination machinery of 43.03.01.

Two questions then matter. Does the grid answer get closer to the true answer as the grid gets finer? And can the method ever produce a wild value that the true solution would never reach? The healthy answer to both is yes-it-converges and no-it-cannot, and the reason is a discrete echo of a fact about the continuous problem: a source-free solution attains its extremes only on the boundary.

Visual Beginner

The picture is a single interior grid point with its four neighbours, and the weights the method attaches to each. The centre point is compared against the average of the four points around it.

The stencil places a weight of four on the centre and a weight of minus one on each of the four neighbours, all divided by the square of the grid spacing. When the source is zero, this forces the centre value to be exactly the average of its neighbours.

            (i, j+1)
               |
              -1
               |
(i-1,j)--  -1  +4  -1  --(i+1,j)
               |
              -1
               |
            (i, j-1)
position weight in the stencil meaning
centre point the value being solved for
each of the four neighbours pulls the centre toward the neighbour average
anything else the stencil is local, so the system is sparse

The takeaway: the entire method is this one small picture, copied to every interior grid point. The boundary dots are not unknowns — their values are handed to you by the boundary data — so the unknowns are only the interior dots, and each one is tied to four neighbours.

Worked example Beginner

Let us solve the smallest interesting case by hand. Take the unit square and put down a grid with spacing , so the interior has just four unknown points arranged in a two-by-two block. We solve with the source set to zero, , and with boundary values all equal to except along the top edge, where the boundary value is .

Label the four interior unknowns (bottom row, left then right) and (top row, left then right). With , the five-point rule says each interior value equals the average of its four neighbours.

Step 1. Write the rule at (top-left interior point). Its neighbours are: left boundary , the point to its right, the top boundary above, and below. So .

Step 2. Write the rule at (top-right interior point): left neighbour , right boundary , top boundary , below . So .

Step 3. Write the rule at (bottom-left): left boundary , right , above , bottom boundary . So . Likewise .

Step 4. By the left-right symmetry of the data, and . Substitute. From step 3, , giving , so . From step 1, , giving , so . Put into this: , so and .

What this tells us: the four grid values are and . Every value sits between and , the smallest and largest boundary values — the grid solution never overshoots the data. The points nearer the hot top edge are warmer, exactly as physical intuition demands. This non-overshooting is the discrete maximum principle at work.

Check your understanding Beginner

Formal definition Intermediate+

Let be the open unit square with boundary , and consider the Dirichlet problem for the Poisson equation 02.13.02 $$ -\Delta u = f \ \text{ in } \Omega, \qquad u = g \ \text{ on } \partial\Omega, $$ with and , whose classical solvability and regularity are assumed as input from the continuous theory and are not reproved here. Fix an integer , set the mesh width , and place the uniform grid points for . The interior grid indices are , numbering unknowns ; the boundary grid values for or in are fixed at .

The 1-D second-difference operator. For a grid function in one variable, the second-difference operator is $$ (D^2 V)i = \frac{V{i-1} - 2V_i + V_{i+1}}{h^2}. $$ On the interior points it is represented by the symmetric tridiagonal matrix , so that has matrix .

The 5-point Laplacian. The discrete Laplacian acts on a grid function by $$ (\Delta_h U){ij} = \frac{U{i-1,j} + U_{i+1,j} + U_{i,j-1} + U_{i,j+1} - 4U_{ij}}{h^2}, $$ the sum of the second differences in and in . The discretised problem is at every interior point, with the boundary values substituted from . Collecting the interior unknowns into a vector under a fixed (e.g. lexicographic) ordering, this is the sparse linear system $$ A_h U = F, $$ where represents and collects together with the boundary contributions moved to the right-hand side. In Kronecker form , exhibiting as built from the 1-D operator in each coordinate. The matrix is symmetric positive definite, has on the diagonal and in the at-most-four off-diagonal positions of each row, and is sparse with at most five nonzeros per row; the system is solved by the LU/sparse-elimination machinery of 43.03.01. The symbols , , , , the Kronecker product , the discrete norms and , and the Landau symbol are recorded in _meta/NOTATION.md.

Local truncation error. The local truncation error of the scheme is the residual obtained by substituting the exact solution into the discrete operator, $$ \tau_{ij} = -\Delta_h u(x_i, y_j) - f(x_i, y_j) = -\Delta_h u(x_i, y_j) + \Delta u(x_i, y_j), $$ measuring the failure of the exact solution to satisfy the discrete equation. The scheme is consistent of order if .

M-matrix and monotonicity. A real square matrix is an M-matrix if it has nonpositive off-diagonal entries and a nonnegative inverse ( entrywise); equivalently here, is monotone implies entrywise. The sign pattern of (positive diagonal, nonpositive off-diagonals) together with weak diagonal dominance and irreducibility delivers this structure, which is the algebraic carrier of the discrete maximum principle [Varga, R. S. — Matrix Iterative Analysis (2nd ed.)].

Counterexamples to common slips

  • Consistency is not convergence. The truncation error measures how well the exact solution satisfies the discrete equation; it says nothing on its own about how far the computed lies from . Bridging the two requires the stability bound on . A scheme can be consistent and still diverge if its discrete operator is not stable.

  • The five-point Laplacian is , not . The Taylor expansion of carries a leading error term , which does not cancel between the two coordinate directions for a general . Believing the centred difference is fourth-order confuses the symmetry of the stencil (which kills the odd-order terms) with the vanishing of the leading even term (which it does not achieve).

  • Symmetric positive definiteness alone does not give the maximum principle. The discrete maximum principle rests on the sign pattern and monotonicity (), an order-theoretic property, not merely on positive definiteness. A symmetric positive definite matrix with a positive off-diagonal entry need not be monotone and need not obey a discrete maximum principle.

  • The boundary values are data, not unknowns. Only the interior values are solved for; the boundary grid values enter through the right-hand side . Treating boundary points as unknowns mis-sizes the system and breaks the M-matrix structure.

Key theorem with proof Intermediate+

The signature result is that the five-point scheme converges at second order in the maximum norm, and that this follows from two separately checkable facts: a consistency estimate (the truncation error is ) and a stability estimate (the discrete solution operator is bounded in the maximum norm uniformly in ). The stability estimate is itself a consequence of the discrete maximum principle.

Theorem (consistency + stability convergence). Let solve in with on , and let solve the five-point system . Then there is a constant , independent of , with $$ |U - u|{\infty} := \max{1\le i,j\le m} |U_{ij} - u(x_i, y_j)| \le C,h^2 \max_{\overline\Omega}\big(|u_{xxxx}| + |u_{yyyy}|\big). $$ [LeVeque, R. J. — Finite Difference Methods for Ordinary and Partial Differential Equations: Steady-State and Time-Dependent Problems; Hackbusch, W. — Elliptic Differential Equations: Theory and Numerical Treatment]

Proof. Let denote the global error grid function, vanishing on the boundary. Apply the discrete operator to . Since encodes , and the exact solution satisfies by the definition of the local truncation error, subtraction gives at every interior point, that is with the vector of truncation values and vanishing on the boundary.

Consistency. Expand in a Taylor series about . The centred second difference in gives $$ \frac{u(x_{i-1},y_j) - 2u(x_i,y_j) + u(x_{i+1},y_j)}{h^2} = u_{xx}(x_i,y_j) + \frac{h^2}{12}u_{xxxx}(\xi_{ij}, y_j), $$ for some between and , the odd-order terms cancelling by symmetry; the analogous expansion holds in . Adding the two and using , $$ \Delta_h u(x_i,y_j) = \Delta u(x_i,y_j) + \frac{h^2}{12}\big(u_{xxxx} + u_{yyyy}\big) + O(h^4), $$ so and hence .

Stability. The claim is the uniform bound . Introduce the comparison (barrier) grid function , the restriction of a quadratic with , hence exactly at every interior point (the second difference of a quadratic is its exact second derivative). On the square, . Given any interior grid function with and on the boundary, set . Then at every interior point, since each component of is at most , and on the boundary . The discrete maximum principle (Proposition 1 below) applied to — for which — gives throughout, that is . Hence , which is exactly .

Synthesis. Apply the stability bound to , which satisfies and vanishes on the boundary: $$ |E|\infty \le \tfrac18|A_h E|\infty = \tfrac18|\tau|\infty \le \frac{h^2}{96}\max{\overline\Omega}\big(|u_{xxxx}| + |u_{yyyy}|\big) + O(h^4). $$ Taking (absorbing the higher-order remainder into for below a fixed bound) gives the stated estimate.

Bridge. This proof is the foundational reason the five-point method is trusted: it factors the error into a consistency piece, controlled by Taylor expansion of the stencil, and a stability piece, controlled by the maximum-norm bound on , and their product is the convergence rate. This is exactly the consistency-plus-stability template that builds toward the Lax-Richtmyer equivalence theorem 43.11.05, where the bounded discrete operator is the time-evolution operator rather than the steady-state inverse ; it generalises the discrete-operator stability idea of 43.03.01, where the role here played by was played by the backward error of elimination. The stability half is dual to the consistency half — one bounds how the scheme amplifies residuals, the other bounds the residual the exact solution leaves behind — and putting these together is the central insight that a consistent, stable discretisation converges at the consistency rate. The same pattern appears again in the parabolic theory of 43.11.02, where the very same matrix reappears as the spatial operator of the method of lines and its eigenvalues set the time-step restriction.

Exercises Intermediate+

Advanced results Master

Theorem 1 ( is a symmetric positive definite M-matrix). The matrix , with , is symmetric, has positive diagonal entries and nonpositive off-diagonal entries , is irreducible (the grid graph is connected) and weakly diagonally dominant with strict dominance in the boundary-adjacent rows, and is therefore a nonsingular M-matrix: entrywise. It is moreover positive definite, since is positive definite and the Kronecker sum of positive-definite operators is positive definite, with eigenvalues the pairwise sums of the eigenvalues of . Monotonicity () is equivalent to and is the matrix form of the discrete maximum principle [Varga, R. S. — Matrix Iterative Analysis (2nd ed.)].

Theorem 2 (exact eigensystem of the discrete Laplacian). On the unit square with , the eigenvectors of are the tensor products of the 1-D sine modes: indexing , $$ v^{(p,q)}{ij} = \sin(p\pi x_i)\sin(q\pi y_j), \qquad A_h v^{(p,q)} = \lambda{p,q},v^{(p,q)}, \qquad \lambda_{p,q} = \frac{4}{h^2}\Big(\sin^2\tfrac{p\pi h}{2} + \sin^2\tfrac{q\pi h}{2}\Big). $$ These are the exact discrete analogues of the continuous Dirichlet eigenfunctions of on the square, whose eigenvalues are ; the discrete eigenvalues approximate these for low modes ( as with fixed) and saturate near for the highest modes. The smallest eigenvalue tends to and the largest to , so [Hackbusch, W. — Elliptic Differential Equations: Theory and Numerical Treatment].

Theorem 3 (the discrete Green's function and the sharp stability constant). The inverse has nonnegative entries , the discrete Green's function, satisfying for the barrier with ; consequently . The constant is the discrete reflection of the continuous bound on the unit square for the comparison quadratic; it is mesh-independent, which is precisely the stability of the scheme. The maximum-norm convergence rate is the product of this stability constant with the truncation error [LeVeque, R. J. — Finite Difference Methods for Ordinary and Partial Differential Equations: Steady-State and Time-Dependent Problems].

Theorem 4 (gain of accuracy by the nine-point stencil and Richardson extrapolation). Replacing the five-point stencil by the nine-point stencil -weighted combination, with the source corrected by , yields a scheme whose truncation error is , the Mehrstellen (compact fourth-order) discretisation; the same M-matrix and maximum-principle structure persists. Alternatively, because the five-point error admits an asymptotic expansion in even powers of , with -independent grid functions , Richardson extrapolation of and produces an approximation without changing the stencil. Both are routes past the second-order barrier of the plain five-point method [Hackbusch, W. — Elliptic Differential Equations: Theory and Numerical Treatment].

Synthesis. The five-point Laplacian is the model case in which consistency and stability are each visible as a separate, checkable structure, and convergence is their product: the foundational reason the method works is that is an M-matrix, and this single algebraic fact carries the discrete maximum principle, the inverse-monotonicity , the sharp mesh-independent stability constant , and the nonnegativity of the discrete Green's function. This is exactly the discrete shadow of the continuous Poisson theory of 02.13.02 and the continuous maximum principle of 02.13.01: the comparison/barrier function used in the stability proof is the discrete restriction of the continuous barrier, and the discrete eigenmodes are the exact sampled continuous Dirichlet eigenfunctions. The central insight is that the maximum norm, not the energy norm, is the natural setting for the finite-difference method — the M-matrix monotonicity is an phenomenon — which is the structural point of divergence from the finite-element method of 24.02.01, whose convergence is read in the energy norm through Céa's lemma and Galerkin orthogonality rather than through a maximum principle. Putting these together, the consistency-plus-stability proof here generalises into the Lax-Richtmyer equivalence theorem 43.11.05 for evolution problems, where is replaced by the power-bounded time-stepping operator; and the very matrix , with its explicit spectrum, is dual to the temporal stiffness it induces in 43.11.02, where its largest eigenvalue becomes the source of the parabolic time-step restriction.

Full proof set Master

Proposition 1 (discrete maximum principle). If a grid function on satisfies at every interior point, then . Symmetrically, implies .

Proof. The hypothesis is , so is bounded above by the mean of its four neighbours. Let and suppose is attained at an interior point . Each neighbour satisfies , while the sub-mean inequality forces , so equality holds and every neighbour also attains . The set is thus closed under the neighbour relation among interior points. Since the interior grid graph is connected and every interior point is connected to a boundary point through grid edges, propagating equality along a path from reaches an interior point adjacent to the boundary; at that point one of its neighbours is a boundary point, which must then also equal . Hence is attained on the boundary. The minimum statement follows by applying the result to .

Proposition 2 ( is monotone: ). The matrix representing on the interior with Dirichlet boundary is nonsingular, and entrywise; equivalently, implies .

Proof. First, nonsingularity. If with on the boundary, then satisfies both and at every interior point, so by Proposition 1 its maximum and minimum are both attained on the boundary where ; hence and is injective, thus invertible. For monotonicity, suppose , i.e. , with on the boundary. By the minimum form of Proposition 1, , so everywhere. Applying this to for each standard basis vector shows every column of is nonnegative, hence . The sign pattern (positive diagonal, nonpositive off-diagonals) together with this nonnegative inverse is the definition of an M-matrix.

Proposition 3 (uniform stability bound ). For every , the discrete solution operator satisfies , a bound independent of .

Proof. Let be the grid restriction of , for which and, since is quadratic and the centred second difference is exact on quadratics, at every interior point; equivalently where is the all-ones interior vector, and on the unit square . Fix a right-hand side and let , so on the boundary. Consider understood at interior points with the convention that ; more directly, set with the barrier satisfying , , on the boundary. Then at interior points and on the boundary (there and ). By Proposition 1, throughout, so for all . Hence , i.e. for every , which is .

Proposition 4 (exact eigenvalues and eigenvectors of ). The vectors , , are a complete orthogonal eigenbasis of with eigenvalues .

Proof. It suffices to treat the 1-D operator , since acts on the tensor mode with by where . Apply to at interior index : $$ (T s^{(p)})i = \frac{-\sin(p\pi x{i-1}) + 2\sin(p\pi x_i) - \sin(p\pi x_{i+1})}{h^2}. $$ Using and the identity with , $$ (T s^{(p)})_i = \frac{2\sin(p\pi x_i)\big(1 - \cos(p\pi h)\big)}{h^2} = \frac{2(1-\cos p\pi h)}{h^2},s^{(p)}i. $$ The boundary entries vanish because and , so satisfies the homogeneous Dirichlet condition and is a genuine interior eigenvector. Hence by the half-angle identity. The vectors are orthogonal (discrete sine transform) and complete in , so the tensor products form a complete orthogonal eigenbasis of with $\lambda{p,q} = \mu_p + \mu_q\square$

Connections Master

  • The continuous Poisson problem and its fundamental solution 02.13.02 is the object this unit discretises: the right-hand side , the Dirichlet data , and the classical solution whose fourth derivatives bound the truncation error all come from there, and the continuous solvability and / regularity it supplies (sharpened in 02.17.01) are exactly the hypotheses the convergence theorem assumes. This unit reproves nothing about the continuous equation; it builds the discrete operator that approximates it and proves the approximation converges.

  • The continuous maximum principle for harmonic and subharmonic functions 02.13.01 is the model for the discrete maximum principle proved here: the sub-mean-value inequality is the grid analogue of the sub-mean-value property of continuous subharmonic functions, and the comparison-function (barrier) technique used for the stability bound is the discrete restriction of the continuous comparison argument. The M-matrix structure of is the algebraic mechanism that makes the maximum principle survive discretisation.

  • The Gaussian-elimination and LU theory 43.03.01 is what actually solves the system this unit produces: is symmetric positive definite, so it admits a pivot-free Cholesky factorization, and its banded sparsity (bandwidth under lexicographic ordering) makes a direct solve cost rather than the dense . The conditioning established here feeds the forward-error analysis of that unit, explaining why very fine grids eventually motivate iterative and multigrid solvers over direct elimination.

  • The finite-element / Galerkin discretisation of the same Poisson problem 24.02.01 is the variational alternative to this pointwise-stencil method: where the finite-difference method enforces the equation at grid nodes and proves convergence through a discrete maximum principle in the maximum norm, the finite-element method projects the weak form onto a subspace and proves convergence through Céa's lemma and Galerkin orthogonality in the energy norm. On a uniform mesh the lowest-order finite-element stiffness matrix for coincides (up to scaling) with the five-point matrix , so the two discretisations meet at this model problem while resting on different stability theories — the energy estimate there, the M-matrix monotonicity here.

  • The eigenvalue and eigenvector theory 01.01.08 supplies the spectral machinery this unit applies to : the explicit diagonalisation by sine modes, the identification of for the symmetric positive definite operator, and the spectral-radius reasoning that the next unit 43.11.02 uses to convert the largest eigenvalue of into the explicit-scheme time-step restriction for the heat equation.

Historical & philosophical context Master

The systematic use of finite differences to approximate the Laplace and Poisson equations was placed on a rigorous footing by Richard Courant, Kurt Friedrichs, and Hans Lewy in their 1928 paper Über die partiellen Differenzengleichungen der mathematischen Physik (Mathematische Annalen 100, 32–74) [Courant, Friedrichs & Lewy 1928], which proved convergence of the five-point discrete solution to the solution of the continuous boundary-value problem and introduced the stability condition that bears their initials in the time-dependent case. Their elliptic argument already used the discrete maximum principle and the comparison-function idea that organise the modern proof.

The recasting of the convergence question into the algebraic language of monotone matrices and M-matrices — the property that carries the discrete maximum principle — is due to the work surrounding Richard Varga's Matrix Iterative Analysis (Prentice-Hall, 1962; 2nd ed. Springer, 2000) [Varga, R. S. — Matrix Iterative Analysis (2nd ed.)] and the matrix-theoretic tradition initiated by Ostrowski and Collatz, who connected diagonal dominance and irreducibility to inverse-positivity. The comprehensive numerical-analytic treatment, including the sharp bound, the discrete Green's function, and the exact eigensystem of the discrete Laplacian, was consolidated by Wolfgang Hackbusch in Elliptic Differential Equations (Springer, 1992) [Hackbusch, W. — Elliptic Differential Equations: Theory and Numerical Treatment], the same period in which Hackbusch's multigrid methods made the resulting sparse systems efficiently solvable.

Bibliography Master

@book{leveque2007fdm,
  author    = {LeVeque, Randall J.},
  title     = {Finite Difference Methods for Ordinary and Partial Differential Equations: Steady-State and Time-Dependent Problems},
  publisher = {Society for Industrial and Applied Mathematics (SIAM)},
  year      = {2007}
}

@book{hackbusch1992elliptic,
  author    = {Hackbusch, Wolfgang},
  title     = {Elliptic Differential Equations: Theory and Numerical Treatment},
  series    = {Springer Series in Computational Mathematics},
  volume    = {18},
  publisher = {Springer-Verlag},
  year      = {1992}
}

@book{varga2000matrix,
  author    = {Varga, Richard S.},
  title     = {Matrix Iterative Analysis},
  edition   = {2},
  publisher = {Springer-Verlag},
  year      = {2000}
}

@book{iserles2009first,
  author    = {Iserles, Arieh},
  title     = {A First Course in the Numerical Analysis of Differential Equations},
  edition   = {2},
  publisher = {Cambridge University Press},
  year      = {2009}
}

@article{courantfriedrichslewy1928,
  author  = {Courant, Richard and Friedrichs, Kurt and Lewy, Hans},
  title   = {{\"U}ber die partiellen Differenzengleichungen der mathematischen Physik},
  journal = {Mathematische Annalen},
  volume  = {100},
  number  = {1},
  year    = {1928},
  pages   = {32--74}
}

@book{strang2007cse,
  author    = {Strang, Gilbert},
  title     = {Computational Science and Engineering},
  publisher = {Wellesley-Cambridge Press},
  year      = {2007}
}