Presentation is loading. Please wait.

Presentation is loading. Please wait.

Numerical integration for physically based animation

Similar presentations


Presentation on theme: "Numerical integration for physically based animation"— Presentation transcript:

1 Numerical integration for physically based animation
CSE 3541 / 5541 Matt Boggus

2 Recording motion First, save a moving object’s position over time. Then, given time, look up position ; y = f(time) Plot roughly based on dropping a non very bouncy ball

3 Sampling A fixed amount of time passes between frames,
approximate the continuous position curve with discrete samples.

4 Sampling Low sampling rate (large dt)

5 Sampling High sampling rate (smaller dt)

6 Kinematics terms Position (x,y,z) Velocity (x,y,z)
Point with respect to the origin Velocity (x,y,z) Speed (vector magnitude) Direction Acceleration (x,y,z) Rate of change of velocity Magnitude and direction r Kinematics - the branch of mechanics concerned with the motion of objects without reference to the forces that cause the motion.

7 Problem statement Compute an unknown function f(time), using its known derivative f’(time) Known current position and velocity i.e. values at start of Update() Unknown “next” position and velocity i.e. what should values be at end of Update() Known forces acting on object Integrate to compute “next” velocity and position

8 Example Initial conditions:
acceleration Initial conditions: p = 0, v = 5 If we have the function for acceleration, we can integrate it and use initial conditions to solve for the velocity and position functions velocity position

9 Step in the direction of the derivative
Euler integration For arbitrary function f (ti) with known derivative Also draw locations of new point if doubling dt or negating dt Euler pronunciation: like “oiler” Step in the direction of the derivative

10 Example of inaccuracy during integration
For arbitrary function, f(t) Ex: wind, springs The force acting on a point may vary in space, i.e in most cases

11 Integration and step size
Here x is the same thing as time or t in the previous slides

12 Inaccuracy and instability

13 Runge Kutta Integration: 2nd order aka Midpoint Method
Compute a “full” Euler step Evaluate f’ at midpoint Take a step from the original point using the midpoint f’ value

14 Runge Kutta Integration: 2nd order
aka Midpoint Method For unknown function, f(t); known f ’(t)

15 Step size Euler Integration Midpoint Method

16 Integration comparison
Image from

17 Integration comparison
Image based on

18 Integration comparison
Image based on

19 Additional slides

20 Other integration techniques
Implicit Euler Huen Verlat Leapfrog

21 OSU CSE course: Numerical Methods
5361 541 (from quarter system)

22 List of 5361/541 topics Mathematical Preliminaries: Derivatives, Taylor Series Representation of Numbers: Accuracy, Precision Root Finding Polynomial Interpolation Numerical Differentiation Numerical Integration Random Numbers and Monte-Carlo Techniques Linear Systems and Gaussian Elimination


Download ppt "Numerical integration for physically based animation"

Similar presentations


Ads by Google