Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Fluid Simulation and Control for
      Computer Graphics




        Michael Bang Nielsen
         Aarhus University
What is Computer Graphics?
• Modeling
  – Geometry
  – Appearance
• Animation
  – Keyframes
  – Motion Capture
  – Simulat...
What is Physically Based
                  Animation?
 •   Rigid bodies
 •   Deformable objects
 •   Cloth
 •   Hair
 •   ...
Why Computer Generated Effects
 for Movies and Commercials?




Real world smoke and water phenomena are very complex
Why Computer Generated Effects
 for Movies and Commercials?




         Ivan Aivazovsky, ”The Ninth Wave”, 1850.

 It req...
Why Computer Generated Effects
 for Movies and Commercials?




                                 From Rikitt: Special Effe...
Why Computer Generated Effects
 for Movies and Commercials?




     From Rikitt: Special Effects
And real phenomena have ...
Why Computer Generated Effects
  for Movies and Commercials?




Copyright Cinefex.

But sometimes physical effects work.
State of the Art in Fluid Simulation
       for Computer Graphics

1: http://www.scanlinevfxla.com/la/en/reels.html
2: Seq...
State of the Art in Fluid Simulation
          for Computer Graphics
                      Sequence from Day After Tomorro...
How do we Simulate Fluids for
   Computer Graphics?




      From John D. Anderson: Computational Fluid Dynamics


Math, ...
Fluid Simulation for Computer
             Graphics
 Demands are different than in CFD:
• Should be
  visually plausible
•...
Fluid Simulation for Computer
             Graphics
• Simulation speed –
  deadlines and
  interactive preview
• The fluid...
Guided Fluid Simulation
  Collaboration between

  •   Michael Bang Nielsen
  •   Brian Bunch Christensen
  •   Nafees Bin...
Guided Fluid Simulation
       Motivation
                            Our Contribution:
       Coarse Simulation   Guided ...
Guided Fluid Simulation
             Motivation




High Res      Low Res     Low Res Upsampled
Guided Fluid Simulation
          Problem Statement
                Develop
• Mathematical model
• Algorithms
• Data struc...
Guided Fluid Simulation
       The Fundamental Idea


      The low frequencies of the fine
     simulation should be equa...
The One-Slide Fluid Mechanics
           Course
Net force = mass x acceleration
F = ma ⇒    F
           Vol
             ...
The One-Slide Computational Fluid
       Mechanics Course
In computer graphics we apply Operator Splitting:


            ...
Guided Fluid Simulation
 How do we attack the problem?
           Advection


           Body forces


         Incompress...
Guided Fluid Simulation
        The Force-Based Approach
• Forces (all or low frequencies)




    Thuerey et al.
• Blendi...
Guided Fluid Simulation
 How do we attack the problem?
           Advection


           Body forces


         Incompress...
Guided Fluid Simulation
 The Modified Pressure Projection
            Approach
Observation
Solving for Incompressibility

...
Guided Fluid Simulation
The Modified Pressure Projection
           Approach
We add the constraint



to the minimization ...
Guided Fluid Simulation
   The Modified Pressure Projection
              Approach

Calculus of variations leads to the eq...
Guided Fluid Simulation
 The Modified Pressure Projection
            Approach




           Test-simulations in Matlab
P...
Guided Fluid Simulation
The Modified Pressure Projection
           Approach

Fundamental question:

Does our approach fai...
Guided Fluid Simulation
    The Modified Pressure Projection
          Second Approach


     The low frequencies of the f...
Guided Fluid Simulation
The Modified Pressure Projection
      Second Approach
We add the minimization term



to the mini...
Guided Fluid Simulation
   The Modified Pressure Projection
         Second Approach

Calculus of variations leads to the ...
Guided Fluid Simulation
The Modified Pressure Projection
      Second Approach
          Verification in 2D
Guided Fluid Simulation
      The Modified Pressure Projection
            Second Approach




Fast to solve, but 1602 req...
Guided Fluid Simulation
    The Modified Pressure Projection
          Second Approach




Computational challenges:
• Spa...
Guided Fluid Simulation
   The Modified Pressure Projection
         Second Approach
  More computational challenges:

• B...
Results
Interpolation between strictly guided and unguided simulation




  Low res        High Res
Links to More Information


• http://cs.au.dk/research/areas/computer-
  graphics-and-scientific-computing/

• http://cg.a...
Fluid Simulation and Control for Computer Graphics
Upcoming SlideShare
Loading in …5
×

Fluid Simulation and Control for Computer Graphics

4,346 views

Published on

Physically accurate computer simulations of fluids such as water, gasses and air have for many years been a valuable complement to experimental methods in examining the flow around airplanes, cars, wind turbines etc. Recently physically based simulation of fluids has also been adopted in computer graphics, where such techniques are required to faithfully reproduce the visually complex motion of fluids that is very hard to animate in a traditional sense. However, the demands are different in graphics where the visual properties of the fluid have to impose character on the fluid in addition to adhering to the vision of an artist or a director. This poses entirely new research challenges for fluid simulation in computer graphics where artistic control, low simulation cost and visual richness are in focus. In this presentation I will motivate the use of physically based fluid simulation for computer graphics, show examples of state of the art and go into more depth with a recent fluid control framework developed at Aarhus University in collaboration with DreamWorks Animation and Digital Domain. I will elaborate both on the final technique and results as well as on the process that took us there, including challenges faced and approaches that turned out not to be successful.

Published in: Education, Technology
  • Be the first to comment

Fluid Simulation and Control for Computer Graphics

  1. 1. Fluid Simulation and Control for Computer Graphics Michael Bang Nielsen Aarhus University
  2. 2. What is Computer Graphics? • Modeling – Geometry – Appearance • Animation – Keyframes – Motion Capture – Simulation/Synthesis • Rendering – Offline – Realtime
  3. 3. What is Physically Based Animation? • Rigid bodies • Deformable objects • Cloth • Hair • Fluids – Water – Smoke – Fire – Air Important for games, but what about movies and commercials?
  4. 4. Why Computer Generated Effects for Movies and Commercials? Real world smoke and water phenomena are very complex
  5. 5. Why Computer Generated Effects for Movies and Commercials? Ivan Aivazovsky, ”The Ninth Wave”, 1850. It requires remarkable talent and a lot of time to do..
  6. 6. Why Computer Generated Effects for Movies and Commercials? From Rikitt: Special Effects And real phenomena have scale…
  7. 7. Why Computer Generated Effects for Movies and Commercials? From Rikitt: Special Effects And real phenomena have scale…
  8. 8. Why Computer Generated Effects for Movies and Commercials? Copyright Cinefex. But sometimes physical effects work.
  9. 9. State of the Art in Fluid Simulation for Computer Graphics 1: http://www.scanlinevfxla.com/la/en/reels.html 2: Sequence from Golden Compass Molemaker et al.
  10. 10. State of the Art in Fluid Simulation for Computer Graphics Sequence from Day After Tomorrow: Copyright Twentieth Century Fox. But don’t be fooled: Artists spend a lot of time making raw simulations look good
  11. 11. How do we Simulate Fluids for Computer Graphics? From John D. Anderson: Computational Fluid Dynamics Math, Physics, Computer Science, Fluid Dynamics and Computational Fluid Dynamics (CFD)
  12. 12. Fluid Simulation for Computer Graphics Demands are different than in CFD: • Should be visually plausible • Physical accuracy not paramount • Animators/director want a certain visual style
  13. 13. Fluid Simulation for Computer Graphics • Simulation speed – deadlines and interactive preview • The fluid should have character Production designs by Jon Brooks • The artists want control – it should be possible to sculpt the fluid From Inkheart. Image by Double Negative
  14. 14. Guided Fluid Simulation Collaboration between • Michael Bang Nielsen • Brian Bunch Christensen • Nafees Bin Zafar • Doug Roble • Ken Museth I will share both our successes and frustrations with you!
  15. 15. Guided Fluid Simulation Motivation Our Contribution: Coarse Simulation Guided Fine Simulation Fine Simulation
  16. 16. Guided Fluid Simulation Motivation High Res Low Res Low Res Upsampled
  17. 17. Guided Fluid Simulation Problem Statement Develop • Mathematical model • Algorithms • Data structures That make it possible to guide a high resolution fluid simulation using a low resolution simulation
  18. 18. Guided Fluid Simulation The Fundamental Idea The low frequencies of the fine simulation should be equal to the frequencies of the coarse simulation Challenge: Formulate this mathematically
  19. 19. The One-Slide Fluid Mechanics Course Net force = mass x acceleration F = ma ⇒ F Vol =a m Vol ⇒ 1 F ρ Vol =a
  20. 20. The One-Slide Computational Fluid Mechanics Course In computer graphics we apply Operator Splitting: Advection Body forces Incompressibility
  21. 21. Guided Fluid Simulation How do we attack the problem? Advection Body forces Incompressibility The low frequencies of the fine simulation should be equal to the frequencies of the coarse simulation
  22. 22. Guided Fluid Simulation The Force-Based Approach • Forces (all or low frequencies) Thuerey et al. • Blending of divergence free velocity fields – Leads to results that are too smooth
  23. 23. Guided Fluid Simulation How do we attack the problem? Advection Body forces Incompressibility The low frequencies of the fine simulation should be equal to the frequencies of the coarse simulation
  24. 24. Guided Fluid Simulation The Modified Pressure Projection Approach Observation Solving for Incompressibility is identical to the minimization of subject to the constraint
  25. 25. Guided Fluid Simulation The Modified Pressure Projection Approach We add the constraint to the minimization of subject to the constraint
  26. 26. Guided Fluid Simulation The Modified Pressure Projection Approach Calculus of variations leads to the equations Does it work?
  27. 27. Guided Fluid Simulation The Modified Pressure Projection Approach Test-simulations in Matlab Problems: • Matrix singular when filter is wide • Where should we place the constraints?
  28. 28. Guided Fluid Simulation The Modified Pressure Projection Approach Fundamental question: Does our approach fail completely, or can we modify it somehow?
  29. 29. Guided Fluid Simulation The Modified Pressure Projection Second Approach The low frequencies of the fine simulation should be as close as possible to the frequencies of the coarse simulation Challenge: Formulate this mathematically
  30. 30. Guided Fluid Simulation The Modified Pressure Projection Second Approach We add the minimization term to the minimization of subject to the constraint
  31. 31. Guided Fluid Simulation The Modified Pressure Projection Second Approach Calculus of variations leads to the equations Does it work?
  32. 32. Guided Fluid Simulation The Modified Pressure Projection Second Approach Verification in 2D
  33. 33. Guided Fluid Simulation The Modified Pressure Projection Second Approach Fast to solve, but 1602 requires roughly 2GB and we want to do it in 2563…
  34. 34. Guided Fluid Simulation The Modified Pressure Projection Second Approach Computational challenges: • Sparse entries take up 4.04TB in resolution 2563 • We reduced this to 208MB • Linear system is a-symmetric • Solution: Improved multigrid solver • Linear system is slow to solve • Solution: Parallel solver using separable lowpass filters
  35. 35. Guided Fluid Simulation The Modified Pressure Projection Second Approach More computational challenges: • Boundaries traditionally hard to use with multigrid • Which lowpass filter should be used? • How do we handle non-physically based guiding velocity fields?
  36. 36. Results Interpolation between strictly guided and unguided simulation Low res High Res
  37. 37. Links to More Information • http://cs.au.dk/research/areas/computer- graphics-and-scientific-computing/ • http://cg.alexandra.dk/2009/05/15/smoke- rendering-demo/

×