Graphics Reference
In-Depth Information
depths of penetration can create a net rotation. With sufficiently large penalty
forces this is a further potential for destabilization in the system as small trans-
lational error may lead to large rotational error.
35.6.5.4 Impulses
The problem with penalty forces is that they take time to apply, which makes their
effectiveness sensitive to the numerical integration scheme of a dynamics simu-
lator. Impulses are an alternative collision resolution strategy that avoids this by
directly and instantaneously changing velocities outside of the numerical integra-
tion process. This is a good example of the principle of knowing the limits of a
model and changing models, rather than patching, when those limits are exceeded.
Numerical integration of forces is stable for constant or slowly varying accel-
erations, such as those due to gravity, springs, and buoyancy. Numerical integra-
tion becomes more fragile for forces with dependency cycles or those that depend
on velocity, such as normal and friction forces. For accelerations that vary over
time scales shorter than the simulation interval, such as penalty forces, numerical
methods generally fail. One approach is to try ever-shorter simulation intervals
or more sophisticated integrators, but that is merely shifting the limitation of the
model rather than removing it. By pausing numerical integration, directly manipu-
lating velocities with momentum impulses, and then restarting numerical integra-
tion, we escape the inherent limitations of integrating derivatives. Note that there is
an analogous situation in light transport. In that context, an “impulse” is a spike in
a probability distribution function, such as created by a directional light source or a
perfect specular reflection. Integrating those zero-area phenomena is just as unsta-
ble as integrating a zero-time force. So, stable renderers explicitly handle specular
reflections and directional sources with absolute probabilities rather than attempt-
ing to make very small angular measurements of very high-magnitude probability
distribution functions. In dynamics, we will directly apply velocity changes rather
than trying to integrate large-magnitude derivatives of velocity over small-scale
time intervals.
Concretely, an instantaneous change means that the integral of acceleration ( x )
over a zero -second time interval is nonzero; therefore, x is infinite. So we're apply-
ing infinite force for zero time. Specifically, the force and acceleration functions
contain mathematical impulses. We can't directly represent impulses within the
integration framework because presenting an infinite acceleration to the numerical
integrator will simply result in infinity
0 = “not a number” under floating-point
representations, and because any attempt to perform higher-order integration on
such quantities will simply propagate the “not a number” value further. So we step
outside the integrator. This of course is a source of instability and error. Anytime
the integrator can't observe a value or control an operation, it becomes vulnerable
to roundoff and approximation errors in that operation.
The impulse equations are derived from the physical concept of linear momen-
tum, which is simply
×
p i ( t )= m i x ( t ) .
(35.46)
The change in velocity at a collision will therefore be
Δ x i ( t )= Δ p i ( t )
m i
.
(35.47)
 
Search WWH ::




Custom Search