Live data from Hacker News

Show HN: A gravitational simulator toy that implements the Barnes-Hut algorithm

skepsi.me

1–3 of 3 posts

Re: Show HN: A gravitational simulator toy that implements the Barnes-Hut algorithm

#2
The "show quad tree" feature is really neat looking and educational for showing someone the Barnes-Hut algorithm. Is there a way to create lots of particles at once? Barnes-Hut isn't really needed until you hit thousands of particles, so can I create a galaxy of n particles quickly?

Re: Show HN: A gravitational simulator toy that implements the Barnes-Hut algorithm

#3
post #2

The "show quad tree" feature is really neat looking and educational for showing someone the Barnes-Hut algorithm. Is there a way to create lots of particles at once? Barnes-Hut isn't really needed until you hit thousands of particles, so can I create a galaxy of n particles quickly?

You can use the "r" hotkey to create a bunch of random particles, but I think it only creates ~10 at a time (but you can hold the button down). That's a good idea, though.