Handling Penetration in Physics Demo with Cubes

  • Thread starter Thread starter bkenwright
  • Start date Start date
  • Tags Tags
    Penetration
AI Thread Summary
The discussion focuses on handling penetration in a physics demo involving cubes, particularly when using large time steps with Euler's integration. The main concern is the issue of collision detection leading to penetration, especially when an object is close to the ground and the time step approaches zero. A proposed solution involves backtracking the simulation to find the exact point of intersection by halving the time step until the object is just on the surface. However, this method may fail if the object is too close to the surface, as it could lead to a time step of zero, preventing further updates. The conversation highlights the complexities of collision detection and the challenges of accurately simulating physics in real-time scenarios.
bkenwright
Messages
7
Reaction score
0
Hi all,
I'm currently trying to write a simple physics demo with cubes, and am looking for the best way to handle penetration.

One method I was looking at is to back-track the collision detection till we find the point of intersection within some limit.. i.e.

collision at dt, so we step back dt/2 again and again till we have a hit within some limit...the only problem I'm having is...what if you have an object hitting the ground at dt of 0...doen's this mean our time step value is 0?...so the object increment is 0...hmmm.

Any ideas would be great.

Thanx

Ben

=)
 
Physics news on Phys.org
A comprehensible description would be just as nice.

What kind of cubes? Polynomial?

What is penetrating what?

Is dt a differential or measurement?

Etc.

What is the problem as presented by the instructor?
 
Well the case I'm trying to deal with is penetration on a general scale. For example, let's say you have a cube bouncing on a plane, and you have large time steps...and you use eulers integration...and just do each vertex point being below the plane to detect a collision.

Now, because the timesteps are large enough, for each time step when a collision is detected, there will be a small error where the cube penetrates the plane.

To solve this, I could back track the simulation to where the collision detection is just on the surface...ie.

store values
update dt (integrate)
while (penetrating)
{
restore values
dt = dt/2
update dt (use half dt)
}

But using this method, if the object is really close to the surface...then for any timestep greater than 0 its going to penetrate the surface due to gravity...so this will result in the above method reduce dt to almost 0...and hence its updates will fail :-/

Thanx for any help on this.

Ben

:)
 
I think it's easist first to watch a short vidio clip I find these videos very relaxing to watch .. I got to thinking is this being done in the most efficient way? The sand has to be suspended in the water to move it to the outlet ... The faster the water , the more turbulance and the sand stays suspended, so it seems to me the rule of thumb is the hose be aimed towards the outlet at all times .. Many times the workers hit the sand directly which will greatly reduce the water...
Back
Top