Using the Lambert Solver for Lagrange points

MontBlanc2012

Active member
Joined
Aug 13, 2017
Messages
138
Reaction score
26
Points
28
This is the fourth in a series of posts about developing a Lambert Solver for Lagrange points.

I've spent the best part of a week testing the accuracy of the Solver in the Elliptic Restricted Three-Body Problem (ER3BP) model of Lagrange points and have verified that, if we ignore assorted perturbations, the solution that developed is very accurate indeed.

I've also spent time working out the operations to convert from state vectors (position and velocity) in inertial space to the rather curious pulsating-rotating coordinates of the ER3BP model. And these work too.

So, now for a simple application of the model....


The test case
The simple test application that I'm going to work through assumes that we have a stock DeltaGlider is placed at a (more or less) arbitrary point in space reasonably close to the Moon (circa 20,000 km - i.e., well within its Sphere of Influence) and we wish to design a transfer to the Earth-Moon L1 Lagrange point such that its arrival speed at L1 is a minimum. (For the purpose of this exercise, I'm going to ignore the velocity change needed to get onto the transfer trajectory to L1. This isn't entirely realistic, of course, but for this test application this assumption suffices.) The single 'free variable' that we have to play with in order to carry out the transfer from the Starting Point to L1 is the time of flight, [MATH]\delta t[/MATH].

Now, for my convenience (after having used parameters at a point in time shortly after the stock "Docked at ISS" commences), I've take the MJD of the transfers's start point to be:

[MATH]MJD = 51982.03806694[/MATH]
This, and other Orbiter parameters, were obtained by running a simple Lua script:

Code:
oapi.set_pause(true)

mjd     = oapi.get_simmjd()

earth		 = oapi.get_objhandle("Earth")
moon		 = oapi.get_objhandle("Moon")
	
-- get the current location of Earth
q_ear 	= oapi.get_globalpos(earth)
p_ear 	= oapi.get_globalvel(earth)
	
-- get the current location of the Moon
q_mon 	= oapi.get_globalpos(moon)
p_mon 	= oapi.get_globalvel(moon)

file = io.open("testmb2012.txt", "w")
io.output(file)
file:write("mjd  ", mjd, "\n")
file:write("q_e  ", q_ear.x, "  ", q_ear.y, "  ", q_ear.z, "\n")
file:write("p_e  ", p_ear.x, "  ", p_ear.y, "  ", p_ear.z, "\n")
print()
file:write("q_m  ", q_mon.x, "  ", q_mon.y, "  ", q_mon.z, "\n")
file:write("p_m  ", p_mon.x, "  ", p_mon.y, "  ", p_mon.z, "\n")
file:close()

oapi.set_pause(false)

From this information, and for that time, it was possible to determine the semi-major axis and the orbital eccentricity of the Moon in its orbit around the Earth to be:

[MATH]a = 381976671.6831\,\text{m}[/MATH]
[MATH]e = 0.06914561926012[/MATH]
[MATH]\nu_i = 1.667962711179\,\text{radians}[/MATH]
Moreover, we can also calculate the true anomaly, and set up a coordinate system based on the orbital plane of the Earth-Moon system for the date given. With this information, we can set up the conversion between inertial and ER3BP reference frames; and use the Lamber Solver for a given time-of-flight to calculate the arrival speed at L1.

So, what's our starting point. Well, for this exercise, I've decided to use the Earth-centric position vectors;

[MATH]X_i = -226478840.9679\, \text{m}[/MATH]
[MATH]Y_i = +25186750.0445\, \text{m}[/MATH]
[MATH]Z_i = -292840797.9784\, \text{m}[/MATH]
(I've used this Earth-centric reference frame because it is easy to transfer these numbers into Orbiter using the Scenario Editor.)

Now, what is this point in the ER3MB reference frame? Using the transformations between these two reference frames, we find that this point corresponds to:

[MATH]\eta_i = \alpha + 0.12[/MATH]
[MATH]\kappa_i = 0.03[/MATH]
[MATH]\phi_i = 0[/MATH]
where the [MATH]\eta_i[/MATH], [MATH]\kappa_i[/MATH] and [MATH]\phi_i[/MATH] are the equivalent x-y-z coordinates in the rotating-pulsating coordinates of the ER3BP reference frame. The value [MATH]\alpha[/MATH] is a parameter that identifies the location of L1 in this coordinate system, so in the ER3BP reference frame, we start at the point [MATH]{0.12, 0.03, 0.00}[/MATH] from the L1 point. And this point happens to be about 20,000 km from the Moon.

OK, so what about our end-point? Well, by definition almost, the end-point is located at the ER3BP point:

[MATH]\eta_f = \alpha[/MATH]
[MATH]\kappa_f = 0[/MATH]
[MATH]\phi_f = 0[/MATH]
What about our time-of-flight? This is a free variable that we will have to 'play around with' to see what value gives us a minimal arrival speed at L1. So, let's try varying the time-of-flight in 0.2 day increments and then calculate the arrival speed at L1. Part of this table is show below:

8.0 days: 3.71 m/s
8.2 days: 3.23 m/s
8.4 days: 2.85 m/s
8.6 days: 2.51 m/s
8.8 days: 2.21 m/s
9.0 days: 1.96 m/s
9.2 days: 1.75 m/s
9.4 days: 1.56 m/s
9.6 days: 1.41 m/s
9.8 days: 1.28 m/s
10.0 days: 1.17 m/s
10.2 days: 1.10 m/s
10.4 days: 1.05 m/s
10.6 days: 1.03 m/s
10.8 days: 1.05 m/s
11.0 days: 1.14 m/s

Evidently, we get a minimum in the arrival speed if we plan on a 10.6 day transfer. So, without trying to refine this 'optimal value' any further, let's use it to work out the initial velocity that we need. Fortunately, the Lambert Solver provides this information (almost) directly. In the ER3BP coordinate system, the initial velocity vector that we need is:

[MATH]\eta'_i = -0.5768982594219064[/MATH]
[MATH]\kappa'_i = 0.03752234431721768[/MATH]
[MATH]\phi_i' = 0.0[/MATH]
Now we can use our coordinate transformation to convert this back to eEarth-centric coordinates:

[MATH]VX_i = +1143.350513828\, \text{m/s}[/MATH]
[MATH]VY_i = -94.33306936334\, \text{m/s}[/MATH]
[MATH]VZ_i = -233.2804115072\, \text{m/s}[/MATH]
And now we can gather all of our information into Orbiter and set these initial conditions up in Orbiter. First, let's pause the simulator and enter in the MJD:

Screen_Shot_2018_04_24_at_8_17_31_PM.png


Nest, let's set up the state vectors:

Screen_Shot_2018_04_24_at_8_19_04_PM.png


And, Lo! If we now open up LagrangeMFD, we immediately get:

Screen_Shot_2018_04_24_at_8_19_56_PM.png


So, it looks as if the Lambert Solver has indeed produced a transfer plan that has us going to L1. Great! But that isn't quite the end of the story. All of the calculations have been set up using the 'pure', perturbation-free EM3BP model. The real Earth-Moon system, however, is subject to some noticeable perturbations - primarily due to the Sun. As I'll show in a subsequent post, this means that our transfer plan doesn't quite work as intended. What this means is that (as with all things in Orbiter), we have to set up a small corrective burn (~ 0.07 m/s or so) to get ourselves back 'on track'. Overall, though, the application of the Lambert Solver - and the associated trivial corrective burn - worked well leading to a near optimal transfer to L1.

Yay!
 
Last edited:

MontBlanc2012

Active member
Joined
Aug 13, 2017
Messages
138
Reaction score
26
Points
28
OK, I've made a short youtube video of a transfer to L1. The transfer was designed using the Lambert Solver - but it isn't optimal. Just a 'short' (6 day), simple transfer to demonstrate the fidelity of the Solver solution.

See:

Don't forget to turn the captions 'on' if you watch the video: that way, you'll get a few ad hoc comments.
 

ADSWNJ

Scientist
Addon Developer
Joined
Aug 5, 2011
Messages
1,667
Reaction score
3
Points
38
In the Lagrange MFD, the S4I solver for EML1 solves for vessel-Earth-Moon-Sun system. I always wondered if there was any value in calculating peturbations due to any other planet or moon, or whether it's so tiny that it's not worth the rounding error to calculate it.
 

MontBlanc2012

Active member
Joined
Aug 13, 2017
Messages
138
Reaction score
26
Points
28
ADSWNJ

I always wondered if there was any value in calculating peturbations due to any other planet or moon, or whether it's so tiny that it's not worth the rounding error to calculate it.

The solar perturbation is primarily a tidal contribution. Tidal contributions fall off very fast (1 / r^3) so unless we are quite close to a body, they are going to be very small. in the Earth-Moon-Sun system, the Sun's tidal contribution is only significant because it is so massive.

Let's guesstimate the relative contribution from, Venus, say. At closest approach, it might be just 1/3 of the distance away from the Earth as the Sun is. So, using the 1/r^3 law, that means that the tidal force is 27 times stronger. But, it is also 1,000,000 times less massive than the sun, so this reduces the tidal contribution by 1/1000000. In total, then, the tidal force (at best) is just 2.7 x 10^-5 of the Sun's tidal contribution. I think we can safely ignore this.

And you can go through all of the other planets in the same way and I think you'll conclude that the tidal contribution from any other body is way too small to worry about.
 
Top