CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   roughness in shallowWaterFoam (http://www.cfd-online.com/Forums/openfoam/94208-roughness-shallowwaterfoam.html)

WSc November 9, 2011 04:46

roughness in shallowWaterFoam
 
Hallo everybody,

I want to do an open-channel simulation with shallowWaterFoam.
How can I define the bed-roughness? Or do I have to model it somehow?

Regards,
Wolfgang

dai_bach July 16, 2013 21:51

Are you looking to model a free-surface flow?
 
Hi,

This reply may come far too late for the original post but I hope it may help other openfoam users. I've been trying to model certain classes of free-surface gravity currents for which the horizontal length scale (x and/or y) is much larger than the vertical scale (z). In this framework, vertical accelerations are small compared to gravity, and the conservation equations can be depth averaged which leads to what are often called the shallow water equations. For this reason, I started to investigate the shallowWaterFoam solver. However, as is described in

HTML Code:

http://www.tfd.chalmers.se/~hani/kurser/OS_CFD_2010/johanPilqvist/johanPilqvistReport.pdf
this solver has been written for atmospheric/oceanic flows where the depth (z) is large compared to the Earth's radius. Furthermore, the top and bottom stresses are assumed to be zero. Hence, as is, this solver cannot be used to treat the kind of problem that I've described above. However, with modifications to the equation set in shallowWaterFoam.C, the same files can be used to tackle these classes of problems via a finite volume method.

yhaomin2007 July 22, 2013 14:10

I think you can just use a rough wall function. You may look it up in turbulence model wall function source file.

dai_bach July 22, 2013 14:31

That would mean that the "rough wall" would be one of the "frontAndBack faces". I don't think that would work as the domain is only one-cell thick in the depthwise direction, but I could be wrong.

haze_1986 September 2, 2013 03:58

you are right. it would not work since it is only one cell thick. In depth averaged models the wind and bed stresses act as souce and sink to the momentum equations. I am currently working on this.

andyru September 4, 2013 09:03

hi,
for bottom roughness you just have to impose an additional source. I did that already and that works brilliantly. It is easy:

Code:

...=lambda*hU
Best,

andy

haze_1986 September 24, 2013 02:49

Quote:

Originally Posted by andyru (Post 449834)
hi,
for bottom roughness you just have to impose an additional source. I did that already and that works brilliantly. It is easy:

Code:

...=lambda*hU
Best,

andy

Hi Andy, did you include this in the hUEqn, momentumPredictor or inside the piso loop?

andyru September 24, 2013 04:33

According to Jasak PhD http://powerlab.fsb.hr/ped/kturbo/Op...jeJasakPhD.pdf
I added it to momentum predictor as well as in piso-loop.

haze_1986 September 24, 2013 05:09

Quote:

Originally Posted by andyru (Post 453269)
According to Jasak PhD http://powerlab.fsb.hr/ped/kturbo/Op...jeJasakPhD.pdf
I added it to momentum predictor as well as in piso-loop.

Can you show me how it can be implemented in both momentum predictor and pisoloop? I have a couple of term that I need to add in shallowWaterFoam.

haze_1986 October 1, 2013 01:34

Fixed, thanks


All times are GMT -4. The time now is 04:40.