A moving profile on a periodic grid
Diffusion smooths a profile, whereas constant-speed advection transports it. A difference scheme should respect the direction in which information moves. We study the periodic problem
on a circle of length . Its exact solution is : the initial profile moves to the right at speed without changing shape.
Definition 6.1.1
(Periodic grid, Courant number and upwind update)
Let be an integer, , , and let be the time step. Indices are taken modulo , so . The Courant number is , and the upwind update is
For positive speed the left neighbor is upstream. No inflow boundary is needed on this periodic grid; a nonperiodic problem requires a separate boundary treatment.
Stability from a convex combination
Theorem 6.1.2
(Maximum-norm stability)
If , then for any two grid vectors their updated vectors obey
The update also preserves the discrete sum and preserves nonnegativity.
Proof
(Nonnegative weights summing to one)
Put . The update is linear, so . Both weights are nonnegative when , and they sum to one, so the triangle inequality gives
for every . Summing the update over and shifting the periodic index, , so the new sum is . Nonnegative data remain nonnegative because both weights are nonnegative. These are exact-arithmetic statements.
Worked example 6.1.3
(One step on four nodes)
With , and , the update reads . Only and see the unit entry, so . The sum remains one and the maximum drops from to : at intermediate the scheme spreads the pulse.
Worked example 6.1.4
(The edge case : an exact shift)
At the update is , so becomes . Moreover , so the exact solution satisfies . The grid values of the exact solution obey the same rule, and with exact initial values the numerical solution is exact at every node and every step. The bound of the next theorem does not vanish at ; it is an upper bound, not a sharp error formula.
A finite-time error estimate
Assume the periodic exact solution has continuous and on , and set and over that domain. Initialize and suppose .
Theorem 6.1.5
(Consistency plus stability)
For ,
Proof
(Local defect accumulated by a stable update)
Write and define the defect . Taylor's theorem in time and in space gives, with intermediate points,
where are evaluated at . Hence , and removes the first term. Therefore
The error satisfies : it is the upwind update of the previous error minus the defect. Maximum-norm stability, applied to the update of against the zero vector, gives . Since , iteration gives , which is the bound. Thus along grids with and , the error vanishes on this fixed time interval.
Proof X-ray
Where the CFL condition enters the error proof
The argument has two independent ingredients. Consistency is the Taylor estimate of the defect; it holds for every , and it uses the equation only to cancel . Stability is the single place where is used: it lets the defects of different steps add up instead of being multiplied. For the same triangle inequality gives only , and grows without bound as with . The proof closes because converts the per-step defect, of size , into a global error of size : one power of is lost to accumulation, so the same argument proves convergence for any stable scheme whose per-step defect is .
Worked example 6.1.6
(Evaluating the bound for a moving sine wave)
Take , , and , which is periodic and solves the equation. Then , so . With and we have , and the bound is
Halving both and keeps and halves the bound: the estimate is first order. Since , the guaranteed accuracy at this resolution is modest, which reflects how much the upwind scheme smears a profile over one period.
The CFL condition also has a geometric reading. After steps, depends only on the initial values at , an interval of length ending at . The exact value equals the initial value at the foot of the characteristic, . The numerical domain of dependence contains that foot exactly when , that is, when . If the foot lies outside, and changing the initial data near it changes the exact value while leaving unaffected, so no refinement with fixed can converge for all smooth data. The algebraic condition on the weights and the geometric condition on characteristics give the same range.
What happens outside the condition?
Both proofs used the CFL condition only through the nonnegativity of the two weights. When the weight is negative, and a single step already shows the consequence.
Counterexample mode
A step beyond the CFL range
For the four-node initial vector above, gives , hence . The initial maximum absolute value was one and the new one is ; a negative value also appears. The convex-combination argument no longer applies. This example shows failure of that one-step maximum principle, not every possible behavior of every initial vector.
The explorer below steps the periodic upwind and centered forward-Euler updates in exact arithmetic, so you can push the Courant number past and watch the sum, the maximum, the sign of the entries and the Fourier amplification factors change.
A centered spatial difference with forward Euler has a different failure. For a periodic Fourier mode , its one-step factor is , so . On a four-node grid is allowed; for any nonzero this mode grows under repeated steps. A more symmetric spatial stencil is not automatically a stable time-stepping method.
Common mistake
(Taking the downwind neighbor)
For the formula looks equally consistent, but its weight is negative for every . Its amplification factor satisfies for , so it is unstable at every time step. The upwind neighbor is the one on the side the flow comes from: when , when .
Common mistake
(Refining space while keeping the time step)
The CFL condition constrains the ratio , not alone. A run that is stable with () becomes unstable if is reduced to with the same , because then . Spatial refinement must be accompanied by .
Exercises
Quick check
(Compute one upwind step for with and with .)
Only the entries at and involve the nonzero value.
Solution · Answer
The update gives for and for .
Quick check
(Why is the periodic sum unchanged by the upwind update?)
Solution · Answer
Periodic index shifting gives , and the two weights sum to one, so .
Quick check
(For a fixed smooth exact solution and fixed , what happens to the error bound as within the CFL range?)
Solution · Answer
The bound tends to zero, provided the stated derivatives are bounded on the fixed time interval; it decreases linearly in and .
Quick check
(For the four-node centered scheme with , find the modulus of the amplification factor.)
Solution · Answer
, so this mode grows by the factor per step.
Further reading
MIT OpenCourseWare, accuracy and stability of finite-difference transport schemes discusses upwind schemes, stability and convergence.