1cs533d-term1-2005 Notes  Typo in test.rib --- fixed on the web now (PointsPolygon --> PointsPolygons)

Slides:



Advertisements
Similar presentations
AP Physics C Mechanics Review.
Advertisements

Review Chap. 8 Momentum, Impulse, and Collisions
Chapter 9. Impulse and Momentum
Momentum Impulse, Linear Momentum, Collisions Linear Momentum Product of mass and linear velocity Symbol is p; units are kgm/s p = mv Vector whose direction.
1Notes. 2Heightfields  Especially good for terrain - just need a 2d array of heights (maybe stored as an image)  Displacement map from a plane  Split.
1cs533d-term Notes  For using Pixie (the renderer) make sure you type “use pixie” first  Assignment 1 questions?
1cs533d-winter-2005 Notes. 2 Numerical Implementation 1  Get candidate x(t+∆t)  Check to see if x(t+∆t) is inside object (interference)  If so Get.
1Notes. 2 Triangle intersection  Many, many ways to do this  Most robust (and one of the fastest) is to do it based on determinants  For vectors a,b,c.
1Notes  Reference  Witkin and Baraff, “Physically Based Modelling” course, SIGGRAPH 2001  Link on the course website.
Conservation of Momentum
1cs533d-winter-2005 Notes  More optional reading on web for collision detection.
1cs533d-winter-2005 Notes  Assignment 2 going okay? Make sure you understand what needs to be done before the weekend  Read Guendelman et al, “Nonconvex.
UNC Chapel Hill S. Redon - M. C. Lin Rigid body dynamics II Solving the dynamics problems.
1cs533d-term Notes  list Even if you’re just auditing!
1cs533d-winter-2005 Notes  Finish up time integration methods today  Assignment 1 is mostly out Later today will make it compile etc.
Chapter 7 Impulse and Momentum.
AP Physics Impulse and Momentum. Which do you think has more momentum?
1cs533d-winter-2005 Notes  Assignment 2 instability - don’t worry about it right now  Please read D. Baraff, “Fast contact force computation for nonpenetrating.
1Notes. 2 Time integration for particles  Back to the ODE problem, either  Accuracy, stability, and ease-of- implementation are main issues  Obviously.
Chapter 4 The Laws of Motion. Forces Usually think of a force as a push or pull Usually think of a force as a push or pull Vector quantity Vector quantity.
Linear Momentum and Collisions
CS 4730 Physical Simulation CS 4730 – Computer Game Design.
Lecture VII Rigid Body Dynamics CS274: Computer Animation and Simulation.
Linear momentum and Collisions
Game Physics – Part I Dan Fleck Coming up: Rigid Body Dynamics.
Momentum and Collisions
Momentum, Impulse, And Collisions
Chapter 7 Linear Momentum. Chapter Momentum Linear Momentum- product of mass times velocity p=mvp=momentum units=kg.m/sec Restate Newton’s second.
Chapter 6 Momentum and Collisions. Chapter Objectives Define linear momentum Compare the momentum of different objects Describe impulse Conservation of.
Force and Momentum Chapter 1. Reminders from GCSE Momentum is a measure of how easy or difficult it is to change the motion of a body –The greater the.
_ Linear momentum and its conservation _ Impulse and momentum _ Collisions _ Two-dimensional collisions _ Center of mass _ Systems of particles. Momentum.
Momentum Chapter 6. Momentum ► Related to inertia, not the same. ► Symbol is p ► p=mv ► Units of kgm/s ► What is the momentum of a 75kg rock rolling at.
Momentum and Its Conservation
1 PPMF102– Lecture 3 Linear Momentum. 2 Linear momentum (p) Linear momentum = mass x velocity Linear momentum = mass x velocity p = mv p = mv SI unit:
REVISION MOMENTUM. the product of an object's mass and its velocity a vector quantity with the same direction as the velocity of the object. MOMENTUM.
Chapter 7 Linear Momentum. MFMcGraw-PHY 1401Chap07b- Linear Momentum: Revised 6/28/ Linear Momentum Definition of Momentum Impulse Conservation.
Chapter 4 The Laws of Motion. Classes of Forces Contact forces involve physical contact between two objects Field forces act through empty space No physical.
1 st Semester Exam Review. Math and Metrics Sig Fig Rules: 505 – zero is significant 500 – zeroes not significant 0.05 – zeroes not significant 5.00 –
Linear Momentum Impulse & Collisions. What is momentum?  Momentum is a measure of how hard it is to stop or turn a moving object.  What characteristics.
M o m e n t u m Momentum is… Inertia in motion Mass x Velocity.
Momentum, impulse, and collisions Chapter 8 Sections 1-5.
The Laws of Motion. Classical Mechanics Describes the relationship between the motion of objects in our everyday world and the forces acting on them Describes.
Chapter 4 The Laws of Motion. Classical Mechanics Describes the relationship between the motion of objects in our everyday world and the forces acting.
Momentum and Collisions Linear Momentum The linear momentum of a particle or an object that can be modeled as a particle of mass m moving with a velocity.
Momentum.
Linear Momentum. Linear momentum describes motion in which the center of mass of an object or system changes position. We call motion where the c.o.m.
Chapter 5 Two Dimensional Forces Equilibrium An object either at rest or moving with a constant velocity is said to be in equilibrium The net force acting.
Ch 8 : Conservation of Linear Momentum 1.Linear momentum and conservation 2.Kinetic Energy 3.Collision 1 dim inelastic and elastic nut for 2 dim only inellastic.
Recoil and Collisions 8.01 W07D1
Physics - Harmonic Motion We have been dealing with straight line motion or motion that is circular. There are other types of motion that must be dealt.
Work Readings: Chapter 11.
Chapter 5 The Laws of Motion.
CS274 Spring 01 Lecture 7 Copyright © Mark Meyer Lecture VII Rigid Body Dynamics CS274: Computer Animation and Simulation.
A Review of Some Newtonian Mechanics Gernot Laicher REFUGES Summer Bridge Course 2014.
Sect. 9.2: Impulse & Momentum
PHY 101: Lecture The Impulse-Momentum Theorem 7.2 The Principle of Conservation of Linear Momentum 7.3 Collision in One Dimension 7.4 Collisions.
1 Chapter 5 The Laws of Motion. 2 Force Forces are what cause any change in the velocity of an object A force is that which causes an acceleration The.
PHY 151: Lecture Motion of an Object attached to a Spring 12.2 Particle in Simple Harmonic Motion 12.3 Energy of the Simple Harmonic Oscillator.
Chapter 9:Linear Momentum
Momentum, Impulses, and Collisions. A. Background Information 1.Momentum of an object is anything that has inertia and is moving a. It is based on an.
Center of Mass and Linear Momentum
a) More on Elastic Collisions
Sect. 9.2: Impulse & Momentum
Momentum Physics.
Momentum and Collision
Impulse-Momentum Principle
ENGINEERING MECHANICS
SCI 340 L21 conservation of momentum
Sect. 9.2: Impulse & Momentum
Impulse and Momentum Chapter 7.
Presentation transcript:

1cs533d-term Notes  Typo in test.rib --- fixed on the web now (PointsPolygon --> PointsPolygons)

2cs533d-term Contact Friction  Some normal force is keeping v N =0  Coulomb’s law (“dry” friction) If sliding, then kinetic friction: If static (v T =0) then stay static as long as  “Wet” friction = damping

3cs533d-term Collision Friction  Impulse assumption: Collision takes place over a very small time interval (with very large forces) Assume forces don’t vary significantly over that interval---then can replace forces in friction laws with impulses This is a little controversial, and for articulated rigid bodies can be demonstrably false, but nevertheless… Normal impulse is just m∆v N =m(1+  )v N Tangential impulse is m∆v T

4cs533d-term  So replacing force with impulse:  Divide through by m, use  Clearly could have monotonicity/stability issue  Fix by capping at v T =0, or better approximation for time interval e.g. Wet Collision Friction

5cs533d-term Dry Collision Friction  Coulomb friction: assume  s =  k (though in general,  s ≥  k )  Sliding:  Static:  Divide through by m to find change in tangential velocity

6cs533d-term Simplifying…  Use  Static case is when  Sliding case is  Common quantities!

7cs533d-term Dry Collision Friction Formula  Combine into a max First case is static where v T drops to zero if inequality is obeyed Second case is sliding, where v T reduced in magnitude (but doesn’t change signed direction)

8cs533d-term Where are we?  So we now have a simplified physics model for Frictionless, dry friction, and wet friction collision Some idea of what contact is  So now let’s start on numerical methods to simulate this

9cs533d-term “Exact” Collisions  For very simple systems (linear or maybe parabolic trajectories, polygonal objects) Find exact collision time (solve equations) Advance particle to collision time Apply formula to change velocity (usually dry friction, unless there is lubricant) Keep advancing particle until end of frame or next collision  Can extend to more general cases with conservative ETA’s, or root-finding techniques  Expensive for lots of coupled particles!

10cs533d-term Fixed collision time stepping  Even “exact” collisions are not so accurate in general [hit or miss example]  So instead fix ∆t collision and don’t worry about exact collision times Could be one frame, or 1/8th of a frame, or …  Instead just need to know did a collision happen during ∆t collision If so, process it with formulas

11cs533d-term Relationship with regular time integration  Forgetting collisions, advance from x(t) to x(t+∆t collision ) Could use just one time step, or subdivide into lots of small time steps  We approximate velocity (for collision processing) as constant over time step:  If no collisions, just keep going with underlying integration

12cs533d-term Numerical Implementation 1  Get candidate x(t+∆t)  Check to see if x(t+∆t) is inside object (interference)  If so Get normal n at t+∆t Get new velocity v from collision response formulas applied to average v=(x(t+∆t)-x(t))/∆t Integrate x(t+∆t)=x(t+∆t) old +∆t∆v

13cs533d-term Robustness?  If a particle penetrates an object at end of candidate time step, we fix that  But new position (after collision processing) could penetrate another object!  Maybe this is fine-let it go until next time step  But then collision formulas are on shaky ground…  Switch to repulsion impulse if x(t) and x(t+∆t) both penetrate Find ∆v N proportional to final penetration depth, apply friction as usual

14cs533d-term Making it more robust  Other alternative: After collision, check if new x(t+∆t) also penetrates If so, assume a 2nd collision happened during the time step: process that one Check again, repeat until no penetration To avoid infinite loop make sure you lose kinetic energy (don’t take perfectly elastic bounces, at least not after first time through) Let’s write that down:

15cs533d-term Numerical Implementation 2  Get candidate x(t+∆t)  While x(t+∆t) is inside object (interference) Get normal n at t+∆t Get new velocity v from collision response formulas and average v Integrate collision: x(t+∆t)=x(t+∆t) old +∆t∆v  Now can guarantee that if we start outside objects, we end up outside objects

16cs533d-term Micro-Collisions  These are “micro-collision” algorithms  Contact is modeled as a sequence of small collisions We’re replacing a continuous contact force with a sequence of collision impulses  Is this a good idea? [block on incline example]  More philosophical question: how can contact possibly begin without fully inelastic collision?

17cs533d-term Improving Micro-Collisions  Really need to treat contact and collision differently, even if we use the same friction formulas  Idea: Collision occurs at start of time step Contact occurs during whole duration of time step

18cs533d-term Numerical Implementation 3  Start at x(t) with velocity v(t), get candidate position x(t+∆t)  Check if x(t+∆t) penetrates object If so, process elastic collision using v(t) from start of step, not average velocity Replay from x(t) with modified v(t) or simply add ∆t∆v to x(t+∆t) instead of re-integrating Repeat check a few (e.g. 3) times if you want  While x(t+∆t) penetrates object Process inelastic contact (  =0) using average v Integrate +∆t ∆v

19cs533d-term Why does this work?  If object resting on plane y=0, v(t)=0 though gravity will pull it down by the end of the timestep, t+∆t  In the new algorithm, elastic bounce works with pre-gravity velocity v(t)=0 So no bounce  Then contact, which is inelastic, simply adds just enough ∆v to get back to v(t+∆t)=0 Then x(t+∆t)=0 too  NOTE: if  =0 anyways, no point in doing special first step - this algorithm is equivalent to the previous one

20cs533d-term Moving objects  Same algorithms, and almost same formulas: Need to look at relative velocity v particle -v object instead of just particle velocity As before, decompose into normal and tangential parts, process the collision, and reassemble a relative velocity Add object velocity to relative velocity to get final particle velocity  Be careful when particles collide: Same relative ∆v but account for equal and opposite forces/impulses with different masses…

21cs533d-term Moving Objects…  Also, be careful with interference/collision detection Want to check for interference at end of time step, so use object positions there Objects moving during time step mean more complicated trajectory intersection for collisions

22cs533d-term Collision Detection  We have basic time integration for particles in place now  Assumed we could just do interference detection, but…  Detecting collisions over particle trajectories can be dropped in for more robustness - algorithms don’t change But use the normal at the collision time