|
-
Feb 18th, 2010, 03:19 AM
#1
Thread Starter
Not NoteMe
Particle Collision Algorithm
Hi all, this is more of an algorithm question than a maths question as i already have the collision/response formula working for a pair of particles and a particle with a convex polygon.
My problem is this. Lets say i have a flat object at the bottom, and drop lots of particles on it. What tends to happen is it takes ages for the particles to start spreading out. The ones on the edge only move out as the ones next to them move, and the particles in the middle of the bunch tend to just move back and forth rapidly as they continually bump.
I think one solution could be performing the collision detection/responses in a order according to how 'close' a particle is from an immovable object, or a particle that's touching an immovable object.
I have a query that will get me all particle pairs that are colliding, in no particular order.
I want an algorithm that will order something touching a wall first, then pairs with particles touching those next, then pairs with ones touching those pairs etc. If an algorithm to order the pairs like this is too expensive/complex then i'd like to just process them in that order, ideally without querying all remaining pairs each time.
Any suggestions welcome!
Quotes:
"I am getting better then you guys.." NoteMe, on his leet english skills.
"And I am going to meat her again later on tonight." NoteMe
"I think you should change your name to QuoteMe" Shaggy Hiker, regarding NoteMe
"my sweet lord jesus. I've decided never to have breast implants" Tom Gibbons
Have I helped you? Please Rate my posts. 
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|