I'm trying to calculate the eccentricity of a binary system's body knowing the bodies' velocities, positions, masses and the semi-major axis. I am only trying to calculate the eccentricity for one of the bodies but can't seem to get the formulas combined right to get the eccentricity only using these values. Any advice would be brilliant, thanks!
[Physics] Calculating eccentricity from semi-major axis, position and velocity of particles
astrophysicsorbital-motion
Related Solutions
Yes, you can derive all of these quantities. The specific orbital energy $E$ is $$ \begin{align} E &= \frac{1}{2}v^2 - \frac{\mu}{r}= -\frac{\mu}{2a}, \end{align} $$ where $ \mu = GM^3/(M+m)^2 $, and $a$ is the semi-major axis. The orbital period follows from Kepler's Third Law: $$ T^2 = (2\pi)^2\frac{a^3}{\mu}. $$ If you also know the radial velocity $v_r$ and the tangential velocity $v_T$ separately at $r$, then you can also calculate the specific relative angular momentum $h$ and the orbital eccentricity $e$: $$ \begin{align} h^2 &= r^2\,v^2_{T} = \mu a(1-e^2). \end{align} $$
Edit
Several people have tried to change $\mu$ into $\mu = G(M+m)$. This is wrong, because that is the formula for relative motion instead of motion with respect to the centre of mass. The equations of motion of the two-body problem are $$ \begin{align} m\ddot{\boldsymbol{r}}_m &= - \frac{GmM}{|\boldsymbol{r}_m - \boldsymbol{r}_M|^3}\left(\boldsymbol{r}_m - \boldsymbol{r}_M\right),\\ M\ddot{\boldsymbol{r}}_M &= \frac{GmM}{|\boldsymbol{r}_m - \boldsymbol{r}_M|^3}\left(\boldsymbol{r}_m - \boldsymbol{r}_M\right),\\ \end{align} $$ where $\boldsymbol{r}_m$ and $\boldsymbol{r}_M$ are the positions of the small and large body with respect to the centre of mass. What we want is to express the motion of the small body in terms of $\boldsymbol{r}_m$. By definition, the position of the centre of mass remains constant, $$ m\boldsymbol{r}_m + M\boldsymbol{r}_M = \boldsymbol{0}, $$ so that $$ \boldsymbol{r}_m - \boldsymbol{r}_M = \frac{M+m}{M}\boldsymbol{r}_m. $$ Therefore, $$ m\ddot{\boldsymbol{r}}_m = -GmM\frac{M^3}{(M+m)^3r^3_m}\left(\frac{M+m}{M}\boldsymbol{r}_m\right), $$ or $$ \ddot{\boldsymbol{r}}_m = -\frac{\mu}{r^3_m}\boldsymbol{r}_m, $$ with $\mu = GM^3/(M+m)^2$. In my answer, $r = r_m$. I hope this clears things up.
What you are asking for is not simple at all. Retrograde motion occurs when the line joining two planets rotates with respect to a fixed coordinate system (or the fixed stars) in the opposite direction as the planets. With both planets in motion in orbits that are not nicely aligned with each other, the times between retrograde motion will only be described by a complicated expression.
If you are numerically simulating the planets' orbits, here's what you can do:
- Choose a coordinate system so that the Earth lies in the x-y plane. It's motion will be described by some function of time: $$\vec{x}_{earth} = \begin{bmatrix}x_{earth}(t)\\y_{earth}(t)\\0\end{bmatrix}$$
- Define the other planet's motion in the same coordinate system. $$\vec{x}_{planet} = \begin{bmatrix}x_{planet}(t)\\y_{planet}(t)\\z_{planet}(t)\end{bmatrix}$$
- The angle between the line joining the planets and the fixed coordinate system is found by subtracting the two vectors and using the two-argument inverse tangent function on the x- and y-coordinates. $$\vec{x}_{planet} - \vec{x}_{earth} = \begin{bmatrix}\Delta x(t)\\\Delta y(t)\\\Delta z(t)\end{bmatrix}$$ $$\theta(t) = \textrm{atan2}(\Delta y(t),\,\Delta x(t))$$
- The planet is in retrograde motion with respect to Earth when $$\frac{\textrm{d}\theta}{\textrm{d}t} < 0$$ assuming the planets orbit anticlockwise in the coordinate system.
Best Answer
Hint 1:solve around the barycenter, maybe you can use the reduced mass
Hint 2: Try doimg what I call 'overloading the system'. Start by assuming you know everything (eccentricity, both axes, position/velocity at any point). Now derive as many relations as possible.