liveBook · Manning

Spline

As explained in Geometry for Programmers

A polynomial spline is a piecewise polynomial curve joined with prescribed smoothness conditions.

A spline is a compound curve made from simpler functions, usually piecewise polynomials joined with prescribed continuity and smoothness. Instead of forcing one large polynomial to describe an entire shape, a spline combines manageable pieces that meet as a single-looking curve. section 7.0 section 7.1.1

Figure 7.1 For x < 0, y = - 0.2x2 + 2; for x ≥ 0, y = 0.3x2 + 2. This is already a spline function.
07-01

Even two different quadratic formulas can form a spline: use one parabola for x < 0 and another for x ≥ 0, joining them at a shared point. section 7.0

The practical goal is control. Polynomial splines let you prescribe points and tangents explicitly, so curve pieces can be positioned and joined deliberately. Derivative constraints consume polynomial coefficients, but they make adjacent pieces appear continuous rather than merely touching. section 7.1.1 section 7.2.4

Common spline representations provide different kinds of control:

  • Polynomial splines join polynomial pieces and specify tangents directly. section 7.2.4
  • Bézier curves model splines through control points, which determine tangent behavior indirectly. section 7.0 section 7.2.4
  • NURBS extend Bézier curves with nonuniform knots, rational weights, and basis functions, supporting more control over engineered curves and surfaces. section 7.3.5 section 11.1

Degree trades segments for smoothness

For both explicit polynomial splines and NURBS, N control points can produce N − M curve segments of degree M, with continuity C^(M−1). Increasing degree therefore improves continuity but reduces the number of available segments: first degree is a continuous polyline, second degree is C1, and third degree is C2. section 7.3.1

Splines are useful wherever smooth, controllable geometry matters: graphic design, virtual reality, games, geoinformation systems, CAD, and physical manufacturing. They replace many specialized curve types with flexible general-purpose representations. section 7.0 section 11.1

How Geometry for Programmers covers it

How deep it goes
Explains piecewise construction, derivative constraints, Bézier and NURBS representations, and degree-continuity trade-offs.
Examples
Uses joined parabolas, tangent-constrained cubic polynomials, Bézier control points, and degree-one through degree-four NURBS.
What it assumes
Assumes basic analytic geometry, calculus derivatives, polynomials, and linear algebra as supporting tools for curve construction.
What you can do after
Build smooth curves by choosing polynomial pieces, tangent constraints, Bézier control points, or NURBS degree and weights.
How it connects
Connects splines with polynomials, Bézier curves, NURBS, control points, tangents, knot vectors, continuity, and CAD.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Geometry for Programmers. The section links point to the parts of the book it draws on.