Real analysis: simple second order ODE I'm studying real analysis at the moment (just covered the mean value theorem, constancy theorem, applications to DEs etc.) and have run across this question that I'm stuck on. Any help would be much appreciated - I have no idea where to start! 
"$f$ is an infinitely differentiable function $\mathbb{R}\to\mathbb{R}$ with $f(0) = f'(0) = 0$, satisfying $f''(x) = -f(x)$ for all $x$. Show that $f$ is identically zero."
Thanks! 

This can be done without assuming a certain solution (which would have to be proven as unique first). 
Consider $v=y'$ and write
$$ \frac{\mathrm{d}v}{\mathrm{d}x} =-y \\
\frac{\mathrm{d}v}{\mathrm{d}y} v =-y \\
\int v \mathrm{d}v = -\int y \mathrm{d}y \\
\frac{1}{2} (y')^2 = \frac{1}{2} y^2 + \frac{C}{2} \\
y' = \sqrt{C-y^2}
$$
Given that $y=0$ and $y'=0$ it means that $C=0$. We are going to apply this later so we don't end up with complex numbers. Now:
$$ \frac{\mathrm{d}y}{\mathrm{d}x} =\sqrt{C-y^2} \\
\int \frac{\mathrm{d}y}{\sqrt{C-y^2}} = \int \mathrm{d}x \\
\arctan\left(\frac{y}{\sqrt{C-y^2}}\right) = x+K
$$
Given that $x=0$ and $y=0$ it means that $K=0$.
$$ \frac{y}{\sqrt{C-y^2}} = \tan(x) \\
\frac{y^2}{C-y^2}+1 = \frac{C}{C-y^2}= \sec^2(x) \\
y = \sqrt{C} \sin(x)
$$
Since $C=0$, then $y(x)=0$ and consequently $y'(x)=0$
