|
|
Hi,
This is an animation i made 2 years ago. If i remember correctly
it should consist of about 500 bodies. The bodies are are randomly
placed inside of a cube with zero velocity waiting for the gravity
to get them moving. Theoretically my system supports collision
between particles but they are so small that they actualy never
collided. Especially in the beginning there are a lot of particles
which throw each other out of the system near lightspeed :)
This is due to the bad forward-euler-integration. Perhaps i will
rewrite my program with runge-kutta, that should avoid this problem.
Happy Galaxy-forming
Thies Heidecke
Post a reply to this message
|
|
|
|
I jsut put together a simple gravity simulation of my own using
(gravconstant)/d^2. There are no colisions and all the points are of the
same mass (that's why I don't need to multiply by the masses) and was having
the ame problem with stuff being shot off into space, but I found an
interesting solution. If I only calculate the effects of gravity if the two
objects are some distance from each other, the whole thing sticks together
very nicely. Some particles do drift off at a low velocity, but I suspect
they would come back in time. I know this is kind of cheating, but it looks
pretty descent, a lot better than having particles shoot off into space
seemingly at random.
Post a reply to this message
|
|