Lei Wang

Department of Computer Science

The Ohio State University


 

Topic

My project is simulating fluid with free surfaces by Smoothed Particle Hydrodynamics (SPH). The basic technology is based on Particle-Based Fluid Simulation for Interactive Applications by Müller, Charypar and Gross [4].

Introduction

Fluids are ubiquitous in our daily life. From the water we drink to the air we breath, everything can continually deform is called fluid. They are also the matters make ocean wave and tornado. Due to their widely existence in our life and their roles in natural phenomena, fluid simulation plays an important part in computer graphics.

Fluid simulation is challenging. Existing simulation approaches can be categoried as grid-based (Eulerian) methods, particle-based (Lagrangian) methods and hybrid methods. As its name suggests, SPH is a particle-based method.

This is the video of Particle-Based Fluid Simulation for Interactive Applications

SPH - flood rendered from Thiago Costa on Vimeo.

GPU-based SPH using CUDA, by oysteinkrog

Video of An Architecture for Unified SPH Simulations

The term SPH is coined by Lucy [1], Gingold and Monaghan [2] to simulate astronomic phenomena. For a SPH based particle system, scalar quantities are defined on particle locations only and evaluated anywhere else. Stam and Fiume [3] first used SPH to simulate fire and gas. Müller, Charypar and Gross [4] developed a SPH method which can be applied on real-time fluid simulation. From now on, SPH will be used solely for the method proposed by [4].

Algorithm

By SPH, a scalar quantity is evaluated by weighted sum from the quantity of near by particles.

Adams and Wicke give a detailed description of SPH in their tutorial [5]. Following figure shows the algorithm of SPH.

From the algorithm we can see the evaluation of quantities can be parallelized.

Objective

  • Implement SPH introduced by [4]
  • Speed up SPH using CUDA
  • Extract the free surface using Marthcing Cubes and render it
  • Design some good scenes

Timeline

09/21 - 10/12 Literature review. Done!

10/13 - 10/24 Implement SPH. Done!

10/25 - 11/14 Accelerate SPH using CUDA. Done! (CUDA version is at least 20 times faster than the CPU version)

11/15 - 11/30 Surface extraction, design test scenes. Done! (I turned to the implicit representation of the surface. I think it looks better and it is easier to be rendered)

Resources

  • Slides of my proposal
  • The source code of a CPU based SPH is here. This is the GPU based SPH.

Results

A video clip of wave. It was simulated with 10,000 particles and rendered by pbrt with implicit surface plug in by Bridson.

A video clip of dambreak. It was simulated with 8,000 particles and rendered by the same technique.

Acknowledgement

Reference

[1] R. A. Gingold and J. J. Monaghan.Smoothed particle hydrodynamics: theory and application to non-spherical stars, in Monthly Notices of the Royal Astronomical Society, 181:375– 398, 1977.

[2] L. B. Lucy. A numerical approach to the testing of the fission hypothesis, in The Astronomical Journal, 82:1013–1024, 1977.

[3] Jos Stam and Eugene Fiume. Depicting fire and other gaseous phenomena using diffusion processes, in Computer Graphics, 29 (Annual Conference Series):129–136, 1995.

[4] Matthias Müller, David Charypar and Markus Gross. Particle-Based Fluid Simulation for Interactive Applications, in SCA 2003.

[5] Bart Adams and Martin Wicke, Meshless Approximation Methods and Applications in Physics Based Modeling and Animation, in Eurographics 2009.