If $f$ belongs to $C[0, \pi]$ and $f(0) = 0$. Determine the cases where the given condition implies that $f$ is identically zero.
Case 1 $\int_{0}^{\pi}\ x^nf(x) =0$ for all non negative integer n
Case 2 $\int_{0}^{\pi}f(x)\cos nx =0$ for all non negative integer n
Case 3 $\int_{0}^{\pi}f(x)\sin nx =0$ for all positive integer n
What I know is if $f(x)$ greater or equal to $0$ in the interval then $\int_{0}^{\pi}\ f(x) =0$ implies $f(x) = 0$.If I use Weierstrass approximation theorem I would get the first case done. But I can not understand how to proceed for last two cases. Can anyone help me out? For your information all the cases are true.