Fluid Simulation in Bases of Laplacian Eigenfunctions

Tyler de Witt
M. Sc. Thesis, 2010
Department of Computer Science
University of Toronto
Full Text PDF Bibtex


We present a novel method for the simulation of incompressible fluids. In contrast to existing grid based and particle methods, we choose a spatial representation of vorticity in a basis of Laplacian eigenfunctions. In this thesis, we show that unique properties of this basis make it useful for computer graphics applications. Particularly, the Navier-Stokes equations reduce to a compact form that is elegant and practical, permitting time integration schemes that operate directly in the reduced space of basis coefficients. These time integration schemes are efficient and energy preserving. For a number of useful geometries, our basis functions are analytic. We extend our method to work on simplicial meshes through the use of discrete exterior calculus.

Images and Videos

A minimum of three basis functions is needed to observe interesting dynamic behavior. This animation shows a vortex moving clockwise around the domain as it is carried by the flow of a larger vortex. This confirms what is described mathematically by the Helmholtz version of the Euler equations: the vorticity is advected by the flow.
Vorticity advected clockwise by larger vortex

2-D simulation with varying number of basis functions. More basis fields permit simulation of smaller scalevortices. Note that even for low dimensional bases, the flows produced are still smooth and the center of the vortices can still be tight; the dimensionality only limits the minimum scale of a vortex.
2-D simulation with 4 basis functions
2-D simulation with 16 basis functions
2-D simulation with 36 basis functions
2-D simulation with 64 basis functions
2-D simulation with 144 basis functions

Top left, bottom left: fluid simulation on 16x16 MAC grid with linear interpolation of velocity field. Grid artifacts are most noticeable at the centres of vorticies where the curvature is high. Top right, bottom right: fluid simulation using analytic basis functions for velocity field. The velocity field remains smooth and accurate in the areas of high curvature.
Coarse mesh
Mesh free simulation

Physical viscosity is simulated by decaying the energy in basis fields with a time constant proportional to their eigenvalue. Accounting for viscosity in our model is trivial and does not require precompu- tation. It can be controlled at run time by changing a single parameter.
Viscosity: None
Viscosity: Water
Viscosity: Oil

Analytic simulation on 3-D cubic domain.
3-D simulation with 81 basis functions
3-D simulation with 376 basis functions

Using DEC, we extended our algorithm to work with triangular meshes. The benefits of analyticity are lost, but allows for complex boundary conditions and immersed obstacles.
2-D triangular mesh: teapot
2-D triangular mesh: obstacle

We also used DEC to extend our algorithm to work with tetrahedral meshes.
3-D tet mesh: head
3-D tet mesh: head 2
3-D tet mesh: bust (ribbons)
3-D tet mesh: bust (particles)

These smoke simulations were rendered through volumetric ray tracing of density fields created by radial basis functions at advected particle positions. Not counting rendering costs, in both of these examples each simulation step took approximately 10ms, after a precomputation of less than 10 minutes.
Smoke in bust model: Ray traced
Smoke in head model: Ray traced

Some basis fields exhibit symmetry in one or more spatial directions. The dynamics amongst these basis fields will produce fluid motion that remains symmetric. By initializing an inviscid flow with a few of these basis functions, the resulting dynamics will change perpetually, but always retain an element of symmetry.

We use this property along with a few liberal adjustments to design a performance based artistic fluid simulation. For example, one modification we employ is to clamp particle positions to around the boundary of the fluid simulation domain. Particles will tend to accumulate into dense layers, which are continually accumulated and lifted off, creating a pleasing visualization of the vortices in the field.

Performance based symmetric fluid animation.