CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Open Channel Flow using InterFoam type solver (https://www.cfd-online.com/Forums/openfoam-solving/63341-open-channel-flow-using-interfoam-type-solver.html)

 sxhdhi April 6, 2009 05:25

Open Channel Flow using InterFoam type solver

Dear Foamers,

Please allow me to create this thread for those of who are interesting in Open Channel Flow simulation by using InterFoam type solvers such as InterFoam, rasInterFOam, and so on.

I have spend over one month on trying to run open channel flow case using InterFOAM, but result is very disappointed. After that, I gave up for testing various BCs and instead it I start to look into the source code of interFoam.

From now on, I will write down and share my doubt, ideas and I hope Foamers who are interesting in this part can join me to fight the problems together in order to solve it.

today, I would like to write down the Governing equations used in InterFoam

(1) continuity Eq
div(U)=0
(2) momentum Eq
(3) free surface capturing Eq
ddt(gamma)+div(U,gamma)+div((1-gamma)*Ur,gamma)=0

where p=pd+rho*gh (4)

laplacian Eq for pd
(5)
laplacian(rUa, pd)=1/ap*[H(U)-div(Fs)-g*div(rho)-gh*div(rho)]

now I have two questions during looking into the source code:
(1) in UEqu.C where is the source term rho*g, this term should be in R.H.S.
(2) In PEqu.C still miss source term rho*g and I cannot understand the laplacian equation for pd
laplacian(rUa, pd)=div(phi)
in my view, phi is already the term after intergretion. why still have to do divergent process.

find problem---> solve it --> new problem -->solve again!!!!!

Regards

Su Xiaohui

 sxhdhi April 21, 2009 02:47

It is so regret that no one is interested in this thread.

I am still focusing on this problem.

What I found now is p=pd+rho*gh, where rho*gh is not particularly pointed to hydrostatic pressure because in code, gh=g& mesh.C(), the real hydrostatic presure shoul be the expression rho*g*(free surface -mesh.C()).

I also found out that in Ueqn and Peqn, source term (gravity term) may not be used.

Best regards,

Su Xiaohui

 huoyinghw May 5, 2009 10:28

hello, Su Xiaohui
I am also studying in the interFoam and thanks for your share.

 awacs May 5, 2009 21:58

Hi,Su Xiaohui

I am interested in multiphase flow too.I have modified the interFoam solver to simulate three dimensional,non-newtonian,nonisothermal,incompressible,laminar flow.The result seems good.
My problem is that when I use the added Cross-WLF viscosity model,the Courant Number increase enormously after a few steps.Then the calculation stopped.
I'll pay more attention to it.