Composite Rule Error Decomposition

A question that asks students to express the error of a composite quadrature rule as a sum of local errors on subintervals and use this decomposition to establish global error estimates.

grandes-ecoles 2021 Q12 View
We consider the case of an arbitrary segment $I = [a,b]$ (with $a < b$), subdivided into $n+1$ equidistant points $a_0, \ldots, a_n$: $$\forall i \in \llbracket 0, n \rrbracket, \quad a_i = a + ih,$$ where $h = \frac{b-a}{n}$ is the step of the subdivision. The trapezoidal rule is $$T_n(f) = \frac{b-a}{n} \sum_{i=0}^{n-1} \frac{f(a_i) + f(a_{i+1})}{2}.$$
Represent graphically $T_n(f)$.
grandes-ecoles 2021 Q13 View
We consider the trapezoidal rule on $I = [a,b]$: $$T_n(f) = \frac{b-a}{n} \sum_{i=0}^{n-1} \frac{f(a_i) + f(a_{i+1})}{2},$$ where $a_i = a + ih$ and $h = \frac{b-a}{n}$, with associated error $e_n(f) = \int_a^b f(x)\,\mathrm{d}x - T_n(f)$.
Suppose that $f$ is a function of class $\mathcal{C}^2$ from $[a,b]$ to $\mathbb{R}$. Show that $$e_n(f) = \frac{b-a}{n} \sum_{i=0}^{n-1} e(g_i)$$ where $e$ is the error associated with the quadrature formula $I_1$ studied in question 11 and the $g_i : [0,1] \rightarrow \mathbb{R}$ are functions to be specified.