
[Sponsors] 
December 11, 2012, 10:19 
interFoamlosing fluid in free surface simulating

#1 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
Hello all
why in simulating free surface flow around a body (2D), by passing time, the level of fluid decreases(lose)? i tried a channel, just a domain without any body, and saw for this case there isn't any losing fluid phase! how ever when i try that channel with a cylinder there is decreasing in fluid level. i'm using OpenFoam 1.6, and saw previous posts in this site but no answer for this problem thanks all 

December 11, 2012, 10:25 

#2 
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,686
Rep Power: 26 
Hi Anim,
It sounds like the boundary conditions on the cylinder are wrong. Would you be so kind as to post them here (along with the other boundary conditions). BTW: Are you using 1.6 or 1.6ext. This is terribly important, since they use two different definitions of the pressure. Kind regards, Niels 

December 11, 2012, 11:03 

#3 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
Hi Niels, Thanks for comment
i think its OF 1.6 , because of this: /** C++ **\  =========    \\ / F ield  OpenFOAM: The Open Source CFD Toolbox   \\ / O peration  Version: 1.6   \\ / A nd  Web: http://www.OpenFOAM.org   \\/ M anipulation   \**/ and its my BC for Pressure: boundaryField { down { type buoyantPressure; value uniform 0; } cylinder { type buoyantPressure; value uniform 0; } up { type totalPressure; p0 uniform 0; U U; phi phi; rho rho; psi none; gamma 1; value uniform 0; } outlet { type zeroGradient; } inlet { type buoyantPressure; value uniform 0; } frontAndBackPlanes { type empty; } } 

December 11, 2012, 11:06 

#4 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
i can send BC for U and Alpha1 too, if it theses can help!


December 11, 2012, 18:36 

#5 
Senior Member
Kent Wardle
Join Date: Mar 2009
Location: Illinois, USA
Posts: 207
Rep Power: 13 
Along with BC consistency, also check that you don't have the wall boundary on your cylinder set to patch in polyMesh/boundaryit needs to be type wall.


December 12, 2012, 04:16 

#6 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
tnx kent, i already put it "wall" .


December 12, 2012, 04:59 

#7 
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,686
Rep Power: 26 
What are the boundary conditions for the velocity? If your are not loosing water without the cylinder, but loosing water with the cylinder, it appears you have a flux over the cylinder wall.
The pressure conditions seems to be correct. / Niels 

December 12, 2012, 05:54 

#8 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
Velocity:
dimensions [0 1 1 0 0 0 0]; internalField uniform (1 0 0); boundaryField { cylinder { type fixedValue; value uniform (0 0 0); } up { type pressureInletOutletVelocity; value uniform (0 0 0); } down { type fixedValue; value uniform (1 0 0); } outlet { type zeroGradient; } inlet { type fixedValue; value uniform (1 0 0); } frontAndBackPlanes { type empty; } } alpha1: dimensions [0 0 0 0 0 0 0]; internalField uniform 0; boundaryField { cylinder { type zeroGradient; } up { type inletOutlet; inletValue uniform 0; value uniform 0; } down { type calculated; value uniform 1; } outlet { type zeroGradient; } inlet { type calculated; value uniform 1; } frontAndBackPlanes { type empty; } } setFields: defaultFieldValues ( volScalarFieldValue alpha1 0 ); regions ( boxToCell { box (15.5 10.5 0.506) (30.5 7 0.506); fieldValues ( volScalarFieldValue alpha1 1 ); } ); Dear Niels i couldn't understand this: "it appears you have a flux over the cylinder wall." Thanks for your attention to this problem. Amin 

December 12, 2012, 06:14 

#9 
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,686
Rep Power: 26 
Hi
It seems that your boundary conditions mostly makes sense, however, is it deliberate that you have a nonzero velocity and specify the value of alpha on the bottom boundary? If you want to have slip conditions, merely write "slip" as type. Besides that I do not think I have much to contribute. Kind regards, Niels 

December 12, 2012, 07:14 

#10 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
Hi Niels
yes, bottom boundary is continued to infinity, so i use inlet for this type BC. i tried the slip BC for down(bottom boundary) and it didn't help and i had losing in fluid again. Dear niels, what will exactly happen, when we use " bouyantPressurevalueuniform 0 " on cylinder? my mean is: what will be the pressure at final?! sorry for my questions. Regards Amin 

December 12, 2012, 11:44 

#11 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
Hi Foamers
I found something else: noslip >increasing fluid's level when i use noslip boundary condition for bottom boundary(down),there is increasing in level of fluid. and you know before for other condition for down, like slip or inlet condition, there is decreasing in level of fluid !!!!!! somebody has idea? 

December 14, 2012, 09:18 

#12 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
no body can help
I'm waiting Foamers 

December 14, 2012, 10:57 

#13 
Senior Member
Santiago Marquez Damian
Join Date: Aug 2009
Location: Santa Fe, Santa Fe, Argentina
Posts: 430
Rep Power: 15 
Could you post a sketch of your domain with names of the BC's? In free surface flow the free surface sometimes lowers passing over an obstacle depending on the Froude number.
Regards.
__________________
Santiago MÁRQUEZ DAMIÁN, Ph.D. Research Scientist Research Center for Computational Methods (CIMEC)  CONICET/UNL Tel: 543424511594 Int. 7032 Colectora Ruta Nac. 168 / Paraje El Pozo (3000) Santa Fe  Argentina. http://www.cimec.org.ar 

December 15, 2012, 13:14 

#14 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
Hi Santiago
that's my domain and you can see the type of BC at upper posts. my problem isn't hydraulic jump. it's about mass conservation: by passing the amount of fluid creases or decreases. nufluid=0.00666667 rhofluid=150 >Re=150 nuair=1.48e02 rhoair=1 Regards 

December 15, 2012, 13:41 

#15 
Senior Member
Santiago Marquez Damian
Join Date: Aug 2009
Location: Santa Fe, Santa Fe, Argentina
Posts: 430
Rep Power: 15 
Hi Amin,
What is the position of the free surface and the center of the cylinder? Could you post a pic of the results showing the problem and the lasts timesteps of run log? Regards
__________________
Santiago MÁRQUEZ DAMIÁN, Ph.D. Research Scientist Research Center for Computational Methods (CIMEC)  CONICET/UNL Tel: 543424511594 Int. 7032 Colectora Ruta Nac. 168 / Paraje El Pozo (3000) Santa Fe  Argentina. http://www.cimec.org.ar 

December 16, 2012, 05:00 

#16 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
Hi Santiago
it's the position of cylinder and free surface. one picture is at 0sec and another is at 442sec. As you see at 442 sec the level of free surface come down, means: we don't have mass conservation. time step log: MULES: Solving for alpha1 Liquid phase volume fraction = 0.550726 Min(alpha1) = 5.26623e21 Max(alpha1) = 1.00001 MULES: Solving for alpha1 Liquid phase volume fraction = 0.550726 Min(alpha1) = 7.57881e109 Max(alpha1) = 1.00001 DICPCG: Solving for p, Initial residual = 6.11147e05, Final residual = 2.01459e06, No Iterations 1 DICPCG: Solving for p, Initial residual = 8.06157e06, Final residual = 3.93617e07, No Iterations 5 DICPCG: Solving for p, Initial residual = 6.26022e06, Final residual = 9.38293e08, No Iterations 15 time step continuity errors : sum local = 1.29399e08, global = 6.4686e10, cumulative = 1.0709e08 ExecutionTime = 30.08 s ClockTime = 31 s Courant Number mean: 0.0155618 max: 0.29406 deltaT = 0.00533165 Time = 442.457 Regards 

December 16, 2012, 06:23 

#17 
Senior Member
Santiago Marquez Damian
Join Date: Aug 2009
Location: Santa Fe, Santa Fe, Argentina
Posts: 430
Rep Power: 15 
Amín, it doesn't look it is loosing mass, nevertheless the free surface solution is not so good. It is difficult to initialize a channel inlet, since the boundary condition is constant in velocity for air and water, which is not true. Each fluid has its own velocity profile. There are at least two remedies, 1) extending the domain more the left and retain the inlet BC to give the fluids enough space to develop the profiles or ) make the inlet by the left, bottom corner and put a wall at the left so that the free surface is not contaminated by the inlet effect. In this case you need enough space to leave the fluid turn from vertical direction to horizontal direction. In both cases you need a refined mesh near the free surface, I mean, 20 or 30 elements in the space between the cylinder and the free surface and the same over the surface, then you change the spacing to the top and bottom the save elements.
I would try option 1) first. Regards. Santiago.
__________________
Santiago MÁRQUEZ DAMIÁN, Ph.D. Research Scientist Research Center for Computational Methods (CIMEC)  CONICET/UNL Tel: 543424511594 Int. 7032 Colectora Ruta Nac. 168 / Paraje El Pozo (3000) Santa Fe  Argentina. http://www.cimec.org.ar 

December 16, 2012, 06:44 

#18 
Member
Amin
Join Date: Mar 2012
Posts: 60
Rep Power: 6 
Dear Santiago
unfortunately we have mass losing,maybe in this pictures it's not shown well, if time pass more(for example till 1000sec), the level of free surface comes below the cylinder! and it's not true! I solved this problem for two inlet and two outlet(water and air apart), and also for the velocity of air been zero or velocity same as water, but there was mass losing again.! I don't know why this situation changes with different BC, as i said before if we put no slip wall condition for down the level of free surface come up and for the other BCs it comes down!! i will try bigger domain and tell you the result Regards 

December 16, 2012, 06:50 

#19 
Senior Member
Santiago Marquez Damian
Join Date: Aug 2009
Location: Santa Fe, Santa Fe, Argentina
Posts: 430
Rep Power: 15 
HI, two inlets is correct, but two outlets with fixed position for the free surface is not since you don't know the exact free surface position. The outlet can be only one boundary with zeroGradient for alpha1.
Regards.
__________________
Santiago MÁRQUEZ DAMIÁN, Ph.D. Research Scientist Research Center for Computational Methods (CIMEC)  CONICET/UNL Tel: 543424511594 Int. 7032 Colectora Ruta Nac. 168 / Paraje El Pozo (3000) Santa Fe  Argentina. http://www.cimec.org.ar 

December 16, 2012, 15:39 

#20 
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Deltares, Delft, The Netherlands
Posts: 1,686
Rep Power: 26 
Hi Amin,
Something just occurred to me. You are specifying a flow rate over the water column and you are specifying the water level at the inlet. In order to maintain this flow condition, you need some kind of driving force, which in your case can only be a horizontal component of the gravitational vector OR a slope of the free surface. Have you checked whether the slope of the free surface and hence your loss of water is not a physical sane response; especially because with the presence of the cylinder, the flow resistance is much larger than without the cylinder. Kind regards, Niels 

Thread Tools  
Display Modes  


Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
free surface model  sjtusyc  CFX  3  September 5, 2012 18:33 
free surface modelling using VOF  sci  Main CFD Forum  10  August 29, 2012 07:43 
buoyantPimpleFoam with free surface (like interFoam)  Andreas.Herwig  OpenFOAM  0  March 1, 2011 13:07 
Interfoam... free surface simulation urgent  lostin4ever  Main CFD Forum  4  October 12, 2010 08:29 
Can Flow3D plot the free surface area in Isosurface or colour variable?  therockyy  FLOW3D  1  June 20, 2010 19:36 