I was practicing my best approximation when I found this question:
Find the best approximation of $f$ in $G$, $f \in G$
$H:L^{2}[0,1]$ ; $ G = \{g \in H | \int_{0}^{1} g(x)dx = 0 \} $ ; $ f(x) = e^{x}$
I am not sure how to solve this problem. I know that for $g$ to be the best approximation of $f$ it has to satisfy the condition that $(f-g) \perp G$. But I am unable to apply it in this case. I also know that the approximation will exist since $G$ is closed.