Computing the Jacobian matrix for a solar system simulation

Click For Summary
SUMMARY

The discussion focuses on computing the Jacobian matrix for a solar system simulation involving gravitational forces between two planetary objects. The user initially believes the Jacobian matrix will be 9x9, but clarification reveals it is actually a 1x3 gradient matrix derived from the gravitational force equation F = Gm1m2/r^2. The matrix is constructed by differentiating the gravitational force with respect to each dimension component (x, y, z), treating the other variables as constants.

PREREQUISITES
  • Understanding of gravitational force equations, specifically F = Gm1m2/r^2
  • Knowledge of partial derivatives and their application in matrix form
  • Familiarity with Jacobian matrices and their significance in physics
  • Basic programming skills for implementing mathematical models
NEXT STEPS
  • Study the construction and application of Jacobian matrices in physics simulations
  • Learn about gradient vectors and their role in optimization problems
  • Explore numerical methods for simulating gravitational interactions in programming
  • Investigate the use of libraries such as NumPy for matrix operations in Python
USEFUL FOR

Physics students, computer science students, and developers working on simulations of physical systems, particularly those interested in gravitational modeling and matrix calculus.

doonzy
Messages
2
Reaction score
0
Hello physicists!

I'm a comp sci student and I am trying to graphically model a simplified version of the solar system as part of a programming exercise. In order to apply the gravitational forces to the planets, I need to compute the Jacobian matrix as it relates to two particles (planetary objects). My (limited) understanding is that the resulting matrix will be 9x9, but I am unsure how it is constructed exactly. This is what I have come up with so far:

J = \begin{pmatrix}<br /> \frac{\partial F_1}{\partial r_1} &amp; \frac{\partial F_1}{\partial r_2} &amp; \frac{\partial F_1}{\partial r_3}\\ <br /> \frac{\partial F_2}{\partial r_1} &amp; \frac{\partial F_2}{\partial r_2} &amp; \frac{\partial F_2}{\partial r_3}\\ <br /> \frac{\partial F_3}{\partial r_1} &amp; \frac{\partial F_3}{\partial r_2} &amp; \frac{\partial F_3}{\partial r_3}<br /> \end{pmatrix}

where \frac{\partial F_i}{\partial r_i} is 3x3, F is the gravitational force F = \frac{Gm_1m_2}{r^2} and r is the respective dimension component (x, y, z).

Some clarification would be much appreciated :-)

Thanks.
 
Physics news on Phys.org
Well, ##r^2=\sqrt{r_1^2+r_2^2+r_3^2}##, hence ##F\, : \,\mathbb{R}^3 \longrightarrow \mathbb{R}## which means it has only one component and your Jacobian matrix is a gradient, i.e. of size ##1 \times 3##. The derivative is the same as at school: differentiate with only one variable ##r_i## and consider all other values as constant.
 

Similar threads

  • · Replies 3 ·
Replies
3
Views
4K
  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 1 ·
Replies
1
Views
6K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 0 ·
Replies
0
Views
2K
  • · Replies 0 ·
Replies
0
Views
562
  • · Replies 1 ·
Replies
1
Views
1K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K