# Find the number of points in $(-\infty,\infty)$ for which $x^2-x\sin x-\cos x=0.$ [closed]

Find the number of points in $(-\infty,\infty)$ for which $x^2-x\sin x-\cos x=0.$

This is a nice, differentiable function, and the question asks for only the number of solutions. I'll use the standard method to attack problems of this kind: we try to divide the function up into areas where it is growing and falling, and then appeal to the intermediate value theorem over a few domains to get the answer. For this particular case, this proceeds as below.

Let $f(x) = x^2 - x \sin x - \cos x$.

Note that:

$$f'(x) = x (2 - \cos x) : \left\{ \begin{array}{ll} >0 & \mbox{if } x > 0 \\ <0 & \mbox{if } x < 0 \\ = 0 & \mbox{if } x = 0 \end{array} \right.$$

and that $$f(0) = -1$$ $$f(x) \underset{x \to \pm \infty}{\longrightarrow} \infty$$

So, $f$ is always decreasing for negative $x$, is positive for negative $x$ with large magnitude, and is negative for $x = 0^{-}$. By this and the intermediate value theorem, there exists exactly one solution for $f(x) = 0$ in $(-\infty, 0)$

Similarly, there exists exactly one solution in $(0, \infty)$

As $x = 0$ is not a solution, the total number of solutions in $\mathbb{R}$ for the equation is $2$.

Here we have to calculate number of real values of $x$ in $x^2=x\sin x+\cos x$

So we will draw graph of $f(x) = x^2$ and $f(x) = x\sin x+\cos x$

First one is upward parabola passing through origin and for drawing graph of

$f(x)=x\sin x+\cos x\;,$ we will put $\displaystyle x=0\;,\frac{\pi}{2}\;,\pi,\frac{3\pi}{2},2\pi$ and $f(-x) = f(x)$

Means $f(x)$ is an even function .

So here these two graph intersect each other at $2$ distinct point

So we get number of real solution of the equation is $\bf{Two}$