I have the following system of ODE's

$$x'' = -\frac{x(t)}{\left(\sqrt{x^2(t)+y^2(t)}\right)^3}$$

$$y'' = -\frac{y(t)}{\left(\sqrt{x^2(t)+y^2(t)}\right)^3}$$

with conditions

and at time $t=0$ we have the initial condition $(x(0),y(0))$ and $(x'(0),y'(0))$

  • $\begingroup$ Your question is not well formulated, so it is unclear what you are asking. But there is a standard procedure, introducing new equations $x'=u$ and $y'=v$, then replacing $x''$ by $u'$ and $y''$ by $v'$ in your first two equations, thus ending up with a system of four first order equations. Is that what you're after? $\endgroup$ – Harald Hanche-Olsen Sep 7 '14 at 12:35
  • $\begingroup$ It helped @HaraldHanche-Olsen thanks you :) $\endgroup$ – Teodor Fredriksson Sep 8 '14 at 13:22

The equations you wrote are the equation of motions of a body in a gravitational potential.

In order to obtain what you want the best approach is to find some quantites which remain constant, that is the energy and the angular momentum.

You can write the total energy of the system in polar coordinates:

$$ E = \frac{1}{2} \left( r^2 \dot{\theta}^2 + \dot{r}^2 \right) - \frac{1}{r} $$

And the angular momentum

$$ l = r^2 \dot{\theta} $$

And replacing $\dot{\theta}$ in the first one:

$$ E = \frac{1}{2} \left( \frac{l^2}{r^2} + \dot{r}^2 \right) - \frac{1}{r} $$

$E$ and $l$ are obviously constant and depend on the initial conditions (btw, the ones you provided are incomplete; since the eq.s are 2nd order you need the initial velocity)

Reordering the equation noticing that $r$ is always positive you get:

$$ \dot{r} = \sqrt{ 2E + \frac{2}{r} - \frac{l^2}{r^2} } $$

Technically you still have 2 equations, the second one being the conservation of the angular momentum.


The substitution $x' = z$ and $y' = w$ gave $$ x'' = z'$$ $$ y'' = w'$$

and plugging this into the equations gives us the wanted system

$$\frac{dz}{dt} = -k\frac{x}{(x^2+y^2)^{3/2}}$$ $$\frac{dw}{dt} = -k\frac{y}{(x^2+y^2)^{3/2}}$$ $$\frac{dx}{dt} = z$$ $$\frac{dy}{dt} = w$$


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.