A difference scheme of order has an error : on a log-log plot, a straight line of slope . Raising tilts the line. The question of this chapter is what happens if is not fixed at all, but grows with the mesh.
Collocation with a global polynomial#
Let be the polynomial of degree that takes the unknown values at the Chebyshev points
and require at the interior points, with matching the boundary data at the two ends. Differentiation is linear and the nodes are fixed, so at the nodes is a matrix times the vector of nodal values. That matrix is the Chebyshev differentiation matrix, lp_cheb in the shared library; the discrete operator is , dense and of size .
Two things are being given up. The matrix is dense, so a solve costs rather than . And the accuracy at a point now depends on the data everywhere, so there is no notion of a local truncation error, and the classical Taylor-series analysis does not apply.
What is bought is the approximation power of polynomials of high degree. For analytic in a neighbourhood of , the best degree- polynomial approximation converges geometrically, like for some set by the size of that neighbourhood, and the collocation solution inherits that rate. The error is not for any ; on a log-log plot it is not a straight line at all, but a curve that falls away ever more steeply.
The clustering of the nodes near the endpoints is essential rather than cosmetic. Equally spaced points of the same degree produce the Runge phenomenon, and a collocation method built on them is unusable for beyond about 20.
Where the curve stops#
On the smooth solution the Chebyshev error falls to at , in a fraction of a millisecond. The three-point scheme, given a hundred times as long and intervals, manages . This is the pattern that makes spectral methods worth their inconvenience: when the solution is analytic and the geometry is simple, they are not a little better, they are several orders of magnitude better at the same cost.
The flat tail past is the roundoff floor again, and it arrives for the same reason as before. The two-derivative operator has a condition number growing like , worse than the of the difference matrices, so a spectral method reaches its floor at a rather small . It reaches it at about , which is close to what double precision permits, and there is nothing to be gained by going further.
Now change the manufactured solution.
layerputs a boundary layer of width at , which is exactly where the Chebyshev points cluster, and the method converges even faster than it does on the smooth case. Grid clustering that happens to match the solution's structure is worth a great deal.peakputs the structure in the middle, where the nodes are sparsest. The method still converges geometrically, but only once is large enough to resolve the peak, and the curve stays flat until then.lowregis the interesting failure. The solution is but not , and all three methods collapse onto very nearly the same algebraic rate, close to . Chebyshev collocation is no better than the three-point scheme here, and at moderate it is somewhat worse. Geometric convergence is a statement about analyticity, and when analyticity fails there is nothing left of the advantage.
The general rule is worth stating plainly, because it survives into two dimensions and into the harder geometries of Part III: the achievable convergence rate is a property of the solution, and a method can only fail to attain it. High-order methods are how one attains it when the solution is smooth. Chapter 9, where the geometry itself forces a singularity into the solution, is about what to do when it is not.