A piecewise linear function is a function composed of some number of linear segments defined over an equal number of intervals, usually of equal size.
For example, consider the function over the interval . If is approximated by a piecewise linear function over an increasing number of segments, e.g., 1, 2, 4, and 8, the accuracy of the approximation is seen to improve as the number of segments increases.
In the first case, with a single segment, if we compute the Lagrange interpolating polynomial, the equation of the linear function results.
The trapezoidal rule for numeric integration is described in a similar manner.
Piecewise linear functions are also key to some constructive derivations. The length of a "piece" is given by the
(1)
|
summing the length of a number of pieces gives
(2)
|
and taking the limit as , the sum becomes
(3)
|
which is simplify the usual arc length.