TITLE: Differentiable and Continuous functions on [0,1] with 'weird' conditions.
QUESTION [12 upvotes]: I've been stuck on this one for a while. Comes from an analysis qual question.
Let f be a function that is continuous on $\left[0,1\right]$ and differentiable on $(0,1)$. Show that if $f(0)=0$ and $|f'(x)| \leq |f(x)|$ for all $x \in (0,1)$, then $f(x)=0$ for all $x \in \left[0,1\right]$.
What I've tried doing so far is see if there was anything I could do with MVT. I didn't really see anything to do with definitions either..to which I have a feeling I'll be playing around with them. Drawing a picture was a little difficult with these conditions as well
Any hints/suggestions?

REPLY [5 votes]: There is also a proof using the MVT:
Let $x_{0} \in (0,1)$.  The MVT implies that $\left | f(x_{0}) - f(0) \right | = \left| f'(x_{1}) \right| \left| x_{0} - 0 \right|$ for some $x_{1} \in (0,x_{0}).$  Also, $$ |f(x_{0})| = |x_{0}||f'(x_{1})| \leq |x_{0}| |f(x_{1})|$$ by assumption.  Applying the MVT again gives $$ |f(x_{0})| \leq |x_{0}| |x_{1}| |f(x_{2})|  $$ for some $x_{2} \in (0,x_{1}).$  Continuing in this way, we obtain a sequence of points $(x_{n})$ such that $x_{n} \to 0$ as $n \to \infty$ and $$ 0 \leq |f(x_{0})| \leq |x_{0}| ...|x_{n}| |f(x_{n+1})|.$$  But $f(x_{n}) \to 0$ as $n \to \infty$ (by continuity), so the squeeze theorem gives that $f(x_{0})=0.$  Thus $f(x)=0$ on $[0,1).$
Continuity then implies that $f(1)=0,$ completing the proof.