Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics...

14
1 K i n e m a t i c s & D y n a m i c s Thomas Funkhouser Princeton University C0S 426, Fall 2000 O v e r v i e w • Kinematics Considers only motion Determined by positions, velocities, accelerations • Dynamics Considers underlying forces Compute motion from initial conditions and physics

Transcript of Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics...

Page 1: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

1

Kinematics &Dynamics

Thomas Funkhouser

Princeton University

C0S 426, Fall 2000

Overview

• Kinematics� Considers only motion� Determined by positions, velocities, accelerations

• Dynamics� Considers underlying forces� Compute motion from initial conditions and physics

Page 2: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

2

Example: 2-Link Structure

• Two links connected by rotational joints

Θ1

Θ2

X = (x,y)

2

1

(0,0)

“End-Effector”

Forward Kinematics

• Animator specifies joint angles: Θ1 and Θ2

• Computer finds positions of end-effector: X

))sin(sin),cos(cos( 2121121211 Θ+Θ+ΘΘ+Θ+Θ= llllX

Θ1

Θ2

X = (x,y)

2

1

(0,0)

Page 3: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

3

Forward Kinematics

• Joint motions can be specified by spline curves

Θ1

Θ2

X = (x,y)

2

1

(0,0)

Θ2

Θ1

t

Forward Kinematics

• Joint motions can be specified by initial conditionsand velocities

Θ1

Θ2

X = (x,y)

2

1

(0,0)

1.02.1

250)0(60)0(

21

21

−=Θ=Θ

=Θ=Θ

dt

d

dt

d

��

Page 4: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

4

Example: 2-Link Structure

• What if animator knows position of “end-effector”

Θ1

Θ2

X = (x,y)

2

1

(0,0)

“End-Effector”

Inverse Kinematics

• Animator specifies end-effector positions: X

• Computer finds joint angles: Θ1 and Θ2:

xllyl

yllxl

))cos(())sin((

))cos(()sin((

22122

221221 Θ++Θ

Θ++Θ−=Θ

Θ1

Θ2

X = (x,y)2

1

(0,0)

−−+=Θ −

21

22

21

221

2 cosll

llxx

2

Page 5: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

5

Inverse Kinematics

• End-effector postions can be specified by splinecurves

Θ1

Θ2

X = (x,y)

2

1

(0,0)

y

x

t

Inverse Kinematics

• Problem for more complex structures� System of equations is usually under-defined� Multiple solutions

Θ1

Θ2

2

1

(0,0)

X = (x,y)

3

Θ3

Three unknowns: Θ1, Θ2 , Θ3Two equations: x, y

Page 6: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

6

Inverse Kinematics

• Solution for more complex structures:� Find best solution (e.g., minimize energy in motion)� Non-linear optimization

Θ1

Θ2

2

1

(0,0)

X = (x,y)

3

Θ3

Inverse Kinematics

Fujito, Milliron, Ngan, & SanockiPrinceton University

“Ballboy”

Page 7: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

7

Summary of Kinematics

• Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors

• Inverse kinematics� “Goal-directed” motion� Specify goal positions of end effectors Compute conditions required to achieve goals

Inverse kinematics provides easier specification for many animation tasks,but it is computationally more difficult

Inverse kinematics provides easier specification for many animation tasks,but it is computationally more difficult

Overview

• Kinematics� Considers only motion� Determined by positions, velocities, accelerations

• Dynamics� Considers underlying forces� Compute motion from initial conditions and physics

Page 8: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

8

Dynamics

• Simulation of physics insures realism of motion

Lasseter ‘87

Spacetime Constraints

• Animator specifies constraints:� What the character’s physical structure is

» e.g., articulated figure� What the character has to do

» e.g., jump from here to there within time t� What other physical structures are present

» e.g., floor to push off and land� How the motion should be performed

» e.g., minimize energy

Page 9: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

9

Spacetime Constraints

• Computer finds the “best” physical motionsatisfying constraints

• Example: particle with jet propulsion� x(t) is position of particle at time t� f(t) is force of jet propulsion at time t� Particle’s equation of motion is:

� Suppose we want to move from a to b within t0 to t1with minimum jet fuel:

0’’ =−− mgfmx

dttft

t∫1

0

2)(Minimize subject to x(t0)=a and x(t1)=b

Witkin & Kass ‘88

Spacetime Constraints

• Discretize time steps:

02

’’2

11 =−−

+−= −+ mgf

h

xxxxm i

iiii

2∑i

ifhMinimize subject to x0=a and x1=b

211

1

2’’

h

xxxx

h

xxx

iiii

iii

−+

+−=

−=

Witkin & Kass ‘88

Page 10: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

10

Spacetime Constraints

• Solve withiterativeoptimizationmethods

Witkin & Kass ‘88

Spacetime Constraints

• Advantages:� Free animator from having to specify details of

physically realistic motion with spline curves� Easy to vary motions due to new parameters

and/or new constraints

• Challenges:� Specifying constraints and objective functions� Avoiding local minima during optimization

Page 11: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

11

Spacetime Constraints

• Adapting motion:

Witkin & Kass ‘88

Heavier Base

Original Jump

Spacetime Constraints

• Adapting motion:

Witkin & Kass ‘88

Hurdle

Page 12: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

12

Spacetime Constraints

• Adapting motion:

Witkin & Kass ‘88

Ski Jump

Spacetime Constraints

• Editing motion:

Li et al. ‘99

Page 13: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

13

Spacetime Constraints

• Morphing motion:

Gleicher ‘98

Spacetime Constraints

• Advantages:� Free animator from having to specify details of

physically realistic motion with spline curves� Easy to vary motions due to new parameters

and/or new constraints

• Challenges: Specifying constraints and objective functions! Avoiding local minima during optimization

Page 14: Kinematics & Dynamics - Princeton University · 7 Summary of Kinematics • Forward kinematics Specify conditions (joint angles) Compute positions of end-effectors • Inverse kinematics

14

Dynamics

• Other physical simulations:" Rigid bodies# Soft bodies$ Cloth% Liquids& Gases' etc.

Hot Gases(Foster & Metaxas ‘97)

Cloth(Baraff & Witkin ‘98)

Summary

• Kinematics( Forward kinematics

» Animator specifies joints (hard)» Compute end-effectors (easy - assn 5!)

) Inverse kinematics» Animator specifies end-effectors (easier)» Solve for joints (harder)

• Dynamics* Space-time constraints

» Animator specifies structures & constraints (easiest)» Solve for motion (hardest)

+ Also other physical simulations