CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   zero gradient pressure B/C (https://www.cfd-online.com/Forums/openfoam-solving/77651-zero-gradient-pressure-b-c.html)

msrinath80 June 29, 2010 15:47

zero gradient pressure B/C
 
Can someone kindly help in explaining why setting the component of "pressure gradient" normal to the wall zero is an appropriate Boundary condition for walls?

Put simply, why should the pressure gradient (i.e. grad (p)) be orthogonal to the outward normal to the wall?

msrinath80 June 30, 2010 13:49

Anybody?? Does setting "grad(p) dot nhat = 0" mean that from the wall onward up till beyond the wall boundary (i.e. the region occupied by ghost CVs), there is no component of the "pressure gradient" in the direction of the outward wall normal?

In other words, physically speaking, we are enforcing the condition that there is no fluid flow through the wall?? Am I even close???

msrinath80 August 5, 2010 23:52

Found some free time. Thought I could use this to close my query. A little too embarrassing actually, but after a sharp reprimand from one of my profs. for not knowing something so trivial I have the answer:

http://www.ualberta.ca/~madhavan/zer...nt_at_wall.pdf

rob3rt August 7, 2010 00:16

Thank you for sharing Srniath.

msrinath80 August 7, 2010 00:26

Glad you found it useful :) Have a good weekend!

idrama August 7, 2010 14:22

Okay, I have mixed up x and n! I'm gonna to study this again, because it seems very interesting. Sorry for the rigor, but as a mathematician, one is compelled to investigate things more critically.

Cheers and have a nice one!

msrinath80 August 7, 2010 15:16

No problem. I for one welcome any criticisms. After all we are all here to share and learn :)

steph79 September 28, 2010 15:31

Is there a patch/method, in OpenFOAM, which extrapolates the pressure to the wall from the adjacent normal cells rather than forcing the approximation of dp/dy = 0 ?

That's my first question, my second being is it easily achievable to prescribe dp/dy = nu*d2v/dy2 as a custom patch?

I ask in the context of using the icoFoam solver on 2-D laminar boundary layers.

Any suggestions would be greatly appreciated. Thanks!

AsafPa November 11, 2010 09:58

I'm also interested in this topic. If you have a look on the cavity tutorial, the pressure-gradient normal to the movingWall is certainly not zero.

Did you already come to a result, steph79?

steph79 November 15, 2010 05:45

Quote:

Originally Posted by AsafPa (Post 283103)
I'm also interested in this topic. If you have a look on the cavity tutorial, the pressure-gradient normal to the movingWall is certainly not zero.

Did you already come to a result, steph79?

Yes, PRESTO! pressure discretisation is what you're looking for but whether that can easily be implemented in OpenFOAM I'm not sure. Could someone with more experience please comment on that?

Thank you.

sahm December 13, 2010 19:43

question
 
Hi, I have a question.
In page 2, line 6 where you say dv/dy=0. then d2v/dy2=0, I cannot see why is that? for other points, you have that because you can compare 2 points on the wall ( which is x direction) but for y direction, I don't know how to say that. Any way, thank you for this calculation, really helps understand what is going on in OpenFOAM.
Yours.

santiagomarquezd December 14, 2010 09:50

I think there is another reason for zeroGradient pressure BC at walls. It comes from numerics. When you implement PISO or SIMPLE methods finally a Poisson equation is assembled for pressure. This equation requires at least a one point with prescribed pressure which is searched from BC. If there is not a prescribed pressure BC then the pRefValue is taking into account. Since pressure is not known at walls, the BC is set to take the value from the nearest point within the fluid, or in other words taking the zeroGradient perpendicularly to the wall.

Just my 2 cents.

Regards.

murx July 28, 2015 11:02

Quote:

Originally Posted by sahm (Post 287302)
Hi, I have a question.
In page 2, line 6 where you say dv/dy=0. then d2v/dy2=0, I cannot see why is that? for other points, you have that because you can compare 2 points on the wall ( which is x direction) but for y direction, I don't know how to say that. Any way, thank you for this calculation, really helps understand what is going on in OpenFOAM.
Yours.

Sorry to open this thread again. But this is exactly what I was asking myself: dv/dy = 0 => d2v/dy2 = 0 ...why?

I was really happy to find a such a simple answer to this question but I actually doubt it's as simple as your prof pretended.

Luke.12 January 20, 2016 11:42

The second derivative of velocity along the wall is zero because the value is constant. The second derivative normal to the wall is zero because of the linear velocity increase in the viscous sublayer... correct me if I'm wrong.

murx January 20, 2016 12:05

Quote:

Originally Posted by Luke.12 (Post 581772)
The second derivatives of velocity are zero because of the linear velocity increase in the viscous sublayer... correct me if I'm wrong.

You are now bringing turbulence into the problem, which will not make this more easy to solve :) However, the linear velocity profile in the viscous sublayer of turbulent flows refers to the parallel velocity component u --> du/dy = const. You can't simply apply this to v.

I still think that dv^2/dy^2 is not generelly zero. However, for high Reynolds numbers the influence can be neglected since it is part of the visous terms in the NSE. For low Reynolds numbers, the zero gradient condition is wrong and can therefore lead to unphysical simulation results.

Luke.12 January 20, 2016 12:15

Ok, thank you, I have edited my initial reply quite fast, but still it does not explain what you are pointing out.

But if the turbulent flow and the viscous sublayer is really present, the wall normal velocity should be zero in that layer. And if that layer has a finite thickness, the first and second derivatives are zero as well at the wall, right?

Again sorry for confusion and thank you for quick reply!

murx January 20, 2016 13:23

I am not an expert in turbulence, but I think you are right about the vertical velocity component. It should be zero in the sublayer. And because of this, the second derivative should also be zero. But this line of argumentation only makes sense to me if the first layer of cells is thinner than the viscous sublayer.

But all this things we know about the viscous sublayer were derived based on certain assumptions and maybe even empirical findings. So I wouldnt use the conclusion from this ( --> du^2/dy^2) and insert this into the derivation of this purely mathematical attempt to derive the pressure boundary condition. At least not without thoroughly thinking it through.

Luke.12 January 20, 2016 13:49

I agree, but it is better than nothing. I will keep an eye on this thread and keep the problem in mind to ask someone more experienced too if solution does not appear until I do so.

I have hands on low-Re SST k-w and wall resolved LES right now, so my mesh is far below (y+ = 1) the viscous sublayer thickness (y+ = 5), so it won't get me toss, turn and sweat in the night.

It is also not clear to me, why it would not be similar to laminar flow problem... The danger of getting thin boundary layer and wall normal velocity components is even smaller there. At least as far as I understand.

Thanks for discussion and the initial post of this thread especially!

murx January 20, 2016 16:48

Quote:

It is also not clear to me, why it would not be similar to laminar flow problem... The danger of getting thin boundary layer and wall normal velocity components is even smaller there. At least as far as I understand.
Actually, if you look at the boundary layer equations by Prandtl (which I guess should be valid for laminar flow), you can see that they even explicitly state that dp/dy = 0 in the whole boundary layer. But still, there are certain assumptions necessary to get from the NSE to the boundary layer equations (i.e. concerning the magnitude of Re). And I am pretty sure, that the dp/dy = condition is not generally valid for low Re-numbers flows. I already experienced convergence issues that are most likely caused by this.

Also as I just had a look at the boundary layer equations... If you apply them at the wall (y=0). Then you get du2/dy2 = 1/mu * dp/dx. So if we can really use du2/dy2 = 0, as described in the derivation linked in the third post in this thread, we would get dp/dx = 0 (basically the Euler equation without convection terms due to u=v=0 at the wall). And this really doesn't make sense.

But if you ever find the answer to this question, let me know! :)

viraj20feb June 1, 2016 02:58

Physical significance and Maths behind boundary conditions
 
Hello,

Does anyone have any material specifying the physical significance and maths behind different boundary conditions(fixedValue, zeroGradient) in OpenFOAM?

Thanks


All times are GMT -4. The time now is 03:20.