### 9.5 Discrete expansions and interpolation

Suppose one approximates a function through its discrete truncated expansion,
That is, instead of considering the exact projection coefficients , these are approximated by
discretizing the corresponding integrals using Gauss, Gauss–Lobatto or Gauss–Radau quadratures,
with given by Eq. (9.65) and any of the Gauss-type points. Putting the pieces together,
Since if is a polynomial of degree smaller than or equal to , the discrete truncated expansion
is exact for Gauss or Gauss–Radau quadratures according to the results in Section 9.4, it
follows that the above term inside the square parenthesis is exactly the -th Lagrange interpolating
polynomial,
Therefore, we arrive at the remarkable result:
The above simple proof did not assume any special properties of the polynomial basis, but does not hold
for the Gauss–Lobatto case (for which the associated quadrature is exact for polynomials of degree
). However, the result still holds (at least for Jacobi polynomials); see, for example,
[237].

Examples of Gauss-type nodal points are those given in Eq. (9.68) or Eq. (9.70). As we will see
below, the identity (9.80) is very useful for spectral differentiation and collocation methods, among other
things, since one can equivalently operate with the interpolant, which only requires knowledge of the
function at the nodes.