Celestial Mechanics: Solving Differential Equations for N-Body Systems

AI Thread Summary
The discussion centers on solving differential equations for the gravitational interaction between two celestial bodies, specifically using numerical methods like Euler's method. The equations for acceleration based on gravitational forces are established, and the user seeks guidance on progressing from these equations to plotting trajectories. A key insight shared is the transition from individual body coordinates to center of mass and relative coordinates, simplifying the problem to that of a single body under a central potential. For systems with more than two bodies, exact solutions are not feasible, and the iterative approach is recommended for calculating new positions and velocities based on current states. The goal is to gain proficiency with two-body systems before expanding to N-body problems for a numerical methods class project.
rizumu
Messages
1
Reaction score
0
I am getting stuck trying to solve a differential equation describing the gravitational relationship between two celestial bodies.

What I have so far is this:

a1 = G m2 (r2 - r1) / ||r2 - r1||^3

a2 = G m1 (r1 - r2) / ||r1 - r2||^3

where:
boldface denotes vectors in 3 dimensional Cartesian space
G for gravitational constant
m for mass
r for position
a for acceleration

I guess my question is where to go from here. I am assuming that the general solution will contain constants relating to initial position and initial velocity for both bodies. My goal is to arrive at a point where I can plot the trajectories of the two bodies using iterations. Essentially a system I can solve using numerical methods such as Euler's.

Anyway, any insight into how to solve this kind of problem would be great! Eventually I want to expand it to more than 2 bodies but I need to get comfortable with 2 first before taking the problem to N-bodies. This is for a numerical methods class, and possibly a final project/presentation.

Cheers!
 
Physics news on Phys.org
The equations for the trajectories of the two bodies (not the equations of motion) can be solved exactly, without approximations. The key is to pass from the r1 r2 coordinates to the R r coordinates, where R are the coordinates of the center of mass of the system, and r are the relative coordinates of the two bodies:

R = (m1 r1 + m2 r2) / (m1 + m2)

r = r2 - r1

If you carry out the calculations, it turns out that R satisfies the equations for a free body of mass M = m1 + m2:

MR''=0

and r satisfies the equation of motion of a single body of reduced mass

m = m1 m2 / (m1 + m2)

in a gravitational central potential with center fixed at the origin:

r'' = -Gmr / |r|^3

So the whole problem is reduced to the one of a single body.
 
I think you are looking more for an iterative procedure that applies to more than two bodies. With more than two bodies, it can't be solved exactly. Given that you know the positions and velocities at time step n, and you have calculated the acceleration as above, you just time step forward to calculate the new positions and velocities. Then you calculate the new accelerations and iterate.

x_{n+1} = x_n +v_{xn}*\delta t; y_{n+1} = y_n +v_{yn}*\delta t; z_{n+1} = z_n +v_{zn}*\delta t; v_{x n+1} = v_{xn} +a_{xn}*\delta t; v_{y n+1} = v_{yn} +a_{yn}*\delta t; v_{z n+1} = v_{zn} +a_{zn}*\delta t
 
Hi there, im studying nanoscience at the university in Basel. Today I looked at the topic of intertial and non-inertial reference frames and the existence of fictitious forces. I understand that you call forces real in physics if they appear in interplay. Meaning that a force is real when there is the "actio" partner to the "reactio" partner. If this condition is not satisfied the force is not real. I also understand that if you specifically look at non-inertial reference frames you can...
This has been discussed many times on PF, and will likely come up again, so the video might come handy. Previous threads: https://www.physicsforums.com/threads/is-a-treadmill-incline-just-a-marketing-gimmick.937725/ https://www.physicsforums.com/threads/work-done-running-on-an-inclined-treadmill.927825/ https://www.physicsforums.com/threads/how-do-we-calculate-the-energy-we-used-to-do-something.1052162/
I have recently been really interested in the derivation of Hamiltons Principle. On my research I found that with the term ##m \cdot \frac{d}{dt} (\frac{dr}{dt} \cdot \delta r) = 0## (1) one may derivate ##\delta \int (T - V) dt = 0## (2). The derivation itself I understood quiet good, but what I don't understand is where the equation (1) came from, because in my research it was just given and not derived from anywhere. Does anybody know where (1) comes from or why from it the...
Back
Top