Fluid Simulation for Fluid Simulation for GraphicsGraphics
Minor project under guidance of Prof. P. Minor project under guidance of Prof. P. KalraKalra
Abhinav GolasAbhinav GolasAkram KhanAkram Khan
OutlineOutline• Fluid animationFluid animation
– What it isWhat it is– What it is notWhat it is not– UsesUses– ModelsModels
• Work doneWork done– Work done earlierWork done earlier– Current focusCurrent focus– Future workFuture work
Fluid animationFluid animation• Modeling and Rendering fluids in a Modeling and Rendering fluids in a
manner which is visually appealingmanner which is visually appealing• NOT a numerically complete NOT a numerically complete
simulationsimulation• Model is scenario dependent – Model is scenario dependent –
computationally expensivecomputationally expensive
UsesUses• Movies! – Titanic, Ice Age, LOTR etc.Movies! – Titanic, Ice Age, LOTR etc.• Games! – All!Games! – All!
The Navier Stokes EquationThe Navier Stokes Equation• Governs all fluid behaviourGoverns all fluid behaviour• PDE – no closed formPDE – no closed form• Solutions only through numerical Solutions only through numerical
simulationsimulation• Issues of numerical errors, and stabilityIssues of numerical errors, and stability• Computationally Computationally veryvery expensive expensive• Boundary conditions and level of Boundary conditions and level of
discretisation importantdiscretisation important
ModelsModels• Heightfield generationHeightfield generation
– For showing ocean surfacesFor showing ocean surfaces– Used when field of view is largeUsed when field of view is large– Doesn’t directly solve Navier Stokes – uses Doesn’t directly solve Navier Stokes – uses
generalised solutionsgeneralised solutions• CFD – Computational Fluid DynamicsCFD – Computational Fluid Dynamics
– Iteratively solve NS eqns for a 3D gridIteratively solve NS eqns for a 3D grid– Surface reconstruction – recent workSurface reconstruction – recent work– Fixed grid positions – Eulerian approachFixed grid positions – Eulerian approach
ModelsModels• Smoothed Particle HydrodynamicsSmoothed Particle Hydrodynamics
– System as collection of fluid particlesSystem as collection of fluid particles– Governed by NS eqnsGoverned by NS eqns– Surface reconstructionSurface reconstruction
Surface reconstructionSurface reconstruction• Problem:Problem:
– Given a set of particles, need to Given a set of particles, need to generate a smooth wrapping surfacegenerate a smooth wrapping surface
• Approach (currently used)Approach (currently used)– Level setsLevel sets– Hybrid approach (level sets + curvature Hybrid approach (level sets + curvature
measures)measures)
Work done earlierWork done earlier• Literature review to find current Literature review to find current
state-of-the-artstate-of-the-art• Issues in simulation of different types Issues in simulation of different types
of fluids:of fluids:– ViscousViscous– SnowSnow– FireFire
Current focusCurrent focus• Getting implementations of the state-of-Getting implementations of the state-of-
the-art methodsthe-art methods– HeightfieldsHeightfields– CFDCFD– SPHSPH
• ReferencesReferences– SIGGRAPH 2004 course on realistic nature SIGGRAPH 2004 course on realistic nature
animationanimation– SIGGRAPH 2006 course on fluid simulationSIGGRAPH 2006 course on fluid simulation
ProgressProgress• Some heightfields implementedSome heightfields implemented
– Gerstner waves (video on site)Gerstner waves (video on site)– Statistics based ocean wavesStatistics based ocean waves– Velocity field based animationVelocity field based animation– Choppy waves (currently underway)Choppy waves (currently underway)
• Work on CFDWork on CFD– Making an implementationMaking an implementation
Some resultsSome results
Some resultsSome results
Future workFuture work• Complete implementations of these Complete implementations of these
fluid simulation methodsfluid simulation methods• Identify areas for further Identify areas for further
improvement/researchimprovement/research– Spray/FoamSpray/Foam– BubblesBubbles