Chapter 2: Metric Spaces and Contraction Mappings#
Imagine you have an equation you want to solve, and you try a guess‑and‑improve method. You make a guess, see how far off you are, and then take a step that brings you closer to the real answer. To know if this process will actually work, we need a precise way to talk about “closeness” and “shrinking.” That is exactly what metric spaces and contraction mappings give us—a clear way to measure distance and guarantee that certain methods settle on a unique solution.
The Big Picture#
In numerical analysis we repeatedly build sequences of approximations that we hope will settle down to the correct solution. But what does “settle down” mean? And what conditions do we need to be sure a given problem has exactly one solution and that our method will find it? This chapter develops the essential mathematical tools: metric spaces extend the everyday idea of distance; completeness makes sure that sequences that “should” converge actually stay inside the space we are working in; contraction mappings are functions that always shrink distances; and the Banach fixed point theorem brings them together by proving that contractions on complete metric spaces have a unique fixed point and that simple iteration always finds it. These ideas support existence and uniqueness proofs for differential equations and are the theory behind many numerical solvers.
Distance and Metric Spaces#
We start with the intuitive idea of distance. On the number line, the distance between two numbers
- Distance is never negative, and the distance between two points is zero only when they are the same point.
- The distance from
to is the same as from to . - Going directly from
to is never longer than going from to and then from to (the triangle inequality).
A metric space takes these rules and uses them as a definition, without tying them to numbers. We can have any set of objects—functions, sequences, vectors, even colours—as long as we have a distance function that satisfies the three properties.
Metric space: A set
together with a function is called a metric space if for all :
, and if and only if . . (triangle inequality).
The functionis called the metric. We often write .
Example (The usual plane). Take
Example (Manhattan metric). On the same set
Example (Discrete metric). On any non‑empty set
These examples show that a metric space gives a clear way to talk about closeness without needing coordinates. An open ball (all points with distance less than
📝 Section Recap: A metric space is a set plus a way to measure distance that follows the four rules: distance is never negative, zero only for identical points, symmetric, and obeys the triangle inequality. This lets us talk about closeness in many different contexts.
Sequences, Cauchy Sequences, and Completeness#
Once we have a distance, we can say when a sequence of points settles down to a limit. Suppose
For every
there exists such that .
In plain words, after some index all terms of the sequence lie inside any tiny neighbourhood of
Convergence is a useful idea, but to prove it we usually need to guess the limit
Cauchy sequence: A sequence
in a metric space is called Cauchy if for every there exists such that for all , .
Every convergent sequence is automatically Cauchy (by the triangle inequality, bring both terms close to the limit). But the opposite is not always true! Think of the rational numbers
To avoid this problem, we introduce the idea of completeness:
Complete metric space: A metric space
is complete if every Cauchy sequence in converges to a point that belongs to .
The real numbers
Completeness is important for fixed‑point theorems: when we repeatedly apply a contraction, we get a Cauchy sequence, and we need to know its limit actually belongs to the space.
📝 Section Recap: A Cauchy sequence is one where the terms eventually cluster together. A space is complete if every Cauchy sequence converges to a point inside the space. Completeness ensures that a sequence that “should” converge really does have a limit in the space.
Lipschitz Functions and Contraction Mappings#
Now we look at functions that respect distance. In calculus, a function
Let
The smallest such
Contraction mapping: A function
from a metric space to itself is a contraction if there exists a constant with such that for all .
Think of a contraction as a function that shrinks all distances by at least a factor
A function need not be a contraction everywhere; often we restrict the domain to a closed bounded region where the Lipschitz constant drops below
📝 Section Recap: A Lipschitz function does not stretch distances more than a constant factor
. When and the function maps a space into itself, it is a contraction mapping — it pulls points closer together.
The Banach Fixed Point Theorem#
The main result of this chapter is the Banach fixed point theorem (also called the contraction mapping principle). It tells us when a function has exactly one fixed point, and how to find it by simply iterating from any starting point.
Banach fixed point theorem (contraction mapping principle): Let
be a non‑empty, complete metric space, and let be a contraction mapping. Then has a unique fixed point (i.e. ). Moreover, for any initial guess , the sequence defined by converges to , and the error after steps satisfies
The proof is constructive and shows exactly what to do.
Proof sketch.
- Pick any
and set . - Apply the contraction property repeatedly:
- For
, use the triangle inequality: Because , the right‑hand side goes to as , so is Cauchy. - Since
is complete, the sequence converges to some . - Contractions are continuous, so take the limit on both sides of
to get . - Uniqueness: if
and were both fixed, then . Because , this forces , so . - The error bound follows by letting
in the inequality from step 3. ∎
Example: Solving
This theorem is very handy: if we can rewrite a problem as finding a fixed point of a contraction on a complete space, we automatically get a unique solution and a simple method to find it.
📝 Section Recap: The Banach fixed point theorem says that a contraction mapping on a non‑empty complete metric space has a unique fixed point, and the simple iterative sequence
converges to it from any starting point. The proof gives an explicit error bound.
Why This Matters for Differential Equations#
The contraction mapping principle is more than just theory—it drives the proof that many ordinary differential equations (ODEs) have unique solutions. Consider an initial value problem
If
for all
Now define an operator
A solution of the ODE is exactly a fixed point of
This is a complete metric space. Because
📝 Section Recap: When an ODE satisfies a Lipschitz condition, we can turn it into a fixed‑point problem on a complete function space. The contraction mapping principle then guarantees a unique solution, and Picard iteration gives a way to find it. This is the basis for many numerical methods.
Summary#
You now understand the main ideas that answer “Does a solution exist, and is it unique?” for many problems. We started by extending the idea of distance so we can talk about convergence in all sorts of settings. Then we made sure sequences that “should” converge actually do, by requiring completeness. A contraction gave us a clear way to guarantee that repeating a function pulls points together. Finally, the Banach fixed point theorem brought everything together, giving us a proof that a unique solution exists and a method to find it, plus an error estimate. This theorem will show up again and again as the foundation for solving differential equations numerically.
| Key idea | What it means (plain English) | Why it matters |
|---|---|---|
| Metric space | A set with a distance function that obeys non‑negativity, symmetry, and the triangle inequality. | It gives us a clear way to talk about closeness that works for numbers, vectors, functions, and more. |
| Cauchy sequence | A sequence whose terms eventually squeeze arbitrarily close to each other. | It captures the idea of convergence without needing to know the limit in advance. |
| Complete metric space | A metric space where every Cauchy sequence has a limit that stays inside the space. | It guarantees that iterative methods that produce Cauchy sequences will actually arrive at a solution. |
| Lipschitz continuous function | A function with a bounded stretch factor: distances between outputs are at most |
It gives precise control over how much a function can amplify errors, essential for proving convergence. |
| Contraction mapping | A Lipschitz function with |
It is the core hypothesis of the Banach fixed point theorem; repeated application pulls all points toward a unique fixed point. |
| Banach fixed point theorem | On a complete metric space, every contraction has exactly one fixed point, and iteration from any start converges to it. | It gives a general method for proving existence and uniqueness, along with a constructive algorithm and an error bound. |
| Picard iteration | Using the contraction principle to solve differential equations by iterating the integral operator. | It shows that many ODEs have unique solutions and that simple successive approximation works—the basis for many numerical solvers. |