CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM (
-   -   interFoam - mass conservation (

wbetz August 5, 2009 16:00

interFoam - mass conservation

Why isn't the boundary condidition 'zeroGradient' for pressure on walls not working anymore in OpenFOAM 1.6 (interFoam)? (if you do, there is a problem with mass conservation ...)

type zeroGradient;

... instead you have to use: (why ???)

type buoyantPressure;
value uniform 0;


sega August 6, 2009 01:40

I suppose this is due to the replacement of pd with static pressure p.
Have a look into the Release Notes for version 1.6 (Section 5.1 Solver restructuring):


pd replaced by static pressure p. All solvers in which buoyancy affects might be strong have been converted from using pd to p with improved numerics to give equally good accuracy and stability. This change is prompted by the need to remove the confusion surrounding the meaning and purpose of pd.

wbetz August 6, 2009 03:51

I agree with that - however, does somebody has more information on that behaviour ('zeroGradient' for pressure on walls ist not working anymore)?

And are there any other BCs you have to be aware of (as to a similar behaviour) in OF-version 1.6?

carsten September 21, 2009 10:40

Dear Wolfgang,

due to the nature of the PISO-algorithm used in interFoam, it is necessary to have a very "good" pressure field, as the pressure field is required in the velocity correction step of the scheme in order to reach mass conservation (i.e.div(U)=0).

If you look at the PISO-algorithm you will see that this means if the flux is zero (as it is orthogonal to the wall) it is necessary that the second derivative of pressure (orthogonal to the wall) must be zero, too (in areas where the density is constant).

buoyantPressure fulfills this requirement in areas of constant VOF-function / density. I'm not sure about mass conservation if sloped walls touch areas with VOF-values 0<VOF<1.

Bye and good luck,

Carsten Thorenz

idrama December 7, 2010 15:22

Has anybody ever done a mass conservation analysis in a pipe flow within VOF approach?

All times are GMT -4. The time now is 06:48.