The question is to show that, given $f$ is a non-negative Riemann integrable function over an interval $[a,b]$, such that $\int_a^b f=1$, then we have that $$\left(\int_a^b f(x) \cos(x)\right)^2+\left(\int_a^b f(x) \sin(x)\right)^2\leq 1$$ And I cannot think of the correct trick here.
With the Cauchy-Schwartz inequality, I have gotten that $$\left(\int f \cos\right)^2+\left(\int f \sin\right)^2\leq \int f^2\int \cos^2+\int f^2\int \sin^2=\int f^2\int 1=(b-a)\int f^2$$ Which gives me almost the inequality I want, but how can I then argue about the value of $\int f^2$ working out properly? Or is my approach going completely up the wrong tree?