Root of continuous function using Rolle's Theorem

$$f(x)= 1 + e^x\cos(x)$$ $$g(x)= 1 + e^x\sin(x)$$

Show that there is at least one root of $g$ between two roots of $f$

How do I start to answer this question and do I need to use Intermediate Value Theorem?

• Maybe if $r$ and $s$ are consecutive roots of $f$ then the numbers $g(r)$ and $g(s)$ are of opposite sign. Sep 30 '13 at 9:55
• Are you sure you haven't swapped $f$ and $g$? Rolle's theorem easily implies a zero of $f$ between two zeros of $g$. For a zero of $g$ between two roots of $f$, I don't see how Rolle's theorem would suffice. Sep 30 '13 at 9:55
• yeah i just realised that i mistakenly swapped the two functions. I have corrected them now. But i still don't know how to solve it. Sep 30 '13 at 11:10
• I tried to start by assuming a,b are two roots of f(x) and using Rolle's theorem, there exist c in (a,b) where f'(c)=0. Then how to show that there at least one root of g(x) between them? Sep 30 '13 at 11:19

Rolle's theorem says that for any differentiable function $h$, there is a zero of $h'$ between any two zeros of $h$. (It is slightly more general, any two points where $h$ attains the same value will do.)
The given functions are not in the form that $g = f'$, but they are closely related. We can transform the problem into a shape where Rolle's theorem applies by multiplying both functions with a suitable function that vanishes nowhere, let
$$\tilde{f}(x) = e^{-x} \cdot f(x);\quad \tilde{g}(x) = e^{-x}\cdot g(x).$$
Then $\tilde{f}$ has the same zeros as $f$, and $\tilde{g}$ has the same zeros as $g$. And although we don't have $\tilde{f}' = \tilde{g}$, they are related closely enough for Rolle's theorem to apply.
• Well, $e^{-x}$ is never zero, and the product of two real numbers is $0$ if and only if at least one of the factors is $0$. So $e^{-x}\cdot f(x) = 0 \iff f(x) = 0$. Sep 30 '13 at 12:10