The velocity of a point
The velocity of a point on an object depends on both its linear and angular velocity:
\[\dot{q} = \dot{\theta} \times (q - p) + \dot{p} \qquad \qquad [1.0] \]where \(\dot{q}\) is the velocity of the point, \(p\) is the position of the point in world coordinates,\(p\) is the position of the origin of the object, and \(\theta\) is the angular velocity of the object.
Impulse
An instantaneous change in velocity.In the same way that we have
\[f = m\ddot{p} \qquad \qquad [1.1] \]for forces,we have
\[g = m\dot{p} \qquad \qquad [1.2] \]一般时使用p而不是使用g,但是为了防止和位置(p)冲突所以使用了g。这个impulse和force是等价的。一些作用力不只是通过加速度来体现出来,有些是通过速度而不是加速度体现的。其实 \(\dot{p}应该是速度的改变吧,此处有疑问\)
Impulsive Torque
.
The linear component is given by
\[\ddot{p} = \frac{1}{m}f \qquad \qquad [1.3] \]and the angular component by the torque
\[\tau = P_{f} \times f \qquad \qquad [1.4] \]where the torque generates angular acceleration by
\[\ddot{\theta} = I^{-1}\tau \qquad \qquad [1.5] \]In the case of the collision it stands to reason that the collision will generate a
linear change in velocity (the impulse) and an angular change in velocity. An instantaneous
angular change in velocity is called an “impulsive torque”.
where the \(u\) is the impulsive torque. \(I\) is the inertia tensor, and \(\theta\) is the angular velocity.该公式对应了上面的[1.2] (个人感觉此处应该是angular velocity的改变值)
Impulses behave just like forces. In particular for a given impulse there will be both a linear component and an angular component.The impulsive torque generated by an impulse (impluse也会产生impulsive torque) is given by
\[u = P_{f}\times g \qquad \qquad [1.7] \]for collisions the point of application \(P_{f}\)is given by the contact point and the origin of the object:
\[P_{f} = q - p \qquad \qquad [1.8] \]where \(q\)is the position of the contact in world coordinates and \(p\) is the position of
the origin of the object in world coordinates.
VELOCITY CHANGE BY IMPULSE
Impulses cause a change in velocity both angular and linear.
The Linear Component
The linear change in velocity for a unit impulse will be in the direction of the impulse, with a magnitude given by the inverse mass:
\[\Delta\dot{P}_{d} = m^{-1} \qquad \qquad [1.9] \]For collisions involving two objects, the linear component is simply the sum of the two inverse masses:
\[\Delta\dot{P}_{d} = m_{a}^{-1} + m_{b}^{-1} \qquad \qquad [1.10] \]The Angular Component
First, equation 1.7 tells us the amount of impulsive torque generated from a unit
of impulse:
where d is the direction of the impulse (in our case the contact normal).
Second, equation 1.6 tells us the change in angular velocity for a unit of impulsive
torque:
And finally, equation 1.0 tells us the total velocity of a point. If we remove the
linear component, we get the equation for the linear velocity of a point due only to
its rotation:
So we now have a set of equations that can get us from a unit of impulse, via the
impulsive torque it generates and the angular velocity that the torque causes, through
to the linear velocity that results.
Vector3 torquePerUnitImpulse = relativeContactPosition % contactNormal; (参考:1.11)
Vector3 rotationPerUnitImpulse = inverseInertiaTensor.transform(torquePerUnitImpulse); (参考:1.12)
Vector3 velocityPerUnitImpulse = rotationPerUnitImpulse % relativeContactPosition; (参考:1.13)
标签:Engine,Development,linear,qquad,torque,velocity,Resolution,angular,dot
From: https://www.cnblogs.com/ultramanX/p/18000508