53
Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University, 2 Industrial Light + Magic, 3 Intel Corporation

Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

  • View
    219

  • Download
    1

Embed Size (px)

Citation preview

Page 1: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Coupling Water and Smoke to Thin Deformable and Rigid Shells

Coupling Water and Smoke to Thin Deformable and Rigid Shells

Eran Guendelman 1,2

Andrew Selle 1,3

Frank Losasso 1,2

Ronald Fedkiw 1,2

1Stanford University, 2Industrial Light + Magic, 3Intel Corporation

Page 2: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

MotivationMotivation

• Fluid simulation becoming more common

– Engineering, biomedicine, entertainment

• Want interaction with thin solids

– Parachutes

– Cardiovascular simulation

– CG characters w/clothing

Page 3: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

GoalGoal

• Two-way coupling between:

– Smoke or free-surface water

– Thin rigid and deformable open shells

• Prevent leaks across solid

Page 4: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

256x256x192 effective octree; 30k triangles

Page 5: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Volumetric vs. Thin SolidsVolumetric vs. Thin Solids

Volumetric Thin shell

Page 6: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Related Work: VolumetricRelated Work: Volumetric

• DLM / “Rigid Fluid” [Glowinski et al. ’94;Carlson et al. ’04]

• Inter-particle forces [Génevaux et al. ’03; Müller et al. ’04]

• Coupling solid velocity & fluid pressure

– Incompressible: [Takahashi et al. ’02]

– Compressible: [Yngve et al. ’00; Fedkiw ’02]

Page 7: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Diffuse Interface MethodsDiffuse Interface Methods

• Smear solid onto fluid grid

• e.g. Immersed boundary method [Peskin ‘72]

– Parasitic currents

Page 8: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Sharp Interface MethodsSharp Interface Methods

• Incorporate jump conditions into stencils

– Ghost fluid method [Fedkiw et al. ’99; Tam et al. ‘05]

– Immersed interface method [LeVeque & Li ’94]

Page 9: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Our ApproachOur Approach

• Couple using

– Solid velocity & fluid coupling pressure

• Sharp interface treatment

• Prevent leaks using robust ray intersections

Page 10: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Talk OverviewTalk Overview

• Fluid simulation

• Solid simulation

• Preventing leaks across solid

• Enforcing solid velocity on fluid

• Computing and applying coupling force

• Summary and future work

Page 11: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Talk OverviewTalk Overview

• Fluid simulation (focus on water)

• Solid simulation

• Preventing leaks across solid

• Enforcing solid velocity on fluid

• Computing and applying fluid coupling force

• Summary and future work

Page 12: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Fluid SimulationFluid Simulation

• Assume incompressible & inviscid

• Use projection method: [Chorin ’68]

un

Advect un and add gravity ! u*

Project u* ! un+1

un+1

u* violates incompressibility

Compute pressure to enforce incompressibility

(u is fluid velocity)

Page 13: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Fluid GridFluid Grid

• Uniform & octree grids [Losasso et al. ’04]

• Staggered grid configuration [Harlow & Welch ‘65]

ui+½,j

ui-½,j

vi,j+½

vi,j-½

pi,j

Page 14: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

AdvectionAdvection

• First order semi-Lagrangian [Courant et al. ’52; Stam ‘99]

– Advection on nodes

x-ut

u x

Page 15: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Particle Level Set MethodParticle Level Set Method

• Level set captures water-air interface

• Particles help correct interface

water

air

[Enright et al. ‘02]

Page 16: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Water Simulation Step (n!n+1)Water Simulation Step (n!n+1)

un,n

Advance particle level set ! n+1

Advect un and add gravity ! u*

Project u* ! un+1

un+1,n+1

Advect and particles

Page 17: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Now Add Solids to the Mix…Now Add Solids to the Mix…

• Fluid simulation

• Solid simulation

• Preventing leaks across solid

• Enforcing solid velocity on fluid

• Computing and applying fluid coupling force

• Summary and future work

Page 18: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Now Add Solids to the Mix…Now Add Solids to the Mix…

• Black box:

Input: external forces

Output: positions and velocities

[Guendelman et al. ’03] [Bridson et al. ’02,’03]

Page 19: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Surface QuantitiesSurface Quantities

• Rigid body

– Directly compute

• Deformable body

– Barycentric weights

Page 20: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Talk OverviewTalk Overview

• Fluid simulation

• Solid simulation

• Preventing leaks across solid

• Enforcing solid velocity on fluid

• Computing and applying fluid coupling force

• Examples, summary, and future work

Page 21: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Key: VisibilityKey: Visibility

Page 22: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Thin Shell Aware InterpolationThin Shell Aware Interpolation

Check visibility of interpolation nodesUse replacement ghost value when interpolating

Page 23: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Replacement Ghost ValuesReplacement Ghost Values

Fluid velocity (u)

Level set ()

use solid velocity

average from nearest valid nodes

Page 24: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Thin Shell Aware AdvectionThin Shell Aware Advection

• Clip semi-Lagrangian rays

u

x-ut

Page 25: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Crossed Over NodesCrossed Over Nodes

• Represent information from opposite side

• Reassign valid values by averaging

Page 26: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Thin Shell Aware Fluid StepThin Shell Aware Fluid Step

un,n

Advance particle level set ! n+1

Advect un and add gravity ! u*

Project u* ! un+1

un+1,n+1

Thin shell aware advection( and particles)

Thin shell aware advection (u)

…see paper for more details

Page 27: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

210x140x140 uniform; 30k triangles

Page 28: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

210x140x140 uniform; 30k triangles

Page 29: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Talk OverviewTalk Overview

• Fluid simulation

• Solid simulation

• Preventing leaks across solid

• Enforcing solid velocity on fluid

• Computing and applying fluid coupling force

• Summary and future work

Page 30: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Rasterizing SolidRasterizing Solid

• Rasterize onto faces of fluid grid

Page 31: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Solid Affecting FluidSolid Affecting Fluid

• Solid prescribes velocity on rasterized faces

• Enforce as Neumann boundary conditions in projection step:

Project u* ! un+1

Page 32: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Which Solid Velocities?Which Solid Velocities?

• At time n+1!n+2, at solid-fluid interface

– Fluid moves with velocity enforced during un+1 projection

– Solid moves from to Xn+1 to Xn+2

• Want these motions to match (reduce mass loss)

• Solution:

– Enforce effective solid velocity: Veff=(Xn+2-Xn+1)/t

Page 33: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

One-Way Coupling StepOne-Way Coupling Step

un,n,Sn,Sn+1

Advance particle level set ! n+1

Advect un and add gravity ! u*

Project u* ! un+1

un+1,n+1,Sn+1,Sn+2

Advance solid ! Sn+2

Enforce effective solid velocities (n+1! n+2) at

solid-fluid interface

(S is the solid’s state)

Page 34: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

160x192x160 effective octree

Page 35: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

192x192x192 effective octree; 60k triangles

Page 36: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Talk OverviewTalk Overview

• Fluid simulation

• Solid simulation

• Preventing leaks across solid

• Enforcing solid velocity on fluid

• Computing and applying fluid coupling force

• Summary and future work

Page 37: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Fluid Coupling ForceFluid Coupling Force

• Want to use fluid pressure

• Incompressible pressure can be noisy

– Incompressibility = hard constraint

– Enforcing solid velocity = hard constraint

– Better for compressible fluids [Yngve et al. ‘00; Fedkiw ‘02]

Page 38: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Smoother Coupling PressureSmoother Coupling Pressure

• Treat solid as fluid

• Solve variable density fluid for pc

• Similar to projection step, but:

– Solid velocities not enforced

– Fluid velocities not modified!

Page 39: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Two Pressure Solves!Two Pressure Solves!

• Incompressible pressure (projection):

– Enforce incompressibility & solid velocity

– Essential for reducing mass loss

• Coupling pressure:

– Does not modify fluid velocity

– Essential for smoother coupling force on solid

Page 40: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Must Enforce Solid VelocityMust Enforce Solid Velocity

Enforced!

Enforcing solid velocity

Rigid Fluid [Carlson et al. ’04]

Mass loss

Page 41: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Computing Force on SolidComputing Force on Solid

• Fluid pressure pushes on both sides

p1

p2

Page 42: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Computing Force on SolidComputing Force on Solid

• Net force is proportional to pressure jump [pc]

p1 - p2

Page 43: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Computing Force on SolidComputing Force on Solid

Rasterize solid

Compute coupling pressure

Pressure jumps on faces

Average to nodes

Extrapolate

Interpolate at centroid

Compute force

Page 44: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Two-Way Coupling StepTwo-Way Coupling Step

un,n,Sn,Sn+1

Advance particle level set ! n+1

Advect un and add gravity ! u*

Advance solid ! Sn+2

Project u* ! un+1

un+1,n+1,Sn+1,Sn+2

Compute coupling pressure and apply force to solid

Page 45: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

148x148x111 uniform; 2.5k triangles

Page 46: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

200x200x200 effective octree; 30k triangles

Page 47: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

256x256x192 effective octree; 30k triangles

Page 48: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

256x256x192 effective octree; 30k triangles

Page 49: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Talk OverviewTalk Overview

• Fluid simulation

• Solid simulation

• Preventing leaks across solid

• Enforcing solid velocity on fluid

• Computing and applying fluid coupling force

• Summary and future work

Page 50: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

SummarySummary

• Sharp interface treatment

– Prevent leaks using ray intersections (visibility)

• Solid prescribes velocity boundary conditions

– Use effective velocity to reduce mass loss

• Smooth coupling force applied to solid

– Treat solid as fluid to compute smoother pressure

Page 51: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

Future WorkFuture Work

• Absorption, adhesion, permeability

• Compare against experiments

Page 52: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

AcknowledgementsAcknowledgements

• Mike Houston, Christos Kozyrakis, Mark Horowitz, Bill Dally, Vijay Pande

• Stanford Graphics Lab

• ONR, ARO, NSF, PECASE, Sloan Foundation, Packard Foundation

Page 53: Coupling Water and Smoke to Thin Deformable and Rigid Shells Eran Guendelman 1,2 Andrew Selle 1,3 Frank Losasso 1,2 Ronald Fedkiw 1,2 1 Stanford University,

The EndThe End