Download Rigid Body Simulation

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts
no text concepts found
Transcript
Rigid Body Simulation
Spring 2006
1
Contents
Unconstrained
Collision Contact
Resting Contact
Spring 2006
2
Review Particle Dynamics
State vector for a
single particle:
System of n particles:
Equation of Motion
Spring 2006
3
Rigid Body Concepts
Spring 2006
4
Rotational Matrix
Direction of the x, y, and z axes of the
rigid body in world space at time t.
Spring 2006
5
Velocity
Linear velocity
Angular veclocity

Spin: w(t)
How are R(t) and
w(t) related?
Columns of dR(t)/dt:
describe the velocity
with which the x, y,
and z axes are being
transformed
Spring 2006
6
Rotate a Vector
Spring 2006
7
Change of R(t)
=
Spring 2006
=
8
Rigid Body as N particles
Coordinate in
body space
Spring 2006
9
Center of Mass
World space coordinate
Body space coord.
Spring 2006
10
Force and Torque
Total force
Total torque
Spring 2006
11
Linear Momentum
Single particle
Rigid body as particles
Spring 2006
12
Angular Momentum
I(t) — inertia tensor, a 33
matrix, describes how the
mass in a body is distributed
relative to the center of mass
I(t) depends on the orientation
of the body, but not the
translation.
Spring 2006
13
Inertia Tensor
Spring 2006
14
Inertia Tensor
Spring 2006
15
[Moment of Inertia (ref)]
 I xx

I   I yx
 I zx

Spring 2006
I xy
I yy
I zy
I xz 

I yz 
I zz 
Moment of inertia
16
Table:
Moment of
Inertia
Spring 2006
17
Equation of Motion (3x3)
Spring 2006
18
Implementation (3x3)
Spring 2006
19
Equation of Motion (quaternion)
quaternion
 x(t )   v(t ) 

 1

d
d  q(t )   2 w (t )q(t ) 
Y (t )  


F (t ) 
dt
dt P(t )

 

 L(t )    (t ) 

 

3×3 matrix
Spring 2006
20
Implementation (quaternion)
Spring 2006
21
Non-Penetration Constraints
Spring 2006
22
Collision Detection
Spring 2006
23
Colliding Contact
Spring 2006
24
Collision
J
Relative velocity
Only consider vrel < 0
Impulse J:
Spring 2006
25
Impulse Calculation
[See notes for details]
Spring 2006
26
Impulse Calculation
For things don’t move (wall, floor):
1
1
 0
M 
Spring 2006
0 0 0
I 1  0 0 0
0 0 0
27
Uniform Force Field
Such as gravity
acting on center of mass
No effect on angular momentum
Spring 2006
28
Resting Contact: See Notes
Spring 2006
29
Exercise
Implement a rigid block falling on a
floor under gravity
Moments of inertia
Ixx = (32+22)M/12
Iyy = (52+22)M/12
Izz = (32+52)M/12
y
3
x
5
thickness: 2
Spring 2006 M = 6
Inertia tensor
 132
I body   0
 0
0
29
2
0
0
 132
1
0  I body   0
34 
 0
2 
0
0 
2 
34 
0
2
29
0
30
Three walls
Spring 2006
31
Related documents