0
Calculate water depth in openfoam

Hello

I'm trying to make some modification in the code of openfoam. I'm using a solver based on pisofoam and simulate a channel with water flowing in it and I need to calculate a function that is dependent on the water depth (H).

My question is: how can I access to the values of H at everytime step? Or how I can calculate? I need the value of the water depth to perform other calculations, any ideas would be really helpful.

Thank you in advance.


OpenFOAM 17-08-21, 9:51 a.m. gatonegro
1

Hi,

In the link below, you'll find the document and the files in which the effect of gravity is added to an incompressible solver, simpleFoam. The document Appendix.PDF has the details on modifications made to simpleFoam and the folder simpleGravityFoam has the source codes to the modified solver.

http://bit.ly/3qymPuR

However, if you're looking to find the water depth from it's free surface, you'd need a multiphase solver. Only then can the solver understand the location of the free surface to calculate the water depth from.

I hope this helps.

Regards,
Ashley

17-08-21, 1:47 p.m. ashleymelvin

Dear all,

I am working with OpenFOAM. I wonder that whether it is possible to calculate water depth and free surface elevation in EnSight.
 

Taco Bell Survey
 


18-08-21, 3:43 p.m. Quentin

Login to add comment


0

Dear all,

I am working with OpenFOAM. I wonder that whether it is possible to calculate water depth and free surface elevation (scalar variables) in EnSight.

Many thanks.
 

MyLowesLife

24-08-21, 12:54 p.m. Yolanda


Log-in to answer to this question.