Physics Stack Exchange is a question and answer site for active researchers, academics and students of physics. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've implemented a fluid simulation based on the paper Stable Fluids.

It works quite well, except I would like to have the velocity at the "upper" edge just to outflow and not to re-enter on the lower(opposite) edge. Apparently that's a side-effect of the periodic boundaries.

Is there an easy method to still achieve this? How would I need to modify the velocity?

Edit: The fluid may just exit, since I'm just interested in how the velocity evolves (and since I'm adding new tracing particles all the time anyway).

Actually I use an (3d-)extended version of the CUDA fluid example. I guess it's mesh-full and yes, it involves the FFT.

share|cite|improve this question
Can you give a bit of context? If you just let the fluid flow out the upper boundary, I think you'll find that the fluid will fairly rapidly nearly entirely exit your simulation via the upper boundary. Is that the desired effect? Or do you want a system that conserves mass (or volume if incompressible, or some other sensible quantity)? – Kyle Oman Jun 13 '13 at 18:20
How are you implementing your simulation? Are you using mesh-full or mesh-free method? The answer varies depending on the specific method that you are using to simulate your flow. Are you using FFT as described in the paper? – Hydro Guy Jun 13 '13 at 22:09

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.