orientation += orientation - prev_orientation + (torgue/mass) * dt * dt;
Is that correct?
The orientation is quaternion here. Torgue is Vector3
Verlet Integration Problem
Im unsure how this works. Ive never worked with quarternions.
The way i understand quarternions they're like complex numbers only with 3 imaginary parts instead of one. In that case the notation should be:
orientation *= orientation / prev_orientation * acc * dt^2
where acc is some quarternion acquire from your bodies intertial matrix and applied torques. Just dividing the torque vector with the mass wont do in 3d. Alot of things get more complicated when moving from 2d particle physics to 3d rigid body physics.
But im probably totally wrong.
How to acquire acc and your inertial matrix is another topic for another thread.
The way i understand quarternions they're like complex numbers only with 3 imaginary parts instead of one. In that case the notation should be:
orientation *= orientation / prev_orientation * acc * dt^2
where acc is some quarternion acquire from your bodies intertial matrix and applied torques. Just dividing the torque vector with the mass wont do in 3d. Alot of things get more complicated when moving from 2d particle physics to 3d rigid body physics.
But im probably totally wrong.
How to acquire acc and your inertial matrix is another topic for another thread.
Thanks! I'll figure out how can i do it with that. The main thing is The Formul is always the same you just change names of values. position to orientation, forceAccum to torgueAccum.
I fully understand it. And found a way to do it. Change the Quat to Euler Angle calculate and change reverse. :)
Thanks,
Kasya
I fully understand it. And found a way to do it. Change the Quat to Euler Angle calculate and change reverse. :)
Thanks,
Kasya
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement