# Deviation of semi-major axis

If I calculate the semi-major axis of Molniya-1T with $$a = \sqrt[3]{\dfrac{GM}{n^2}}$$ with $$n=3.18683728\text{ }d^{-1}$$, I get another apoapsis ($$a=19505.7$$ km) as noted at Heavens Above:

apogee height: 25659 km

perigee height: 595 km

which is $$a=\frac{25659+595}{2}=13127$$ km.

This is my approach in Octave/MATLAB:

# Computes the semi major axis a from n with constant GM
# @params:
#   GM constant (cubic km per square second)
#   n: mean motion  (revs/day)
# @return:
#   a: semi major axis (km)

function a = getSemiMajorAxis(GM,n)
n = n*2*pi/(24*60*60); #conversion (revs/day) --> (rad/s)
a = (GM/(power(n,2))).^(1./3);
endfunction

getSemiMajorAxis(398600.44,3.18683728) # Test with Molniya-1T


So, what is the origin of the deviation? Isn't apogee the same as apoapsis basically?