Regularity in the trapezoidal rule

50 Views Asked by At

I tried to understand if the following sentence is true of false. Let $u$ be an absolutely continuous function defined in $[0,2\pi]$ such that $u(0)=u(2\pi)$. Let $n\in \mathbb{N}, h=\frac{2\pi}{n}$ and $t_i=ih$ with $1\leq i\leq n$, then for the trapezoidal rule: $\int_0^{2\pi}u(t)^2dt=\sum_{i=1}^n u(t_i)^2+O(\frac{1}{n^2})$. I thought that the function must be $C^2$ for have a quadratic error, so i think the claim is false, but i cannot produce a counterexample, can you provide me a counterexample or the proof in the case it is true?