🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Gravitational acceleration calculation

Started by
143 comments, last by taby 1 year, 10 months ago

But i think if i do more planets, and they align to form a line, which will happen sooner or later, then the strong gravity will pull them all out of orbit.

And then, much earlier than thought, we are all fucked! /8O\

Advertisement

P.S. Don’t forget to set the delta-time to something suitable, like 0.0001 or something like that.

Oh, don't worry. I have spent the recent months to tweak simulation parameters, i have experience.
There always is just a narrow range of parameters where the crap barely works. And my terrain still does not look good.

There is no timestep in the sim, so it's 1. But all other parameters give still a nice result of… awesome circles ; )

Sorry man, I was more talking to the other dude. ?

@taby I don’t. I’m planning on adding some features that will force me to understand how to calculate this. Edit: Replying to your question about circular orbit’s.

None

@taby , regarding dT, I’m just letting the frame rate be dT. it’s not even a variable in my latest sums. Although perhaps I should just in case.

None

You don’t need to use a dt of 1. for instance, in my Mercury orbit simulation, I use a dt of 10000 seconds, which is 0.116 Earth days per timestep.

See: https://github.com/sjhalayka/mercury_orbit_glut/blob/54dd9f93b6f8a7c4dd808d8cc42e93f3055d8ec6/main.cpp#L63

taby said:
You don’t need to use a dt of 1. for instance, in my Mercury orbit simulation, I use a dt of 10000 seconds, which is 0.116 Earth days per timestep.

I'm sure you could use 1, and rescaling simulation and its parameters you would get the same results.
Maybe it would be worth it in cases, to get rid of some instructions.

But rescaling is not trivial. Some params depend on size, others on volume (or area). I actually need rescaling, and it's frustrating to get this right for all the things.

@joej @taby , Take a look at some of the progress that's been made. http://www.theblewitts.online/

None

Nice : )

Bug report: If i enable ‘show orbit lines’ it stops working.

This topic is closed to new replies.

Advertisement