1 / 43

Simulation and Animation

Simulation and Animation. Rigid Body Simulation. The next few lectures …. Comming up …. Dynamic simulation . Movement of point masses, rigid bodies, systems of point masses etc. with respect to Forces Body charcteristics (mass, shape)

poppy
Download Presentation

Simulation and Animation

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Simulation and Animation Rigid Body Simulation

  2. The nextfewlectures…

  3. Commingup…

  4. Dynamic simulation • Movement of point masses, rigid bodies, systems of point masses etc. with respect to • Forces • Body charcteristics (mass, shape) • Derivation of accelerations from properties and physical laws • Dynamic of point masses • Dynamic of rigid bodies

  5. Dynamic simulation • Newtons Axioms • Withoutexternalforces, a bodymovesuniformly (Inertia) • An externalforceFappliedto amassmresults in an accelerationa:F = ma • Actio= reactio

  6. Now…

  7. Point dynamics • Dynamic simulationofparticles • Position r, massm, velocityv,accelerationa, but noextend • ForcesF acton particles F,a,v,rare 3D vectors!!!

  8. Point dynamics • Dynamic simulationofparticles • Multiple forcesmayacton particles • Forcesareaddedbyvectoraddition • F isusually a functionof time • Massmightchangeas well • Change ofmomentum(Impuls) withchangeof time

  9. Point dynamics • Particleshavenointernalstructure • 3 DOF = degreesoffreedom (positiononly) • Directkinematic: froma  v  r • Indirectkinematic: fromrandboundaryconditions v  a

  10. Point dynamics • Relation betweenforceFandaccelerationa • Directdynamics Point mass

  11. Point dynamics • ImportantForces • Gravity • Hooke's Law • Friction

  12. Point dynamics • Linear momentum(Impuls) • Force F act on centerofmass • Force • Conservationofmomentum • Example: elastic push

  13. Point dynamics • Angular momentum (Drall) • Torque(Drehmoment) • Conservationof angular momentum p r Moment of inertia: I = mr2

  14. Point dynamics • Angular velocityof a point (rate atwhichthepointisrotating): magnitudeofchange • Notation:

  15. Point dynamics • Analog forrotationmatrixR - itchangesunder angular velocity • Aggregate movementof a bodypoint • (r0/r(t): position in local/worldspacecoordinatesystem)

  16. Point dynamics • Relation between angular momentumandangular velocity • InertiatensorI (Trägheitstensor) Example:Skater Symmetrictensor

  17. Point dynamics Summary

  18. Next…

  19. Rigid body simulation • Idea • Combinationofmanysmallparticlesto a rigid body • Bodiesthat do not deform – theyarestiff • They do not penetrate • Theybounce back iftheycollide • Rigid convexpolyhedraofconstantdensity • 6 DOF insteadof 3n DOF (fornparticles) • Distinguishbetween • Movement ofcenterofmass(CM) • Rotation around(CM)

  20. Volume integral overentire body Massdensity (= specificweight = Mass/Volume) Rigid body simulation • MassMin continuouscase small, discrete mass points

  21. Rigid body simulation • CM (centerofmass)in continuouscase

  22. Rigid bodysimulation • Dynamic simulationof rigid bodies • Motion consistoftranslationaland angular component • Velocity v(t) is rate ofchangeofpositionr(t) over time • v(t) = r´(t) • v(t) is linear velocityatcenterofmass • Bodies also have a spin • About an axis (vector) throughthecenterofmass • Magnitude ofthevectordefineshow fast thebodyisspinning

  23. Rigid body simulation • Translation and Rotation: • Rotation R: • 3*3 Matrix • Redundancies • only 3 DOF local/fixedcoordinate system CM

  24. Rigid body simulation Rotation Translation

  25. Rigid body simulation • Momentum • Movement of CM • Force Fextissumof all externalforces Fext,i Fext R

  26. Rigid body simulation • Angular momentum • InertiatensorI

  27. Rigid body simulation • Angular momentum • InertiatensorI in continuouscase x,y,z coordinates Kronecker-symbol

  28. Rigid bodysimulation • Translation vs. Rotation MassInertiaMoment (Trägheitsmoment) m Velocity Angular Velocity v =dr/dt = d/dt Momentum Angular Momentum p = mv L = I = r x p Force Torque F = dp/dt T = r x F = dL/dt KinetcEnergyKineticEnergy E = ½ mv2 E = ½ I2

  29. Rigid body simulation • Properties oftheInertiatensor • Diagonal elementsaremomentsofinertiawithrespecttocoordinateaxes • Itissymmetricand real • Hasthreeprincipalaxis (eigenvectors) • Eigenvectorsare orthogonal: directionsofinertia (Hauptträgheitsachsen) • Eigenvalues are real: momentsofinertia (Hauptträgheitsmomente)

  30. Rigid body simulation • Inertiatensor • In this (directionsofinertia) coordinatesystem, I canbediagonalizedby RIRT, where R is a rotationmatrix: • Inertiamoment (scalar) forrotationaroundaxisn (normalized)

  31. Rigid body simulation • Torqueofsingle „bodyelement“ • Total torque • Important: startingpointofforce • Equationsofmotionforrotation(Euler equationsforfixedcoordinatesystem)

  32. Rigid body simulation • State vectorof a rigid body • Constants: • InertiatensorIKS • MassM Position Orientation (rotation matrix) Impuls Angular momentum

  33. Rigid body simulation • Derived variables

  34. Rigid body simulation • Equations of motion

  35. Rigid body simulation • System ofordinary partial differential equations • Initial boundaryproblem • Structure • In general, numericsolution (Integration) • Explicit solve: Euler, Runge-Kutta • Implicitsolver

  36. Numerical Integration • Initial value problem: • Simple approach: Euler • Derivation: Taylor expansion • First order scheme • Higher accuracy with smaller step size

  37. Numerical Integration • Problems of Euler-Scheme • Inaccurate • Unstable • Example: Divergenz für t> 2/k

  38. Numerical Integration • Midpoint method:1. Euler-Step2. Evaluation of f at midpoint3. Step with value at midpoint • Second order scheme

  39. Numerical Integration • Fourth order Runge-Kutta • Adaptive step size control

  40. Numerical Integration • So far: Explicit techniques • Stableintegrationbymeansofimplicitintegrationschemes • Implicit Euler-Step • „rewind“ the explicit Euler-Step • Taylor-expansionaroundt + tinsteadoft • Solvingthe non-linear systemofequationsforx(t + t)

  41. Rigid body simulation

  42. Rigid body simulation • Demo

  43. Rigid body simulation • Summary Translation Rotation Position rCM Orientation R Velocity vCM Angular velocity  Impuls pCM Angular moment L Forces Fext Torque T Mass M Inertia tensor 

More Related