Solve Kepler's equation using various methods. Solution of Kepler's equation is a key step in determining the position of a planet or satellite in its orbit. M is a fictitious angle that increases at a uniform rate from 0 at perihelion to 2Pi in one orbital period.
E is an angle at the center of the ellipse.
The answer is returned through the pointer passed as first argument. The function returns the number of iterations required or -1 in case of an error. Also possibly of interest is the included routine for calculating bessel functions of the first kind with integer index, although I'm sure the implementation is pretty naive.