Solve for x in tanx-2x=0 I know homework questions are generally frowned upon here, but I've run into the following equation, which I've tried to solve and am having a genuinely hard time with:
$$\tan(x)-2x=0,x\in(-\pi/2, \pi/2)$$

So far I've tried adding $2x$ to both sides and doing some manipulations, but I can't seem to isolate the $x$ (and I'm not even sure if that's what I have to do here). I guess in the worst case scenario I could always just graph $y=\tan(x)$ and $y=2x$ and see where they intersect, but surely there has to be a better way to do it?
 A: This kind of equations, which mix polynomials and trigonometric functions, do not present solutions in terms of simple functions and only numerical methods could be used to get the solution(s).
Since you had a look at the plot of the function, you noticed that, in the considered range, beside the trivial solution $x=0$, there two roots close to $1.2$ and $-1.2$.
So, let us consider Newton method which, starting from a "reasonable" guess $x_0$, will update it according to $$x_{n+1}=x_n-\frac{f(x_n)}{f'(x_n)}$$ Let us use it for $$f(x)=\tan x - 2x$$ $$f'(x)=\sec ^2(x)-2$$ and start with $x_0=1.2$. So the iterates are $1.16935$, $1.16561$, $1.16556$ which is the solution for six significant figures.
A: There is no direct way of calculating a closed form solution for $x$ from the equation $\tan x - 2x = C$ for an arbitrary value of $C$
That said, however, in your particular case, plotting both $\tan x$ and $2x$ will quickly show you there are more solutions. One is the zero function, the other two can be only calculated numerically.
