No subject
Tue Nov 15 16:38:34 MST 2005
suddenly materialized right in the middle of your sphere (which has geometry
and a rigid body).
So what can ODE do? The sphere was not moving beforehand, and suddenly
there's this plane (or multiple planes) embedded inside of it, which have
no rigid body information associated with it. It can't dynamically resolve
the collision based on the "movement" of the plane, because from ODE's point
of view, the plane isn't moving - it just suddenly materialized.
The best ODE can do is to try to push the sphere back out of the plane to
move the system back into a legal configuration, and possibly to add a
"bounce" factor (specified in the contact joint) by mirroring (and reducing)
the velocity along the contact normal. Moving back into a legal configuration
is the role of the ERP, the error reduction parameter. Here, the error is
the amount of penetration, and depending on how high you set ERP, that will
control how much of a "spring force" is used to push the sphere back out.
Since no other forces are acting on your sphere, if you set ERP too high, the
sphere will fly away wildly.
The problem is that your sphere was not moving at all when the plane(s)
suddenly materialized inside of your sphere. So there is no relative velocity
to mirror, so there is initially no bounce. Only after the ERP starts to push
the sphere out of the plane will the sphere gain velocity (thus unphysically
gaining energy in the process, but your planes were also unphysically rotating
without any mass). This added energy might cause "superball" type behavior
where the sphere flies off wildly - depending on how high your ERP is and
how fast you rotate your planes.
I think it would probably be best to use boxes (with bodies and mass) to model
your movable geometry, since the alternative, movable geometry without any
rigid body information, is sort of a violation of the assumptions of a rigid
body simulator - you are discontinuously moving the system into illegal
(penetrating) configurations, so the best the simulator can do is to somehow
try to "cope".
-Norman
More information about the ODE
mailing list