JAMP  Vol.7 No.10 , October 2019
The Simulation and the Calculation of the Shortest Hohmann Transfer Orbit to Mars
Abstract: This paper will present the results and analyses of a simulation to send a satellite from the Earth to Mars. We use Python to simulate the orbit of the rocket. Our goal is to find the least energy-cost trajectory, with the least initial velocity. We find the date which allows the satellite to go from the Earth to Mars in the shortest distance based on a Hohmann transfer orbit considering the gravity of the Sun, Earth, and Mars.

1. Introduction

Mars, the closest planet to earth, has a lot in common with and has long been exploring. Since ancient times, “Mars has fascinated mankind” [1] . Finding retrograde motion of Mars not only improved Ptolemy’s geocentric theory, but also supported the heliocentric theory of Copernicus. “From then on, natural science liberated from theology” (Copernicus, 1543). Moreover, almost all of Kepler’s theories were based on observations of Mars for eighteen years. With the idea of “artificial canals” on the surface of Mars in 1877 [2] and the same year, A. Hall discovered two small satellites of Mars—Phobos and Phobos. In recent years, people increasingly considered Mars as another habitable planet, because of the environmental degradation on the earth and the evidence found on Mars. Radar evidence of subglacial liquid water on Mars found by the MARSIS instrument provided strong support to the importance of exploring Mars [3] .

With the attraction of this precious red planet, we do want to learn more about it. However, the high risk of sending the probes from the Earth to Mars is a big obstacle. Since the Soviet Union launched its first Mars probe in 1960, 46 missions have been launched around the world, with less than a 45 percent success rate. In the last century, a total of thirty-three detectors were launched worldwide, but only 9 of them were completely successful. The key concerns of launching process are the calculation of the track and the unknown accidents. When the detector approaches Mars, a slight deviation in the orbital calculation will cause amplified error enough to pass the planet. Also to be practical, fuel is another serious problem, which means the limited size of the aircraft restricted the amount of fuel carried. Then in order to solve these two problems, we try to figure out a better trajectory that can minimize the use of fuel with our careful calculation. We chose the Hohmann transfer as the basic model of our trajectory, because it’s undoubtedly the most fuel-efficient one of all the orbital paths, which has been proved hundreds of times, such as the article Journey to Mars: The physics of travelling to the red written by Stinner and Begoray (2005) [4] . In this paper, we simulate the launch of a detector from the Earth’s low Earth orbit, continuous moving by passing the sun and entering the orbit of Mars under solar gravitation with the help of PYTHON. In addition, on the basis of Hohmann’s orbit, we compared the 365 launch dates, the path generated, and the shortest distance path on a daily basis, which allows a relatively small amount of required fuel and short time. And then we calculated the time required, and the initial position of the Martian Earth, and chose the ideal launch date.

2. Organization

During our brainstorm, there were two routines of the probe from Earth to Mars that can travel for solving this problem: directly from the Perihelion of the Earth move to the Perihelion of Mars.

Because our simulation depends on the Hohmann transfer, we first simulated an elliptic trajectory from lower orbit (the earth orbit around the sun) to the higher orbit (the mars orbit around the sun). In order to be simple, we chose to simplified the whole solar system with seven planets to be only Sun, Earth, and Mars, and also treat Earth and Mars orbits as two circular orbits with the same center. Because we want the trajectory from Earth to Mars to be the shortest. Then we treat the Perihelion coordinate to be the starting point from Earth, and the aphelion coordinate to be the ending point approaching Mars. We used the data (speed and distance from sun of the Perihelion coordinate and the aphelion coordinate of two planets) to dot a point on every final positions of mars and earth in a linear motion with the gravitational force, and gain two oval orbits of them. However, in fact, those two points, aphelion and Perihelion, are not in the same line, because there is an angle between the long-axis of two ellipses. We use the knowledge in geometry to figure out the coordinate of one point in mars orbit and successfully “turn the orbit of Mars in a certain angle”. The orbits of two planets were fixed.

The next step of the research was to add the probe into the simulation. We assume an initial altitude of probe and calculate the initial angle and the speed which allow the probe to reach Mars. We simulate the first situation (move directly toward mars). The result was it requires a numerous amounts of energy allowing the probe move toward mars, resisting the gravitational force exerted by Sun. Then, we considered Sun’s gravity at first, and gain an approximate initial speed. Then, we tended to figure out the shortest distance for probe to reach Mars, and enter the orbit to rotate around mars. We used recursive algorithm again, to simulate every position of Earth on daily basis, found the shortest distance it need to take, and return the position of the earth. After we finished the final orbit of probe with the gravity of earth, we located the shortest position between the orbit of Mars and probe, and calculate the time of probe takes to reach this point. Finally, we calculated the initial position of mars. We used the possible mass of probe provided by professor to evaluate the altitude of the low mars orbit, and speed. We tried to figure out the shortest time period needed from launching from Earth and arriving on mars, but our computer was unable to finish such huge amount of computation. Then, we found the target launch date in the lists of the coordinates of earth and mars for our shortest routine plan and end up our research.

3. Materials and Methods

3.1. Experimental Tools

We used Python and Matlab to do the calculation and draw graph to simulate the orbits.

3.2. The Initial Data

In order to simulating the revolution orbit of Earth and Mars, we need initial data, the data is listed:

1) The mass, radius of Mars, Earth, and Sun respectively, and Distance to Sun, Perihelion Speed, Perihelion coordinates, and Period of Mars and Earth are displayed in Table 1 and Table 2.

2) G = Gravityconstant = 6.673 × 10 11 N m 2 kg 2

3.3. Depending Theory

Hohmann transfer

a certain trajectory from the Earth to Mars.

law of universal gravitation

Newton’s second law

F = m a

Law of conservation of energy

the total energy of an isolated system remains constant. Einitial = E 1 = E 2 = E 3 = = E n

Table 1. Mass and radius.

Table 2. Distance and Perihelion coordinates and speed.

Law of conservation of angular momentum

The total angular momentum of a system remains constant unless acted on by an external torque.

x,y components

We separated the x component and y component of Force, speed, acceleration.

4. Simulation and Analysis

4.1. Simulating Gravitational Environment

4.1.1. Modeling Gravitational Effect

G = 6.67 × 10 11

We calculate the gravitational forces between the Sun, Earth and Mars. The gravitational force between two masses is given by:

F = G M m r 2 r ^ (1)

According to the Newton’s second law F = m a , we obtain the acceleration:

a = G M r 2 r ^ (2)

4.1.2. Modeling the Revolution Orbit of Earth and Mars

In order to simulate the revolution orbit of Earth and Mars, we need Perihelion coordinates and Perihelion speed of Mars and Earth in the initial data.

Choose the time step (t) as one minute. Combined with gravitational effect, we can get the acceleration:

a n 1 = G M R n 1 2 r ^ (3)

Therefore, the velocity varies by acceleration:

v n = v n 1 + a n 1 t (4)

Also, the position varies by velocity:

x n = x n 1 + v n t sin θ (5a)

y n = y n 1 + v n t cos θ (5b)

Finally, the distance between the two objects is:

R n 1 = x n 1 2 + y n 1 (5c)

Because we have known the initial theta, we can draw the elliptical revolution orbit of Earth and Mars by using these equations (see from Figure 1).

4.2. Simulating a Trajectory

4.2.1. Determining the Trajectory

In order to find the least amount of fuel, we need to find the shortest distance from the initial position to the final position of the rocket.

Because of the Kepler’s first law: all planets move around the Sun in elliptical orbits, having the Sun as one of the foci, the rocket’s trajectory is elliptical and focuses on the Sun. As a result, the line connecting the initial position to the final position passes through the center of the Sun.

We have known that the initial position of the rocket is on the line between the Sun and Earth and 6800 km from the center of Earth and also on the line between the Sun and Mars and 3800 km from the center of Mars.

To find the shortest distance from the initial position to the final position, we use python to select it and print the coordinates of the initial and final position of the rocket. The results are below:

Rocket initial coordinate ( x 1 , y 1 ) ; rocket final coordinate ( x n , y n )

distance = ( x 1 x n ) 2 + ( y 1 y n ) 2 (6a)

a = semi-longaxis = Distance 2 = ( x 1 x n ) 2 + ( y 1 y n ) 2 2 (6b)

Figure 1. The orbit of Earth and Mars.

c = focallength = a x 1 2 + y 1 2 = ( x 1 x n ) 2 + ( y 1 y n ) 2 2 x 1 2 + y 1 2 (6c)

b = a 2 c 2 (6d)

4.2.2. The Velocity of Rocket to Transfer into the Hohmann Orbit

A) Simplifying the original problem

The problem in reality is quite difficult to solve by our hand calculation, we started from a simplified form that we ignore the competing gravitational effect from the Earth and Mars. In this situation, the rocket moves noticeably in a simple Keplerian elliptical orbit under the gravitation of the Sun, which we can use the Kepler’s law to solve the problem.

According to the Kepler’s second law, a line segment joining a planet and the Sun sweeps out equal areas during equal intervals of time, which represents the ratio of area to time as a constant.

d 1 = distance from the center of the earth to the rocket = 6878 km.

d 2 = distance from the center of mars to the satellite’s orbit which orbit around the mars = 4185 km.

d i = distance from the initial position to the center of sun= 1.473459836 × 1011 m.

d f = distance from the final position to the center of sun= 2.034171152 × 1011 m.

v i = velocity we need at the initial position.

v l = the lower velocity at the initial position.

v i l = the ideal initial velocity.

v f = the final velocity at the final position.

v f l = the ideal final velocity.

a = semi-long axis.

b = semi-short axis.

m = rocket (satellite).

v a = velocity at the point a.

v b = velocity at the point b.

Δ v = v a v b (7)

Area swept in a very small time interval at the initial position:

δ d i = 1 2 v i δ t (8)

Area swept in a period:

a t = π a b (9)

According to the Kepler’s third law, Square of the orbital period of a planet is proportional to the cube of the semi-major axis of its orbit. Combining with the Newton’s gravitation law, we can get the equation:

p t = 4 π 2 a 3 G M s u n (10)

Finally we get the equation:

δ a i δ t = a t p t = π a b 4 π 2 a 3 G M s u n = a b G M s u n 2 a 3 (11a)

The result is below:

v i l = 32786 m / s

v i l d i = v f l d f (11b)

v f l = 23734 m / s

B) Perturbation and Correction

Considering the competing gravitation of Sun, Earth and Mars, we can first get a range of the velocity.

-To determine the initial velocity

We start with velocity v l , which is equal to the orbital speed of the earth around the sun plus the escape velocity from the Earth:

v l = the lower speed

a) The Lower Speed

Because we ignore the Earth gravitational effect on the rocket, we can add the energy needed to escape from the earth to find a velocity which has lower magnitude than the actual velocity. v Escape = escape velocity from earth

1 2 m v Escape 2 G M earth m R earth = 0 (12)

v Escape = 11169 m / s

The kinetic energy:

1 2 m v l 2 = 1 2 m v i l 2 + 1 2 m v EscapeVelocity 2 (13)

v l = 34619 m / s

b) The Higher Speed

Because planets conserve energy at any point as it moves around the same star in an elliptical orbit, we can use the conservation law of energy to calculate the speed difference between the initial position and final position.

E a = 1 2 m ( v a v b ) 2 G M sun m d i G M earth m d l (14a)

E b = G M sun d f G M mars m d 2 (14b)

According to the conservation law of energy:

E a = E b (14c)

The figure of elliptical revolution orbits of Earth and Mars with pointing a and b is depicted in Figure 2.

We obtain the value of Δ v = 18117 m / s

Figure 2. Orbits with perihelion and aphelion.

The sum of v f and Δ v is greater than the true speed, because the ignorance of Earth and Mars gravitation.

As a result, we obtain a range of speed at initial position v ( v l , v f l + Δ v ) .

Using the Newton’s law of motion (Rocket Equation), we can get these functions:

x ( t + Δ t ) = x 0 + δ x δ t Δ t (15a)

y ( t + Δ t ) = y 0 + δ y δ t Δ t (15b)

v x ( t + Δ t ) = v x 0 + δ v x δ t Δ t (15c)

v y ( t + Δ t ) = v y 0 + δ v y δ t Δ t (15d)

a ( t + δ t ) = G M sun x t 2 + y t 2 + G M earth ( x t x e ) 2 + ( y t y e ) 2 + G M mars ( x t x mars ) 2 + ( y t y mars ) 2 (15e)

Input the initial position ( x 0 , y 0 ) , the range of initial velocity (get results every 50), and the duration of time steps, these functions help us to modeling the trajectory. We can use python to add up these steps and using numerical method for integration. The result is below:

v i = 41600 m / s

We then increase the velocity v l from velocity in small steps to find the trajectory that approximately intersects the designated point. From this process, we find the required change in velocity to be 648 m/s and the total velocity to be 41,600 m/s. With the total velocity, we find out that it takes 209 days for the satellite to approach to Mars.

We input the initial position ( x 0 , y 0 ) , the initial velocity in the range of ( v l , v f l + Δ v ) , adding 50 m/s each time until finding the trajectory that approximately intersects the designated point.

-To determine the day of the period from the starting point to the designated point.

Thus, we can get the time t S t o D for the satellite moving from the starting point to the designated point by keeping track of the real-time coordinates of the satellite.

t S t o D = 209 days

Initial probe.coordinate = [ 69178254048.58987 , 130096917958.33554 ]

After finding the time to travel to Mars, we can find the coordinate of Mars when the satellite is entering the trajectory.

We can then consider the 3 gravitational forces, and simulate the trajectory of the satellite as the Earth and Mars orbit the Sun.

We then iterate the initial velocity from 41,600 m/s to optimize the distance between the earth and Mars when they approximately get to the designated point. We thus get the optimal initial velocity v InitialVelocity , which is 41,655 m/s, and the distance between the satellite and Mars at that moment is 497,311 km.

The full figure of the trajectory and the figure of the designated part are shown in Figure 3.

In 4.2.3, we specifically explain how we draw the trajectory (see from Figure 4).

4.2.3. The Principle to Draw a Trajectory

To find out the position of the rocket at certain time and draw the trajectory, we can use the Newton’s law of motion.

x ( t + Δ t ) = x 0 + δ x δ t Δ t (16a)

y ( t + Δ t ) = y 0 + δ y δ t Δ t (16b)

v x ( t + Δ t ) = v x 0 + δ v x δ t Δ t (16c)

v y ( t + Δ t ) = v y 0 + δ v y δ t Δ t (16d)

a ( t + δ t ) = G M sun x t 2 + y t 2 + G M earth ( x t x e ) 2 + ( y t y e ) 2 + G M mars ( x t x mars ) 2 + ( y t y mars ) 2 (16e)

Input the initial position ( x 0 , y 0 ) and time step, we can get the initial acceleration; Input the initial speed and initial acceleration and time step, we can get the next step’s velocity; Input the next step’s velocity and time step, we can get

Figure 3. Trajectory of 41,600 m/s.

the next step’s position; We can use the python to add up all these steps and using numerical method for integration of trajectory.

4.2.4. Orbit from Low Earth Orbit

Calculating the acceleration

Thrust = v δ m δ t = 3000 tons (17a)

a t = Thrust m = v δ m δ t m = 10 m / s 2 (17b)

Initial position to accelerator.

m = the mass of rocket.

t equivalent = the period of the rocket orbit around the Earth orbit.

θ =the angle between the line which from the initial position to the center of Earth and the line from projection point to the center of Earth.

T = the time that need for accelerate from the initial velocity to the final velocity.

R = radius of Earth.

R sun = distance from the center of Sun to Earth.

h = low earth orbit’s height.

Figure 4. Trajectory of 41,600 m/s with detail.

After launching from the Earth surface, the probe enters the orbit around Earth, which is 500 km above the Earth surface, with the velocity of 7605.662596 m/s.

G M earth m ( R + h ) 2 = m v 2 R + h (18a)

v = G M earth R + h (18b)

v NearEarthOrbit = 6.67 × 10 11 × 5.965 × 10 24 6.378 × 10 6 + 5 × 10 5 = 7605.662596 m / s (18c)

G M sun M earth R sun 2 = M earth v earth 2 R sun (18d)

And then, we change the velocity relative to the earth by plus a velocity change in order to reach the velocity to start the elliptical trajectory to Mars which is about 41,645 m/s relative to Sun.

Δ v = 41655 7605 30287 = 3853 m / s (19a)

The process of velocity change of the probe near Earth is shown in Figure 5.

The Thrust is 3000 tons, and the designed the mass of the rocket is 300 kg.

The time period we use to change the velocity is now obvious to calculate

Figure 5. The Earth part of the velocity change.

t = Δ v a = 3853 10 = 385.3 s (19b)

Because the T is very small, we can ignore the offset track. Therefore, before the probe comes to the point where it starts the elliptical trajectory, it took a time period to change the velocity. In addition, the period of an orbit around the earth is

T NearEarthOrbit = 2 π ω = 2 π v NearEarthOrbit R + h = 2 π × ( 6.378 × 10 6 + 5 × 10 5 ) 7605 = 5682.544187 s (19c)

R earth = 6.378 × 10 6 m , h = 5 × 10 5

θ = v NearEarthOrbit R earth + h + 1 2 a R earth + h t 2 = 0.109137842031 (19d)

t equivalent = θ ω = θ v NearEarthOrbit R earth + h = 98.5957637656 days (19e)

According to the equivalent time around the orbit when accelerating, we can calculate the point where the probe starts the elliptical trajectory by python’s data.

4.2.5. Simulating the Transfer

We use the python to simulate the picture, but we ignore the competing gravitation of Earth and Sun. So the rocket accelerates on the Low Earth orbit and get out of the orbit at the projection point.

4.3. Orbiting from Hohmann Transfer Orbit to Mars Reconnaissance Orbit

4.3.1. Simplifying the Original Problem

The problem in reality is too complicated to solve, we started from a simplified form that we ignore the competing gravitational effect from the Earth and Mars. In this situation, the rocket moves noticeably a simple Keplerian ellipse under the gravitation of the Sun, which we can use the Kepler’s law to solve the problem.

We calculated the area that the Mars swept from the initial position to the end position by the function:

A = π a b tan 1 a y a x 2 π (20a)

A t = π a b (20b)

P t = 4 π 2 a 3 G M mars (20c)

A t = A t P t (20e)

t = A P t A t = π a b tan 1 a y a x 2 π 4 π 2 a 3 G M mars π a b = 31 days (20d)

Because of the Kepler’s second law, we know that the ratio of area to time as a constant. We know that it takes 209 days to Mars. After that, we need to use python to rearrange the data.

4.3.2. Perturbation and Correction

Considering the competing gravitation of Sun, Earth and Mars, we can first get a range of the period.

Because this initial day does not change so much, that we can try more days to make it better (adjust the period to enable the velocity).

Finally, the actual initial position coordinate is (69, 178, 254, 048.58987, −130, 096, 917, 958.33554), which needs 27.5 days to get there from the perihelion.

Starting point: the point where we start entering the trajectory from the near surface orbit about 500 km height above the earth surface.

Starting point = initial position.

Designated point: the point where we first get close to Mars (within 500,000 km).

-To change the velocity to get closer to Mars (within 5000 km from the mass center of the Mars). In order to get closer to Mars which is necessary for us to enter the orbit around Mars, we plan to change the velocity again by changing the acceleration on XY component, to get to the point within 5000 km away from Mars.

sin θ = a mainforce a mainforce 2 + a sideforce 2 = 0.04018 0.1483 2 + 0.04018 2 = 0.262 (21a)

cos θ = a mainforce a mainforce 2 + a sideforce 2 = 0.1483 0.1483 2 + 0.04018 2 = 0.965 (22b)

After 28 days acceleration, the velocity changed into 39,015 m/s. And the distance between the center of Mars and the satellite is 4185 km, which means the satellite is at the height of 788 km.

h = d aftera . R mars = 4185 3397 = 788 km (22a)

R mars = 3397 km

-To make the satellite orbit around Mars Then the satellite change the velocity into v aroundMars , and it can orbit around the Mars with the height of 788 km. The detail of the trajectory when the probe approaches Mars is displayed in Figure 6.

v aroundMars = G m mars d aftera . = 3199 m / s (22b)

4.4. Fuel Consumption

M 0 = initial mass of the rocket.

M = mass at time.

M p = mass of propellant.

v = the velocity of rocket.

F = net force = thrust.

v e q = equivalent engine exhaust velocity = I s p g

m f 1 = full mass at Low Earth Orbit.

m f 2 = the mass of the satellite after the first acceleration.

m e = empty mass = 300 kg.

Δ v = Δ v or Δ v

According to the Newton’s law of motion:

F = M δ v δ t = v e q δ M p δ t (23a)

Δ v = v e q ln m f m e = I s p g ln m f m e (23b)

Separating the fuel consuming into two part:

1) from Low Earth Orbit to Hohmann Transfer Orbit.

2) from Hohmann Transfer Orbit to Mars Reconnaissance Orbit.

Because we ignore the offtrack, there is no need to considering the variation of g in the process of acceleration.

Figure 6. The detail when the probe approaches Mars.

1) g = the gravitational acceleration at Low Earth Orbit

Δ v = 3753 m / s

g = G M earth ( R + h ) 2 = 8.625 N / kg (24)

m f 1 m f 2 = 2.9739

2) g = the gravitational acceleration at Mars Reconnaissance Orbit

Δ v = v aroundMars + v Mars v f = 6165.4 m / s (25a)

g = G M Mars ( R mars + h ) 2 = 2.9663 N / kg (25b)

m f 2 m e = 180.487

The total mass of fuel = m f 1

As a result, the total mass of fuel = 161,025 kg.

4.5. The Date the Satellite Escape the Orbit of the Earth

We use the table including the Azimuth angle and the distance from Mars and the earth to the sun on each day separately to find the date of the earth appearing on the perihelion. According to our calculation, we know if we speed up the satellite and escape from the earth orbit after the earth passes the perihelion, the distance the satellite getting to Mars is the shortest route. Then we find the next date of the earth arrives its perihelion, add 28 days after it, we get the ideal date is January the 31st in 2019.

5. Conclusions

By modeling the condition of launching a rocket to Mars and simulating the rocket trajectory, we have successfully optimized the route that enables the rocket efficiently travel from Earth to Mars within a short period of 209 days, by adjusting the initial values of the launching condition to a precision of 3 figures in our attempts to orbit around Mars. With the thrust provided and the calculated trajectory, we are able to send 300-tons rocket into space, which also signifies a large effective payload of rocket being put into the orbit of Mars. However, along with all our achievements also come the drawbacks. We ignore other planets’ gravity in the solar system.

We have tried our best to make our result as closer to the real situation as possible, but there are two limitations in our simulation that cause the error. Since our computers are not capable of running the code for some precise calculation, we have to approximate the real situation with some other ways to reduce the computation.

The first limitation is that the displacements of planets and probe in an extremely short period are infinitely close to linear segments, but our computers are not able to deal with the computation of such extremely short time period or integral. The only way we can cope with it is to calculate the linear displacement in certain short time period to simulate the real arc displacement of them. The second limitation is that we try to figure out the initial coordinates of Mars and Earth about the shortest time period plan, because the shortest time period means fewer risks for the probe to be damaged in the space. Our computers do not allow us to finish this simulation, so we have to abandon this plan.

Actually, although these approximations or errors have little impact on the result of the simulation, we have to admit that there is some unavoidable error between our simulation and the real situation of the movement of those celestial bodies.


First of all, we would like to thank our supervisor, Professor Gregory Tucker, a famous professor from Brown University who has provided us with crucial guidance for this paper. Besides, we thank Shaw Man, Kevin Huang, Kenny Rao for their contribution during the research. Moreover, we would also like to show our deeply gratitude to academic assistance, Zhijing Lu. Finally, we appreciate CIS program for providing us the precious chance to do this scientific research.

Cite this paper: Wei, Y. and Zhang, Y. (2019) The Simulation and the Calculation of the Shortest Hohmann Transfer Orbit to Mars. Journal of Applied Mathematics and Physics, 7, 2384-2400. doi: 10.4236/jamp.2019.710162.

[1]   Orosei, R., Lauro, S.E., Pettinelli, E., Cicchetti, A., Coradini, M., Cosciotti, B. and Seu, R. (2018) Radar Evidence of Sub-Glacial Liquid Water on Mars. Science, 361, 490-493.

[2]   Pettit, E. (1947) The Canal of Mars. Astronomical Society of the Pacific, 59, 5-11.

[3]   Rincón, á., Rojo, P., Lacruz, E., Abellán, G. and Díaz, S. (2015) On Non-Coplanar Hohmann Transfer Using Angles as Parameters. Astrophysics and Space Science, 359, 6.

[4]   Stinner, A. and Begoray, J. (2005) Journey to Mars: The Physics of Travelling to the Red Planet. Physics Education, 40, 35-45.