Yevgeni
- 2
- 0
Hello! This is my first post but definitely not my last.
I am programming a space simulator and my first problem to solve is to make gravitation work properly.
If I have two objects at arbitrary positions in three dimensional space I can calculate the net force between them in a straight line, but that does me no good for a Cartesian coordinate system. How do I break the forces down into three axes? I have found how to do this with two axes, but I can't apply this logic to three for some reason. Once I solve this problem I will put a "star" and a "planet" into my simulator and let you all know if I can make a stable orbit with this solution.
I am programming a space simulator and my first problem to solve is to make gravitation work properly.
If I have two objects at arbitrary positions in three dimensional space I can calculate the net force between them in a straight line, but that does me no good for a Cartesian coordinate system. How do I break the forces down into three axes? I have found how to do this with two axes, but I can't apply this logic to three for some reason. Once I solve this problem I will put a "star" and a "planet" into my simulator and let you all know if I can make a stable orbit with this solution.