Paper Summaries Any takers? Dynamics I Note on next lectures - - PDF document

paper summaries
SMART_READER_LITE
LIVE PREVIEW

Paper Summaries Any takers? Dynamics I Note on next lectures - - PDF document

Paper Summaries Any takers? Dynamics I Note on next lectures papers: Linear Motion Topic: Poupourri NOT Angular Motion Though a paper on Aerodynamic forces has been added Projects Plan for today Proposals were


slide-1
SLIDE 1

Dynamics I

Linear Motion

Paper Summaries

  • Any takers?
  • Note on next lecture’s papers:

– Topic: Poupourri – NOT Angular Motion

  • Though a paper on Aerodynamic forces has been

added

Projects

  • Proposals were due last Monday

– Please submit if you haven’t already done so.

  • I will return proposals with feedback by

Monday.

Plan for today

  • Physics 101 for rigid body animation

Motivation Films

  • Two more Academy Award winning Pixar

films.

Motivational Film

  • Tin Toy (1988)

– Technical challenge: life like baby. – First computer animated short to win an academy award.

slide-2
SLIDE 2

Motivational Film

  • Geri’s Game (1997)

– Technical challenge: Human & Clothing Modeling – Geri makes a cameo appearance in Toy Story II.

Let’s get started

  • Physics for Rigid Body Dynamics

– Note: Change in original schedule

  • Today: Linear Motion
  • Monday: Rotational Motion
  • Wednesday: Collisions
  • Monday, April 7: Numerical Integration /

Constraints

Using Physics in Animation

  • To achieve physically accurate motion, go

to the source!

– Keyframing accurate physical motion is tedious.

  • Use physics to calculate motion

– Removes control from animator!!

The Source: Sir Isaac Newton

  • 1643-1727
  • Discovered (amongst
  • ther things)

– Calculus – Physics of Light – Physics of Motion

  • Busy Man

Laws of Motion

  • Law I

– Every object in a state of uniform motion tends to remain in that state of motion unless an external force is applied to it. (Inertia)

  • Law II:

– The acceleration of a body is proportional to the resulting force acting on the body, and this acceleration is in the same direction as the force.

  • Law III:

– For every action there is an equal and opposite reaction.

Cartoon Laws of Motion

  • Law I

– Any body suspended in space will remain in space until made aware of its situation.

  • Law III

– Any body passing through solid matter will leave a perforation conforming to its perimeter.

  • Law VII

– Certain bodies can pass through solid walls painted to resemble tunnel entrances; others cannot.

  • Law IX

– Everything falls faster than an anvil.

slide-3
SLIDE 3

Terms

  • For Linear Physical Motion

– Mass

  • Measure of the amount of matter in a body
  • From Law II: Measure of the a body’s resistance to motion

– Velocity

  • Change of motion with respect to time

– Acceleration

  • Change of velocity with respect to time

– Force

  • In short, force is what makes objects accelerate

Terms

  • Mathematically defined

– Velocity – Acceleration – Force

dt ds v / = dt s d dt dv a / /

2

= =

ma F =

Terms

  • Said another way:
  • If we have force and mass, we can calculate

motion. m t F t a ) ( ) ( =

= dt t a t v ) ( ) (

= dt t v t s ) ( ) (

∫∫

=

2

) ( ) ( dt t a t s Physical units

  • You want physical motion, you need to use

physical units

Newton kg• m / sec2 pound (lb) s • ft / sec2 Force m / sec2 ft / sec2 Acceleration m / sec ft / sec Velocity Meter (m) foot (ft) Distance kilogram (kg) slug (s) Mass SI (Metric) English Quantity

Physical units

  • Is weight == mass?

– This is actually still being debated – See Link on Web site

  • Our convention (used in Bourg book)

– Mass = amount of matter in a body – Weight = Force resulting in acceleration due to gravity.

  • g = 9.8 m / sec2 or 32 ft / sec2

– Unambiguous in SI units – English units: slug = mass, pound = force

Vectors

  • Note that all quantities mentioned (except

for mass) are vector quantities

– We are, after all, dealing in 3D motion

slide-4
SLIDE 4

Center of Mass

  • Definition

– the location where all of the mass of the system could be considered to be located. – For homogenous solid bodies that have a symmetrical shape, the center of mass is at the center of body's symmetry, its geometrical center.

Initial value problems

  • In order to animate an object, we need to

find p(t), for various values of t, given

– Initial position of object – Initial velocity of object – Initial acceleration of object – Forces applied to object

  • All of the above are vector quantities

Projectile motion

  • Shoot a projectile out of a cannon
  • Cannon is positioned at a given angle
  • No further acceleration except for gravity.

Projectile motion

  • analysis
  • g

acceleration

Recall

m t F t a ) ( ) ( =

= dt t a t v ) ( ) (

= dt t v t s ) ( ) (

∫∫

=

2

) ( ) ( dt t a t s Solving differential equations

  • Means:

– Analytically – Numerically

slide-5
SLIDE 5

Analytic solution

  • For constant acceleration problem

– Acceleration – Velocity – Position

=

x

a g ay − =

φ cos v vx =

gt v dt a v v

y y

− = + =

φ φ sin sin

+ = + = t v x dt v x x

x

) cos ( 0 φ

2

2 1 ) sin ( gt t v y dt v y y

y

− + = + =

φ

Analytic solution

  • We now have equations of motion:

t v x t x ) cos ( ) ( φ + =

2

2 1 ) sin ( ) ( gt t v y t y − + = φ

Analytic solution

  • Let’s see this in action

– Link

Numerical Integration

  • Remember, integration required

– We won’t always be fortunate enough to be able to perform the integration using calculus – Must code different equations for different motions.

  • In animation, numerical integration is usually used

– Full discussion of Numerical Integration techniques next week

  • Quick and dirty hack

– Euler Integration

Leonard Euler

  • 1707-1783
  • Studied:

– Number theory – Differential Equations – Newtonian Physics – Rotational Motion

Numerical Integration

Object properties Position, orientation Linear and angular velocity Linear and angular momentum mass Calculate forces Calculate accelerations Using mass, momenta Update object properties

slide-6
SLIDE 6

Euler Integration

  • Aka Method of Finite Differences
  • Approximates a curve with a series of

straight lines corresponding to curve during a given ∆t

  • Uses tangent on the curve at a given point

to guide the curve to the next point.

Euler Integration

F (ti) F ’ (ti) F (ti+1) = F (ti) + F ‘ (ti)*∆t

Euler Integration

  • Equations

– x (t + ∆t) = x(t) + (v(t) ∆t) – v(t + ∆t) = v(t) + (a(t) ∆t) – x(t + ∆t) = x(t) + ((v(t) + v(t + ∆t) /2) ∆t – x(t + ∆t) = x(t) + v(t) ∆t + ½ a(t) ∆t2

Euler Integration

  • Euler Integration is fast, intuitive, and easy

to code however,

– It is also a very crude approximation to the integral – The smaller the ∆t, the better the solution.

  • Also, the more work that is required.

Euler Integration

  • Questions?
  • Break.

Rigid Body Simulation

Object properties Position, orientation Linear and angular velocity Linear and angular momentum mass Calculate forces Calculate accelerations Using mass, momenta Update object properties

slide-7
SLIDE 7

Force

  • F = ma
  • a = F/m
  • From Force and mass you get acceleration
  • Must consider the Sum of all forces

(including rotational)

Useful forces

  • Gravity
  • Friction
  • Impulse
  • Spring
  • Wind
  • Add your own

Gravity

  • Gravity is an attractive force between all pairs of massive objects

in the universe.

  • The gravitational force between two objects is given by a (fairly)

simple mathematical equation.

  • Where

– m1 and m2 are the masses of the two objects – r is the distance between the two objects – G is the universal gravity constant = 6.67 x 10-11 Nm2 / kg2 2 2 1

r m m G F =

Gravity

  • For objects interacting on this earth, the

acceleration due to gravity can be calculated using the radius of the earth.

– g = 9.8 m / sec2 – g = 32 ft / sec2 – This acceleration is always towards the earth’s surface.

Friction

  • Arises from interaction of surfaces in

contact.

  • Always works against the direction of

relative motion of two objects.

Friction

  • Static Friction

– For objects not in motion – Fraction of the normal component of force – Amount of force need to get object from rest moving

  • Kinetic friction

– For objects in motion – Fraction of the normal component of force – Amount of resistance due to friction

slide-8
SLIDE 8

Supporting object Resting contact Normal force FN F Static friction Fs = us * FN Fs

Static Friction

Supporting object Resting contact Normal force FN v Fk = uk * FN Kinetic friction Fk F

Kinetic Friction Friction

0.08 0.1

Oiled steel on steel

0.03 0.1

Ice on Ice

0.2 0.38

Dry wood on wood

0.04 0.04

Dry Teflon on Teflon

0.42 0.78

Dry steel on steel

0.4 0.55

Dry rubber on pavement

0.15 1.1

Dry iron on iron

0.4 0.94

Dry glass on glass

uk us Surfaces

Impulse

  • Law III:

– For every action there is an equal and

  • pposite reaction.
  • Impulse is the equal and opposite reaction

after a collision

  • More when we talk about collisions

Springs

  • Force applied by stretching a

spring.

  • Given by Hooke’s Law

– restoring force due to a spring is proportional to the length that the spring is stretched – acts in the opposite direction. – F = -kx

Springs

  • Hooke’s Law

– F = -kx – k = spring constant

  • Given in N/m
  • Large k – stronger springs
  • Small k – looser springs
slide-9
SLIDE 9

Springs

  • Damping

– Decreases spring force proportional to velocity

Springs

  • Damping

– Damping specified by damping coefficient, kd – Damping and Springs

      − − = dt dx k kx F

d

Springs

  • Useful for:

– Simulate collections of connected particles or rigid bodies

  • Example: cloth, paper, etc.

– Damping required to make solutions “stable” – Can also be used in collision detection (impulse forces)

Wind

  • Define a force field

– Force varies in space and time – See Wejchert paper in Monday’s myCourses session

Add your own

  • Most difficult part is mathematically

describing the force

  • Physics for game development book has a

bunch

Summary

  • Using physics removes control from

animator

  • Force -> Acceleration -> Velocity ->

Position

  • We are doing numerical integration here.
slide-10
SLIDE 10

Summary

Object properties Position, orientation Linear and angular velocity Linear and angular momentum mass Calculate forces Calculate accelerations Using mass, momenta Update object properties

Next Time

  • Rotational Motion
  • Please get proposals in!

– Will be returned Monday.

  • Questions?