Integrating Cubic Spline

Integrating Cubic Spline
$\begingroup$

Suppose that I have a finite number of samples of the function $f(x)$ for the range $a < x < b$. I don't have the expression for $f(x)$ but I can do a cubic spline interpolation. If I want to integrate the function $f(x)$ from $x=a$ to $x=b$, would the best approach be to simply do an exact integration for each of the cubic polynomial in the cubic spline, since the error would only be from the interpolation and not from the integration?

$\endgroup$
3
Sophia Al-Mansoor
Author

Sophia Al-Mansoor

Sophia analyzes international trade, startup ecosystems, retail transformation, and supply chain logistics for modern digital publications.