TITLE: A false integral inequality
QUESTION [6 upvotes]: I have a problem which I think is wrong.

Let $f: [a,b] \to \mathbb{R}$ be a differentiable function with $f'$ continuous such that $$\int_a^b f(x) d x = f\left(\frac{a+b}{2}\right) = 0$$
Prove that $$\int_a^b \big(f'(x)\big)^2 d x - 2 \big(f(a) + f(b)\big)^2 \geq \frac{8}{(b-a)^2} \int_a^b \big(f(x)\big)^2 d x$$

If it's correct, can you show me your solution? Else, can you fix it?

REPLY [5 votes]: Omran Kouba's answer is very good, but here is a perhaps simpler counterexample. Take
$$f:[-2,2]\to\mathbb{R},\quad f(x)=x^2(x^2-12/5).$$
Then,
$$\int_{-2}^2f(x)dx=f(0)=0,$$
but
$$\int_{-2}^2f'(x)^2dx-2(f(-2)+f(2))^2=-\frac{19456}{175}<\frac{8}{(2-(-2))^2}\int_{-2}^2f(x)^2dx=\frac{47104}{7875}.$$