My instructor finally repsonded to my message. He makes it sound so much simpler than it is.
Thanks for everyone's help, but I guess my teacher wants it to be super simple and I have it figured out now.
Theta is the initial angle entered by the user and then updated as gravity is applied to the asteroid. It is a trajectory program that could be circular, but normally will not. The asteriod needs the ability to orbit, crash, or just do a flyby. Because initial distance, speed, and angle can...
I think I am starting to understand how to factor in gravity. I use the function:
g=\frac{GM}{r^2} and then use F_{g} =sin(\theta) for x coordinate and -F_{g} =cos(\theta) for y? If I am correct with this, I can program most of it and work in coef of friction when I get that figured out.
I have done a little research on the matter and I remember a bit from my high school Physics class. He is wanting us to use the inverse square law for gravity.
g=\frac{GM}{r^2}
The problem is, the gas giant doesn't have a radius, simply an atmosphere that is 1.0 units around it's center. Maybe...
Homework Statement
I need to know how to apply the coefficent of friction and gravity to a 3-coordinate (3D) velocity vector.
For my Intro to C Programming class, our final project is to write a program that simulates the trajectory of an asteroid passing a gas giant. The problem is, I...