weymouth / lily-pad

Real-time two-dimensional fluid dynamics simulations in Processing. Initiated by Dr G D Weymouth:
https://github.com/weymouth/
MIT License
162 stars 78 forks source link

TwoPhase is unstable #11

Open weymouth opened 8 years ago

weymouth commented 8 years ago

Migrated from issue #10.

The attached LilyPad.pde has a circle moving up and down in a two phase flow. If QUICK advection is used, the flow is fine. If the semi-lagrangian advection is used, the flow blows up (infinite velocity near the air/water/body interface) at the end of the first cycle of motion. The semi-lagrangian is much better for interactivity (since the time step can be fixed to a large value), so this instability should be corrected.

LilyPad.pde.zip

The fact that switching advection scheme fixes the problem means this is unlikely to be related to the pressure solver.

weymouth commented 8 years ago

Even without a body, and even using QUICK, the TwoPhase solver can become unstable if the waves are sufficiently large and energetic.

LilyPad.pde 2.zip