# Probability that Mercury is the nearest planet to Earth.

Motivation: We tend to think of Venus as the nearest planet to Earth because at its nearest approach to Earth, Venus is the closest at 39 million Km away. This is followed by Mars at 56 million Km and Mercury at 83 million Km. Surprisingly, if we look at the entire year, Mercury ends up being the closest to Earth 46% of the time, followed by Venus 36% of the time, and Mars 18%. This is because orbits of Venus and Mars are huge compared to that of Mercury so while Mercury does not have the nearest approach to Earth, its is never too far away; but Venus and Mars spend most of their time far away from Earth. In fact on an average, Mercury is the nearest planet to every other planet in the solar system.

Our simplistic system: Consider a circular co-planar planetary system with a sun in the center and $$n$$ planets $$p_1, p_2,\ldots, p_n$$ orbiting counter clockwise at radius $$r_1 < r_2 <\ldots < r_n$$ respectively. Assuming the mass of the planets are negligible compared to that of the sun, orbital velocity is $$v_i = \displaystyle \frac{\beta}{\sqrt{r_i}}$$, where $$\beta$$ is some constant. For any given planet, the the remaining planets are equally likely to be anywhere in their respective orbits i.e. uniformly distributed relative to one another over a long period of time. Also, if $$r_{i+1} - r_i > r_{i-1} + r_{i}$$ then $$p_{i+1}$$ will never be the nearest planet to $$p_{i}$$. So to make the system interesting, we must have $$r_{i+1} < r_{i-1} + 2 r_{i} < 3r_i$$. Hence we assume that $$r_{i+1} = \alpha r_{i} = r_1 \alpha^i$$ where $$1 < \alpha < 3$$ and $$i \ge 1$$. This makes sense because most planetary system are know to follow some kind of Titius Bode type rules with their own set of constants.

Question: What is the probability that the inner most planet is the nearest planet to the $$k$$-th planet? Is it possible to have a closed form in term of $$r_i, \alpha$$ and $$\beta$$?

Update: I think the direction and orbital velocity matters because once a planet $$p_i$$ becomes the nearest planet of $$p_k$$, it remains the nearest planet to $$p_k$$ for some time until another planet $$p_j$$ becomes the nearest i.e. even though the relative positions of the planets are uniformly distributed over a long period of time, there is a non-random order which determines which is the nearest at time $$T+1$$ given the state of the system at time $$T$$. I have updated the questions accordingly.

• Comments have been moved to chat; please do not continue the discussion here. Before posting a comment below this one, please review the purposes of comments. Comments that do not request clarification or suggest improvements usually belong as an answer, on Mathematics Meta, or in Mathematics Chat. Comments continuing discussion may be removed. Commented Apr 28 at 13:08

Per the comments, here's some MATLAB code that runs a simulation using both random planetary positions and deterministic positions based on orbital velocities.

For both, I've set up polar coordinates centred at the sun. To simplify the calculations a bit, I've taken Earth to be on the positive $$x$$-axis and looked at the $$\theta$$ coordinates of the other planets relative to that.

For a planet with polar coordinates $$\left(r_i,\theta_i\right)$$, its Cartesian coordinates are $$\left(r_i \cos \theta_i,r_i \sin \theta_i\right)$$; the coordinates of Earth are $$\left(r_e,0\right)$$ and so the square of the distance we're interested in is $$\left(r_i \cos\theta_i-r_e\right)^2+r_i^2\sin^2 \theta_i=r_e^2+r_i^2-2r_e r_i \cos \theta_i$$

The code generates $$\theta$$ coordinates for each planet using the different assumptions then calculates how often each is the nearest to Earth and prints the results.

Caveat: I was not initially expecting to publish this code so although I've commented it a bit, it's not the neatest! Please feel free to ask any questions in the comments and I'll try to clarify.

%orbital radii
re=149.6;   %Earth
r=[57.9;108.2;228];   %per https://nssdc.gsfc.nasa.gov/planetary/factsheet/
lbls=["Mercury","Venus","Mars"];
np=length(r);   %number of planets exc Earth

%number of simulations
Nmax=1e7;

%assuming random uniform distribution for planet angles
th_rnd=rand(np,Nmax)*2*pi;

%calculate squares of distances from each planet to Earth
%creates a 3xNmax array
dist_rnd=re^2+r.^2-2*re*r.*cos(th_rnd);

%how often is each planet the closest to Earth?
[~,closest]=min(dist_rnd,[],1); %indices of nearest planet

%display results
disp("Using random uniform distributions for angles")
for i=1:np
fprintf("%s: %.3f\n",lbls(i),sum(closest==i)/Nmax);
end

%% Orbital velocities - deterministic
%run simulation over a long time
Tmax=1e7;
tspan=1:Tmax; %duration

beta=1; %constant for orbital velocities

%angular velocities of planets relative to Earth
ang_vel=beta./r.^(3/2)-beta/re^(3/2);

%randomise start angles
th0=rand(np,1);

th_det=th0+ang_vel*tspan;

%calculate squares of distances from each planet to Earth
%creates a 3xNmax array
dist_det=re^2+r.^2-2*re*r.*cos(th_det);

%how often is each planet the closest to Earth?
[~,closest]=min(dist_det,[],1); %indices of nearest planet

%display results
disp("Using orbital velocities for angles")
for i=1:np
fprintf("%s: %.3f\n",lbls(i),sum(closest==i)/Tmax);
end

• If there's a better way to format this code on MathJax, please let me know! Commented Apr 12 at 11:29

Lifting my comments to an answer basically to try and more verbosely explain how I interpreted the given details, and what my simulations did.

My interpretation of the probabilities is the following. We pick a loooooong interval of time, something that will even out each and every near synch the orbits of the planets may have. I made the following assumptions:

1. The orbits of the planets are concentric circles, each on the same plane. This is not quite correct, but since Pluto lost its status, the differences are (IIRC) rather minor.
2. If we fix an imaginary line on that plane emanating from the Sun, the angles describing the positions of the planets relative to that line of reference are all uniformly distributed in $$[0,2\pi)$$ and independent from each other. As I was leaving e.g. the asteroids locked into synchronized orbits by the gravitational pull of Jupiter out of the reckoning, this is another simplification unlikely to matter much.
3. In my simulation I used the values in the list $$R=\{57.9, 108.2, 149.6, 227.9, 778.6, 1433.5, 2872.5, 4495.1\}$$ for the radii of the orbits of the planets. I used millions of kilometers because I'm most comfortable with those. Using miles or AUs won't change the results.
4. In the simulations I first fixed a planet, say number $$n$$, $$n=1$$ for Mercury etc. I first initialized a vector of counters to all zeros. I then repeated the following loop $$10^6$$ times:
• pick random angles in $$[0,2\pi)$$ giving the positions of the planets on their respective orbits for planets other $$n$$th, which can be thought of as stationary (this makes no difference for reasons of rotational symmetry)
• calculate the distances of the other planets to planet $$n$$, and record which is closest at this point in time, incrementing the corresponding counter
• print out the final frequencies of all the planets.

I am optimistic about this interpretation, because using Earth as the base planet ($$n=3$$rd rock from the Sun) lead to the following frequencies: Mercury was the closest with probability 46.5%, Venus with probability 36.7% and Mars with 16.7%.

Other results:

• Comparing the distances to Venus instead, the odds are: Mercury is the closest 66.7% of the time, Earth 27.2% and Mars 6.1%.
• Mars is surprisingly uniform: Mercury is the closest with probability 35%, Venus 32% Earth 33%.
• But when comparing distances to Jupiter the scene is different. Of all the other planets Mars is the closest 35.3% of the time followed by Earth (26.2%), Venus (19.2%), Mercury (14.9%) and Saturn (5.1%).
• With the outer planets the list is broadly similar, the probability for Mercury to be the closest goes down, and the "adjacent" planet leads the pack.

Here is my attempt at explaning as to why Mars is most often the planet closest to Jupiter. Consider the following image. The Sun is the orange blob, Jupiter is cyan, Mars red, Earth green, Venus blue and Mercury brown. Their orbits are included.

I added two circles centered at Jupiter. One grazes the orbit of Earth, the other that of Mercury. We think of Jupiter's position as fixed (the cyan blob). If Mars is on Jupiter's side of the smaller circle, then it is guaranteed to be the planet closest to Jupiter (Saturn is not shown, but its distance from the Sun exceeds twice the distance between Sun and Jupiter minus the distance between the Sun and Earth, and it cannot compete with Mars under the circumstances). Mars can still be the closest even if it happens to be outside this zone, but anyway this region boosts Mars's chances by a fair amount.

On the other hand, for Mercury to have a chance at being the one closest to Jupiter, all of Venus, Earth, Mars need to be beoynd the outer circle. This is already somewhat unlikely, and places an upper bound on Mercury's chances.

My Mathematica code:

R = {57.9, 108.2, 149.6, 227.9, 778.6, 1433.5, 2872.5, 4495.1}
M = 8
phases := Table[2 Pi*Random[], {i, 1, M}]
planets := Module[{k, kulmat = phases},
Table[R[[k]] {Cos[kulmat[[k]]], Sin[kulmat[[k]]]}, {k, 1, M}]]
lahin[p_, n_] := Module[{min, vert, k, j, diff},
k = n;
min = 10^12;
For[j = 1, j < M + 1, ++j,
If[j != n,
diff = {R[[n]], 0} - p[[j]];
vert = diff . diff;
If[vert < min, min = vert; k = j];]];
k
]
freq = Table[0, {k, 1, M}]

freq

In light of the other interpretation of the question, if we want to compare the average distances between two planets we can do the following. Again assume that we have two planets following circular orbits in the same plane. Assume that the respective radii are $$R$$ and $$r$$. If $$x$$ is the distance between the two planets, and $$\theta$$ is the angle between them as seen from the Sun, then the law of cosines tells that $$x^2=R^2+r^2-2Rr\cos\theta.$$ With similar independence assumptions as above, it follows that the expected value of $$x^2$$ is $$E(x^2)=R^2+r^2,$$ because $$\theta$$ is uniformly distributed in the interval $$[0,2\pi)$$, and therefore $$E(\cos\theta)=0$$. This already hints at Mercury having the lowest average squared distance to any planet. After all, keeping $$R$$ (=the other planet) fixed, minimizing $$r$$ (=picking Mercury) minimizes $$E(x^2)$$ by the above formula.
It may be possible to make a similar reasoning about $$E(x)$$, but in that case, instead of integrating cosine over a full period, we have the more complicated elliptic integral. I won't go there :-)