# 3-Body Simulation and Accuracy of Lambert Interplanetary Solver

I've found that using a Lambert solver together with the equations of the patched conic approximation for an interplanetary flight from Earth to Mars is quite inaccurate, when taking Earth's gravitational field into consideration. I guess this is to be expected since it is an approximation, but this has got me thinking: How does one accurately calculate an interplanetary trajectory between two planets if the perturbative effects of the target, and more importantly, source planet are taken into account? I suppose one way to fix the trajectory once out of the Earth's sphere of influence would be to run the Lambert solver again and apply the required delta-v to the spacecraft, but this seems like a very inefficient thing to do when fuel is limited. Are there more advanced methods than the Lambert + patched conic approach out there, and if so, does anyone have any links to papers written on these topics? Any help would be greatly appreciated.

P.S. This is the output I get from a Lambert solution when disregarding the gravitational effects of Earth and Mars (inner semi-circle is the orbit of Earth, outer semi-circle is the orbit of Mars, and the line joining the two is the spacecraft's trajectory):

And this is the output I get from a Lambert + patched conic solution when taking the gravitational effects of Earth and Mars into accout:

The solutions are found using fully integrated trajectories. (Our Moon can be quite important too, if it's close to the outgoing trajectory at the time. Though you always need to take into account the total GM of the Earth-Moon system when departing. Jupiter is included as well, though I don't know how important that is. Also the center of the Sun has a small orbit about the Solar System barycenter ...)

The patched conic solutions provide a good starting point for finding the integrated solutions.

I'll see if I can find any published references for the techniques used. There are not a lot of people in the world who do this for a living.

• Thanks Mark, I'd be very interested in reading up on this topic further. When you say "fully integrated", what exactly do you mean by that? My model integrates the spacecraft's position from LEO about Earth until rendezvous (or should I say hopeful rendezvous) with Mars, would this be regarded as fully integrated? – InquisitiveInquirer Feb 11 '14 at 10:46
• Yes, if you include the gravity and accurate positions as a function of time of all of the relevant bodies. There are many such integrations of the complete trajectory run in order to match the end points. – Mark Adler Feb 11 '14 at 17:01