Given y=atan(x)/x, how can I get "x" for a given value of "y"? I have a simple C++ equation that I'm using to perform lens distortion correction.
$$y=\frac{\arctan(x)}{x}$$
where $x$ is in radians between 0.0 and 1.0.
I'm trying to come up with the inverse of this equation [get $x$ given $y$] but I've been unsuccessful. I got this far before my flabby math skills were exhausted:
$$xy = \arctan(x)$$
$$\tan(xy) = x.$$
I realize that this question sounds like a homework problem but trust me, I haven't had homework in several decades. I would appreciate pointers on where to look or even google terms.
 A: As said in comments and answers, there is no closed form of the solution and numerical methods need to be used.
Admitting you know Newton method, the problem is to start with a reasonable estimate of the solution. The nice thing is that using Pade approximants, we have $$y=\frac{\tan ^{-1}(x)}{x} \approx \frac{1+\frac{4 x^2}{15}}{1+\frac{3 x^2}{5}}$$ So, for a given $y$, solving the quadratic gives $$x_0=\sqrt{\frac{15 (1-y)}{9 y-4}}$$ Now, you can safely start Newton.
Edit
The formula can be improved assuming $$y=\frac{\tan ^{-1}(x)}{x} \approx \frac{1+ax^2 }{1+bx^2}$$ and setting $b=\frac{4 (a+1)}{\pi }-1$ in order to exactly match the value of $y$ at $x=0$ and $x=1$. Minimizing $$F(a)=\int_0^1 \Big(\frac{\tan ^{-1}(x)}{x}- \frac{1+ax^2 }{1+bx^2}\Big)^2\,dx$$ lead to $a=0.217886$ and accordingly $b=0.550661$ . This leads to  $$x_0=\sqrt{\frac {1 - y}{0.550661 y-0.217886}}$$
Edit
We can improve the approximation using an higher degree Pade approximant and get  $$y=\frac{\tan ^{-1}(x)}{x} \approx   \frac{\frac{64 x^4}{945}+\frac{7 x^2}{9}+1}{\frac{5 x^4}{21}+\frac{10 x^2}{9}+1}$$ and get $$x_0=\sqrt{\frac{3}{2}} \sqrt{\frac{\sqrt{35} \sqrt{800 y^2-1432 y+947}-350 y+245}{225
   y-64}}$$ For example $y=0.85$ will lead to $x_0=0.777582$ while the exact solution is $x=0.777478$ while the previous approximation lead to $x_0=0.774324$.
Using these estimates, one or two Newton iterations will be needed for six or more significant digits.
A: Equation is of transcendental character. Can't be solved in a closed form.
A: If you want to read x for given y, there are three ways.
First one is approximate, reading off from a graph.
Second use Newton-Raphson iteration procedure.
Third, set up a differential equation, change $ \frac {dy}{dx}\rightarrow \frac {-1}{dy/dx} $ and integrate to get x for uniform y increments. 
A: As said in a comment, the problem changed to $$y=\frac xk\, \tan^{-1}(xk)$$ Fos simplicity, let us define $t=kx$ and $z=k^2y$ to make $$z=t \, \tan^{-1}(t)$$ If we look at the graph of the function, there are clearly two different behaviors.
When $t$ is small (say $0 \leq z \leq 1$), $t \, \tan^{-1}(t)$ can be approximated either by a Taylor series which makes $$z \approx t^2-\frac{t^4}{3}$$ which leads to the approximation $$t\approx\frac{\sqrt{3-\sqrt{3} \sqrt{3-4 z}}}{\sqrt{2}}$$ or by a Pade approximant $$z \approx \frac{t^2}{\frac{t^2}{3}+1}$$ which leads to the approximation $$t\approx\frac{\sqrt{3} \sqrt{z}}{\sqrt{3-z}}$$
Let us try with $z=\frac 12$; the Taylor based approximation gives $t_0=\sqrt{\frac{1}{2} \left(3-\sqrt{3}\right)}\approx 0.796225$; Newton iterates xill then be : $0.765692$, $0.765379$ which is the solution for six significant figures. The Pade based approximation gives $t_0=\sqrt{\frac{3}{5}}\approx 0.774597$ from which the iterates are $0.765408$, $0.765379$.
More interesting is the case where $z$ is large; Taylor expansion gives $$z\approx \frac{\pi  t}{2}-1$$ which leads to the approximation $$t\approx \frac{2 (z+1)}{\pi }$$ Let us try with $z=10$; the Taylor based approximation gives $t_0=\frac{22}{\pi }\approx 7.00282$;  Newton iterates xill then be : $6.99854$ which is the solution for six significant figures.
