Implicit solvers and Newton tolerances
Control algebraic error inside an implicit time step using Jacobian conditioning, scaled corrections, and a discretization error budget.
On this page
The question for today
What you’ll understand
- Form the residual and Newton matrix for an implicit step.
- Relate residual size to state error through an inverse Jacobian.
- Choose algebraic accuracy that does not overwhelm temporal discretization.
An implicit formula defines the next value through an equation, and software only solves that equation approximately. Its output therefore contains algebraic error in addition to the time-discretization error of the ideal formula. Solving far beyond the needed accuracy wastes work, while stopping too early can erase the integrator's nominal order. A reliable implementation connects the nonlinear stopping criterion to a scaled state-error budget and checks the linear systems used to produce each Newton correction.
The time step becomes a residual equation
Backward Euler seeks a value Z satisfying . Newton's method linearizes G at a current guess, solves for a correction, and updates that guess. The exact Newton matrix is identity minus h times the state Jacobian of f. A small h often makes this matrix close to identity, but stiff rates, couplings, and scaling can change its conditioning. The mathematical implicit formula does not specify how many iterations are sufficient.
A predictor from previous accepted values can provide a good initial guess, but Newton convergence remains local without additional safeguards. A line search or damping can prevent a bad full correction from leaving the useful region. Reusing a factorization gives a modified Newton method, which can save work when the Jacobian changes slowly but can converge more slowly. Failure to reduce corrections or residuals may require refreshing the Jacobian, improving the linear solve, rejecting the step, or reducing h.
A small residual needs a conditioning interpretation
Near a regular root, first-order perturbation analysis relates the state error to the inverse residual Jacobian applied to the residual. A small raw residual can correspond to a large state error if that inverse is large. Multiplying the entire equation by a small constant also makes its residual small without changing the root. Residual tolerances must therefore use a meaningful scaling and an estimate of how residual error affects the state, rather than an arbitrary numerical threshold.
Correction-based stopping can estimate the remaining error when the iterations have entered a predictable contraction regime. But a small step in an iteration is not always proof of a small error: damping, stagnation, or a poor approximate Jacobian can make corrections tiny. Use both progress and a residual or correction criterion tied to the integration scales. In a scalar problem a derivative bounded away from zero can give a rigorous local error bound by the mean-value theorem; in a system one needs an appropriate inverse or nonlinear regularity bound.
Nest the error budgets rather than solving blindly
An order-p one-step formula has an ideal local defect of order h to the p plus one. A sufficient fixed-interval strategy is to keep each algebraic state error at that scale or below, so its propagated contribution does not spoil the intended global order under the same stability assumptions. A fixed absolute nonlinear tolerance may dominate as h shrinks, causing a refinement plateau. Adaptive codes usually tie nonlinear error to the current componentwise integration weights and reserve a fraction of the allowed local estimate.
There is another nested solve inside Newton when a Krylov method approximates the correction. Its linear residual should be small enough that the resulting correction error does not obstruct nonlinear convergence, but high accuracy in early nonlinear iterations may be unnecessary. Preconditioners affect that trade and must account for the step-dependent matrix. Track nonlinear iterations, linear iterations, rejected trials, and Jacobian updates together; a solver that takes few accepted steps can still be expensive if each step hides a difficult algebraic problem.
Work it through
Solving a nonlinear backward-Euler step
For y′=−y², Yₙ=1, and h=0.2, solve G(Z)=Z+0.2Z²−1=0 on the nonnegative branch using Newton from Z⁽⁰⁾=1.
The derivative is 1+0.4Z. The first correction is −0.2/1.4=−1/7, giving Z⁽¹⁾=6/7≈0.8571428571.
At this value G=1/245 and G′=47/35. The next correction is −1/329, giving Z⁽²⁾=281/329≈0.8541033435.
The exact nonnegative algebraic root is (√1.8−1)/0.4≈0.8541019662. The remaining error is about 1.3772×10⁻⁶. Because G′≥1 on the nonnegative interval, the residual also bounds the state error there.
Two Newton updates solve the implicit equation closely. This algebraic root is still distinct from the exact differential-equation value 1/1.2≈0.8333333333.
The living notebook
Explore the model
Interactive lab · root-finding
A rigorous algebraic bracket
Pause and Reset, then set target c=2 and upper bound U=2. Predict the bracket after three bisections and Step three times. Compare the midpoint and reported bracket error bound with √2. Use this as a concrete example of an algebraic stopping certificate.
- Midpoint after 0 refinements
- 1.5
- Bracket error bound
- 1.5
- Computed residual · x² − c
- 0.25
Bisection of x² − c on [0,U], capped at 50 iterations for floating-point resolution. The error bound is the maximum distance from the displayed midpoint to either bracket endpoint (half the width in exact arithmetic). Compensated square evaluation preserves the bracket when ordinary multiplication rounds a residual to zero. A truly exact endpoint or midpoint collapses the bracket. This is one monotone quadratic, not a general root solver. Parameter changes pause playback and recompute the model at the current elapsed time. Reset restores both parameters and returns time to zero. Playback starts paused. Adjust either parameter, then choose Play or Step.
Look forThe bracket is [1.25,1.5], midpoint 1.375, with bound 0.125. This instrument bisects x²−2; it does not run Newton or solve an implicit ODE. Its guaranteed scalar bound illustrates what a solver tolerance must mean.
Pause & reason
Check your understanding
Your turn
Try it yourself
Backward Euler for y′=−3y from Yₙ=2 with h=0.25 gives G(Z)=1.75Z−2. For a candidate Z=1.143, find the residual, exact algebraic error, and exact algebraic root.
Take a moment to make a prediction or work it out on paper. Open a hint when you need one.
Give me a hint
This residual is linear, so dividing it by 1.75 gives the state error exactly.
Compare with the solution
The algebraic root is 2/1.75=8/7≈1.1428571429. The candidate residual is 1.75·1.143−2=0.00025. Dividing by 1.75 gives the signed state error 1/7000≈0.0001428571. This identity is exact for the linear residual. The ODE's exact next value is 2exp(−0.75), which is a different target from the implicit algebraic root.
Keep the idea
Take it with you
- Implicit discretization error remains even after the algebraic equation is solved exactly.
- Residuals need conditioning and scale information before they certify state accuracy.
- Linear and nonlinear solve budgets should remain below the temporal error budget.
Read further
Original sources and deeper explanations to follow at your own pace.
Optional progress, saved in this browser when available. Revisit any lesson at any time.
Lesson not marked complete.