# Prove rigorously: $x^2=2^x$ has exactly $3$ real solutions [duplicate]

I am not sure how to prove rigorously (using calculus) that $x^2=2^x$ has exactly $3$ real solutions.

## marked as duplicate by Cameron Buie, Travis Willse, peterwhy, user147263, Aaron MarojaAug 22 '15 at 22:39

• You can study the continuous function defined on $\mathbb{R}$ by $f(x)=x^2-2^x=x^2-e^{x\ln(2)}$ (using derivative and second derivative). – Augustin Aug 22 '15 at 22:26
• @Augustin you mean $e^{x\ln(2)}$... – YoTengoUnLCD Aug 22 '15 at 22:28
Let $f(x)=2^x-x^2$. Then, $f'''(x)$ is always positive, so $f$ has at most three roots by Rolle's theorem. To prove that there are at least three roots, note that $f(-1)=-0.5$, $f(0)=1$, $f(3)=-1$, $f(5)=7$.