Clamped cubic spline 2026-10-31
A clamped cubic spline is a cubic spline whose endpoint first derivatives are prescribed. A clamped cubic spline interpolant additionally matches prescribed values at its spline knots. Distinct spline knots, arbitrary nodal values and arbitrary endpoint slopes determine one such interpolant. The minimum roughness property of a clamped cubic spline proves uniqueness. Unlike the natural cubic spline, this construction prescribes endpoint slopes rather than zero endpoint second derivatives.
Fourth derivative 2026-10-31
The fourth derivative is the derivative of the third derivative. It vanishes for a polynomial of polynomial degree at most three. For a cubic spline, this statement applies inside each knot interval; a jump of the third derivative can prevent a classical fourth derivative from existing at a spline knot.
Use the standard meaning of a cubic spline: a function that is cubic on each unit interval. If it vanishes on both exterior intervals, continuity of the function and its first two derivatives gives zero endpoint jets at zero and at .
Such a spline can be represented through its third-derivative jumps asFor , this must be the zero polynomial. Expanding in powers of yields the four moment conditionsIf , the columns of this Vandermonde system are linearly independent, so every . No nonzero spline has such short support.
For , a nonzero null vector is , since the fourth finite difference annihilates every cubic. Thus the Cardinal cubic B-spline isIts knot values at are , whose sum is one. It is nonzero and supported on , proving the minimal value . Equivalently, on it is , on it is , and the other half follows by symmetry .
Past exam of the mathematics course of the University of Cambridge 2001 iii Paper 58 1 Solution Created 2026-10-03 Updated 2026-10-14
The cubic spline is even, so the symmetry of the normalized B-splines gives . It therefore suffices to extract three coefficients. The two polynomial pieces join with matching values and first two derivatives at zero, so the function belongs to the stated cubic spline space. At zero its right-hand derivatives areUse the supplied De Boor–Fix spline coefficient functional with the unnormalized knot polynomial . In this sign convention the coefficient isFor , . Taking the right-hand limit at kills the first three terms and gives . For the next two coefficients take the right-hand limit at zero. Their knot polynomials and derivatives there areConsequently and . Although the third derivative jumps at zero, its multiplier vanishes for these two functionals; taking either one-sided limit gives the same coefficients. Symmetry gives and . ThusFor a normalized B-spline basis, define the synthesis linear map from the maximum coefficient norm into the spline space with its supremum norm. Nonnegativity and partition of unity give , including equality on the all-ones vector. The coefficient condition number of a normalized B-spline basis isOn , . The only interior extremum is at , where ; at zero and one, . Reflection therefore gives . Its largest absolute coefficient is , proving
Past exam of the mathematics course of the University of Cambridge 2007 iii Paper 49 1 Solution Created 2026-10-03 Updated 2026-10-14
A cubic spline belongs to and is a polynomial of degree at most three on each interval separated by the spline knots. A natural cubic spline is additionally an affine function on the exterior intervals and . On this is equivalent to the endpoint conditions ; these conditions remain part of the definition when an outer knot coincides with or .
Let be the natural cubic spline interpolant of the prescribed values, and let be any other interpolating function. Set , so . On the interval , integration by parts twice givesbecause the fourth derivative of each cubic piece is zero. The second boundary term is zero because vanishes at the spline knots. After summing the first terms, the interior contributions cancel by continuity of and , and the two remaining terms vanish by the natural endpoint conditions. On the exterior intervals . Thus , and the second derivative roughness penalty satisfiesIf equality holds, the continuous nonnegative function has zero integral, so everywhere. Hence is an affine function, and its zeros at two distinct spline knots force . This proves the minimum roughness property of the natural cubic spline interpolant and its equality case: the unique minimum-roughness interpolant is .
For the fixed-design nonparametric regression fit, use the penalized least squares criterionLet be the natural cubic spline interpolant with value vector . Replacing by for leaves the residual sum unchanged and reduces the second derivative roughness penalty, strictly unless . It therefore remains to minimize the finite-dimensional quadratic formThe supplied spline roughness penalty matrix is positive semidefinite. For every nonzero vector ,Consequently is a positive-definite matrix, and is strictly convex. Its normal equations for linear least squares have the unique solutionThe preceding strict reduction also proves uniqueness over the whole class , not just over the natural cubic splines. This is the cubic smoothing spline. If the residual criterion is divided by instead, the corresponding formula is , reflecting a change in the numerical convention for the smoothing parameter.
The independence and specified error mean and variance are not needed for existence or uniqueness of this minimizer. They do imply, with smoothing matrix and , that and . The null space of consists of sampled affine functions: these have zero roughness, and conversely zero roughness forces their natural cubic spline interpolant to be an affine function. Thus these functions are reproduced without bias of an estimator, while other components are smoothed.
Past exam of the mathematics course of the University of Cambridge 2017 iii Paper 210 4 Solution Created 2026-10-03 Updated 2026-10-05
Use the natural cubic spline convention appropriate to the interior design knots: the spline is linear on and . We also need . These points will be important for uniqueness.
A cubic spline is a function in whose restriction to each of , , through is a polynomial of degree at most three. A spline knot is a junction between consecutive pieces. For a natural cubic spline, the two exterior pieces are affine functions; equivalently, one uses the natural endpoint conditions on the spline over and then extends linearly with matching derivatives. Merely prescribing on otherwise arbitrary exterior cubic pieces is a different condition and does not provide the unique interpolant invoked in this question.
The natural cubic spline interpolant to values is the natural cubic spline satisfying . Its existence and uniqueness for are the interpolant fact allowed in the PDF. The interpolation map is a linear map: a linear combination of interpolants satisfies the same spline, boundary and value conditions, so uniqueness identifies it with the interpolant to the corresponding linear combination of value vectors.
Let , let have the same values, and put . Then . We prove the orthogonalityApply integration by parts twice on each polynomial interval. On an interior interval, , andThe terms vanish because vanishes at the knots. The terms cancel at internal knots because and are continuous, and vanish at because is zero there. On the exterior intervals, identically. Summing therefore gives the claimed orthogonality without assuming that is continuous across knots.
Expanding the square now gives the minimum roughness property of the natural cubic spline interpolantEquality forces everywhere, since is continuous. Thus is an affine function. It vanishes at two distinct design points, so , proving equality if and only if .
For the penalized fit, take the allowed spline roughness penalty matrix to be a symmetric matrix with ; thus it is a positive semidefinite matrix. If its supplied representative were not symmetric, its symmetric part defines the same quadratic form and is all that is needed. For any , let . Replacing it by preserves every fitted value and can only decrease the second derivative roughness penalty. Therefore it is enough to minimizeover . The matrix is a positive-definite matrix, sinceCompleting the quadratic or differentiating gives the unique solutionThis is the cubic smoothing spline. More explicitly, the normal equations are , andFor an arbitrary function with fitted vector , the earlier orthogonality also givesBoth terms are nonnegative. Equality forces and, by the proved interpolation equality case, . This proves both existence in and uniqueness over the entire stated function class, not just over splines.
The argument is deterministic for each observed . The fixed-design nonparametric regression and homoscedasticity assumptions motivate the squared-error loss, but Gaussian errors are not required.
At least two distinct design points are required for uniqueness. Question 4 does not explicitly restate , and this hypothesis is necessary. With one design point, every function has zero residual and zero second derivative roughness penalty, for any real . Thus the printed unrestricted uniqueness conclusion would be false for . The corrected theorem assumes at least two distinct knots and the stated linear-tail convention. At , uniqueness over all of also fails; the stipulated eliminates that degeneracy.
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 207 5 b vi Solution Created 2026-10-03 Updated 2026-10-05
Fit the Cox proportional-hazards model with the other explanatory variables, initially omitting the variable whose form is being assessed, and plot the resulting martingale residuals against . Add a smooth trend, for example using a cubic spline or a local smoother. A systematic pattern indicates that affects the hazard function; the shape helps suggest a linear term, a transformation, or a nonlinear spline term in the log hazard.
Refit with the proposed form and inspect martingale residuals against again. Under an adequate functional form, their conditional mean should have no systematic trend, allowing for model fitting and the other covariates. Compare plausible alternative forms using the partial likelihood and suitable model checks.
Use the smoothed pattern to assess the covariate's functional form, rather than treating these residuals as normal regression errors. Martingale residuals are asymmetric, bounded above by 1, and can be arbitrarily negative; the raw residual plot can therefore be misleading without smoothing. This diagnostic concerns the covariate form, and does not by itself test the proportional hazards assumption.
Past exam of the mathematics course of the University of Cambridge 2024 iii Paper 210 3 Solution Created 2026-09-24 Updated 2026-10-03
A cubic spline with knots is twice continuously differentiable and restricts to a polynomial of degree at most three between consecutive knots. It is a natural cubic spline when it is linear outside , equivalently when its second derivative vanishes at the two outer knots and on the exterior intervals.
Let be the natural cubic spline interpolating prescribed values and let be any other interpolant in . Then . Piecewise integration by parts, using that between knots, is continuous, on the exterior intervals, and every jump of is multiplied by , givesConsequentlyEquality forces almost everywhere. Then is affine and its zeros at at least two distinct knots force , proving uniqueness.
For the penalized problem, fix a vector of fitted values. The preceding variational result says that its natural spline interpolant has the least roughness among all functions taking those values, and by assumption that roughness is . The infinite-dimensional problem therefore reduces toBecause is positive semidefinite, is positive definite. The unique fitted-value vector isand is its unique natural cubic spline interpolant.
For Leave-one-out cross-validation, let minimizeand defineIf , its normal equations sayThus , whereTaking the th coordinate and writing givesTherefore one spline fit and the diagonal of its smoothing matrix give
A linear spline is a continuous function whose restriction to every interval is a polynomial of polynomial degree at most one. With and , linear interpolation givesIntegrating the two linear polynomials and adding the contributions givesThis is the composite trapezoidal rule applied to the nodal values, and it is exact for the linear spline itself, including nonuniform spline knots.
A cubic spline on this partition of an interval is a function that restricts to a polynomial of polynomial degree at most three on every interval . Thus its second derivative is continuous and piecewise of polynomial degree at most one: is a linear spline on the same spline knots. Its third derivative is constant on each open interval and can jump across the spline knots; its fourth derivative vanishes inside each open interval.
Past exam of the numerical analysis course of the University of Oxford 2017 3 b ii Solution 2026-10-31
Let be a second cubic spline matching the same values and endpoint derivatives. The minimum roughness property of a clamped cubic spline applied with as the minimizing cubic spline gives , where . Applying the same argument with their roles exchanged gives . Hence equality holds, and the exact identity from part (i) yieldsThe integrand is continuous and nonnegative. If it were positive somewhere, it would have a positive integral over a small interval. It follows that everywhere. Consequently is an affine function. Its value and derivative vanish at , so it is identically zero. Thus , proving uniqueness of the clamped cubic spline with the prescribed data. Existence was assumed in the question; this argument establishes the remaining uniqueness claim.
A cubic spline is a twice continuously differentiable function whose restriction to each knot interval is a polynomial of degree at most three. Its second derivative is continuous and piecewise linear. Natural endpoint conditions are .
Linearity of both the piecewise-polynomial and smoothness conditions, and of the endpoint equations, makes the natural splines a vector space . A continuous piecewise linear second derivative with zero endpoint values is determined freely by its interior nodal values. Integrating twice adds two arbitrary affine constants. HenceThis count includes the case of one interval.
An interpolating spline has at every node. Set , so vanishes at all nodes. On each open knot interval is constant. Two integrations by parts giveThe terms containing vanish at nodes. When summed, the interior terms cancel because and are continuous. The two outer terms vanish by the natural endpoint conditions. ThusIntegrating the given square identity now yields the sharper energy decompositionIn particular the natural interpolating spline minimizes the squared-curvature integral.
If is another natural interpolant, the same minimizing argument in both directions makes the two energies equal. The final nonnegative integral then vanishes, so everywhere by continuity. Their difference is affine and zero at all knots, including the two distinct endpoints, so . This proves uniqueness.
It also supplies existence if needed: nodal evaluation is a linear map from the -dimensional space to . Its kernel is zero by the same argument with zero data and the zero competitor. It is therefore surjective, so every data vector has a natural spline interpolant.
A natural cubic spline with the given knots is a function that is polynomial of degree at most three on each interval between consecutive knots and has . With the usual whole-line convention, it extends affinely outside the extreme knots. The word natural refers to these endpoint second-derivative conditions; the interpolation values must be specified separately.
For , direct differentiation on either side of the knot givesBoth one-sided limits of the function and its first two derivatives at are zero, so these formulas are continuous there andIts third derivative jumps from zero to six, which is permitted for a cubic spline.
Spline approximation Created 2026-09-24 Updated 2026-11-05
Spline approximation represents a function by low-degree polynomial pieces joined at specified knots. Smoothness conditions control the agreement of neighboring pieces. This permits local changes without fitting one high-degree polynomial across the entire domain.
The simplest example is piecewise-linear interpolation on a uniform grid. If on each cell of width , the interpolation remainder gives . More regular cubic splines impose derivative continuity as well. Spline quasi-interpolation uses local functionals instead of solving for a global interpolating fit, making locality useful in both analysis and computation.
Spline knot 2026-10-05
A junction between adjacent polynomial pieces of a cubic spline or other spline. Continuity conditions at these junctions determine which piecewise polynomial functions are splines.
Third derivative 2026-10-31
The third derivative is the derivative of the second derivative. On the interior of a cubic polynomial piece it is constant. A cubic spline can have different constants on adjacent pieces, so its third derivative need not be continuous across a spline knot.
