Prove that the equation $\tan x=p(x)$ has a solution I have the following question:
Given a polynom $p(x)$ I need to prove the the equation $\tan x=p(x)$ has at least one solution.
I defined the difference as a function $f(x)=\tan x-p(x)$ and I know that $f(x)$ is continues in any interval where $\tan x$ is defined, so I am trying to use the Intermediate value theorem, but I don't know how.
 A: Consider $$g(x)=\cos x\, p(x)-\sin x$$ We have $g(-\pi/2)=1$ and $g(\pi/2)=-1.$ Hence $g(x_0)=0$ for a point $x_0,$ $-\pi/2<x_0<\pi/2.$ Thus $$p(x_0)={\sin x_0\over \cos x_0}=\tan x_0$$
A: Here is how I would approach the problem, although there may be a more clever method.
We will restrict our view to the interval $I=(-\frac{\pi}{2}, \frac{\pi}{2})$. Since $p$ is a polynomial, it must be continuous on the closure  $\overline{I}=[-\frac{\pi}{2}, \frac{\pi}{2}]$. By the extreme value theorem, $p$ attains both a maximum and a minimum on $\overline{I}$. Therefore, there is some $m\in \mathbb{R}$ such that for all $x\in I, |p(x)|\leq m$.
On the other hand, $tan(x)$ is not bounded on $I$ and has the range $(-\infty, \infty)$.
Let $n=2m$. There exists some $x$ such that $tan(x)=n$. For this fixed $x$, $f(x)=tan(x)-p(x)\geq tan(x)-m=m\geq 0$. Similarly, there exists an $x$ such that $tan(x)=-n$. For this fixed $x$ we have $f(x)=tan(x)-p(x)\leq tan(x)+m=-m\leq 0$.
From the equations above, we see that there is and $x$ such that $f(x)\geq 0$ and an $x$ such that $f(x) \leq 0$. As you suggested, this is where we can apply the intermediate value theorem. $f$ is continuous on $I$ and attains values above and below $0$ so there must be some $x'$ between the two $x$ we found such that $f(x)=0$.
