but if I want to calculate the time it take for a photon to go from the surface of the Earth to the surface of Mars then with the following information:
http://hyperphysics.phy-astr.gsu.edu...oldata.html#c1
I have:
y = integrate((m/|x-i| + n/|x-j| + o/|x-k| + h_g)/((m/|i| + n/|j| + o/|k| + h_g))*1/c, x)
y = (o*log(|x-k|) + n*log(|x-j|) + m*log(|x-i|) + h_g*x) / (c*(o/|k| + n/|j| + m/|i| + h_g))
Where:
• m = 1.989e30 kg (mass of the Sun)
• i = -(1496e8 + 12756000/2) m (position of the Sun)
• n = 5.976e24 kg (mass of the Earth)
• j = -(12756000/2) m (position of the Earth)
• o = 6.42e23 kg (mass of Mars)
• k = 2279e8 - 1496e8 m (position of Mars)
• h_g = 1.35e27 kg/m (or c^2/G as solved in post #165)
Then for a:
x = (2279e8 - 1496e8) - 6794000/2
I get:
t = 260.98873 s