# Numerical implementation of Boundary conditions in fractional step method

 Register Blogs Members List Search Today's Posts Mark Forums Read

 November 15, 2021, 19:33 Numerical implementation of Boundary conditions in fractional step method #1 Member   Join Date: Feb 2011 Posts: 41 Rep Power: 15 Hello, I know there are a lot of debates on the choice of the boundary conditions in the fractional step method. I'm reading Kim and Moin's 1985 JCP paper. I can understand most of it but have some difficulty in understanding the boundary conditions. May I ask the following question? In their paper, see the screenshot below, where they used Taylor series to get boundary conditions for the intermediate velocities, it requires to evaluate the derivative of phi on the boundary. In staggered grid, phi is defined on the center of cells. Does it mean that we should use one-sided finite difference method to get the derivatives of phi on the boundaries (basically extrapolation)? Thanks. Screenshot 2021-11-16 at 08.27.52.jpg

November 16, 2021, 04:00
#2
Senior Member

Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,815
Rep Power: 73
Quote:
 Originally Posted by jollage Hello, I know there are a lot of debates on the choice of the boundary conditions in the fractional step method. I'm reading Kim and Moin's 1985 JCP paper. I can understand most of it but have some difficulty in understanding the boundary conditions. May I ask the following question? In their paper, see the screenshot below, where they used Taylor series to get boundary conditions for the intermediate velocities, it requires to evaluate the derivative of phi on the boundary. In staggered grid, phi is defined on the center of cells. Does it mean that we should use one-sided finite difference method to get the derivatives of phi on the boundaries (basically extrapolation)? Thanks. Attachment 87141

Actually no. The derivative is evaluated at the previous time step, thus you have already solved the Poisson problem with the Neumann BCs and your d(phi)/dn is already computed.

However, be carefull that the second order Taylor series does not imply that the BCs produces a second order accurate truncation error, you can see that it is a firts order accurate BC.

November 16, 2021, 04:16
#3
Member

Join Date: Feb 2011
Posts: 41
Rep Power: 15
Quote:
 Originally Posted by FMDenaro Actually no. The derivative is evaluated at the previous time step, thus you have already solved the Poisson problem with the Neumann BCs and your d(phi)/dn is already computed. However, be carefull that the second order Taylor series does not imply that the BCs produces a second order accurate truncation error, you can see that it is a firts order accurate BC.

I'm not sure if I understand you correctly. In staggered grid, the pressure is defined at the cell center. For uniform grid, the boundary is half-cell-distance away from the first cell center. Even for the pressure gradient from the last time step, we still need to extrapolate in space to get the pressure gradient at the boundary. Am I right?

November 16, 2021, 04:26
#4
Senior Member

Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,815
Rep Power: 73
Quote:
 Originally Posted by jollage Thanks for your reply, FMDenaro! I'm not sure if I understand you correctly. In staggered grid, the pressure is defined at the cell center. For uniform grid, the boundary is half-cell-distance away from the first cell center. Even for the pressure gradient from the last time step, we still need to extrapolate in space to get the pressure gradient at the boundary. Am I right?

No. You have already the value of the derivative on the boundary, you do not need to discretize. The expression you used in the previous time step is n.(v* - vn)/dt, v* being the intermediate value of the previous time step. This is the Neumann BCs used for solving the pressure equation at tn.

To better understand, consider the intermediate velocity at the time step n+1 and that at the time step n.

November 16, 2021, 05:08
#5
Member

Join Date: Feb 2011
Posts: 41
Rep Power: 15
Quote:
 Originally Posted by FMDenaro No. You have already the value of the derivative on the boundary, you do not need to discretize. The expression you used in the previous time step is n.(v* - vn)/dt, v* being the intermediate value of the previous time step. This is the Neumann BCs used for solving the pressure equation at tn. To better understand, consider the intermediate velocity at the time step n+1 and that at the time step n.
Maybe you are referring to some other formulation different than the one in Kim and Moin's paper? If it's Neumann type for pressure, I guess they will explicitly mention it?

I have written down the two steps for v velocity as you suggested (with the AB2 and CN method). Please be more specific on how to understand the issue with and

 November 16, 2021, 05:26 #6 Senior Member   Filippo Maria Denaro Join Date: Jul 2010 Posts: 6,815 Rep Power: 73 The paper of Kim & Moin is exactly what I am referring. You need to consider the whole procedure. That is to compute the intermediate BCs for v* at time tn+1 you need to consider the computation of the pressure at time tn. At the time step tn you compute the pressure problem Div Grad phi = (1/dt) Div v* with the Neumann BC n.Grad phi = (1/dt) n.(v* -v) That is you have the pressure computed in the cell center but also the evaluation of the derivatives on the faces lying on the boundary (RHS). If you wnat, you can see that like using ghost point and computing the central derivative at second order of accuracy.

 November 16, 2021, 05:57 #7 Senior Member   Filippo Maria Denaro Join Date: Jul 2010 Posts: 6,815 Rep Power: 73 Have also a look to these papers https://www.researchgate.net/publica...ection_methods https://www.researchgate.net/publica...v8onk7-JA9ssEA

November 16, 2021, 06:24
#8
Member

Join Date: Feb 2011
Posts: 41
Rep Power: 15
Quote:
 Originally Posted by FMDenaro Have also a look to these papers https://www.researchgate.net/publica...ection_methods https://www.researchgate.net/publica...v8onk7-JA9ssEA
I can understand your way of imposing the boundary conditions, which is in the same spirit as the one in Kim and Moin. You said that "...but also the evaluation of the derivatives on the faces lying on the boundary (RHS)." I think I'm confused by this statement. The stagger grid I use is attached. For example, for v (red arrows), I don't define it on the top and bottom boundaries. It seems to me that I cannot get any value of RHS of n.Grad phi = (1/dt) n.(v* -v) on the boundary for v. Please advice.

Screenshot 2021-11-16 at 19.17.54.jpg

November 16, 2021, 06:40
#9
Senior Member

Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,815
Rep Power: 73
Quote:
 Originally Posted by jollage I can understand your way of imposing the boundary conditions, which is in the same spirit as the one in Kim and Moin. You said that "...but also the evaluation of the derivatives on the faces lying on the boundary (RHS)." I think I'm confused by this statement. The stagger grid I use is attached. For example, for v (red arrows), I don't define it on the top and bottom boundaries. It seems to me that I cannot get any value of RHS of n.Grad phi = (1/dt) n.(v* -v) on the boundary for v. Please advice. Attachment 87148

In fact, for a staggered grid the tangential components is posed badly ... I highlighted this problem in the paper and the need to have more accurate intermediate BCs.

Clearly, you could think u* located at a ghost node or considering a different derivative for the diffusive term along y in such a way to have the last cells close to the boundaries of half size and u* located exactly on the boundary. Then you have to construct the tangential derivative d phi/dt along the boundary.

November 16, 2021, 06:42
#10
Senior Member

Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,815
Rep Power: 73
Quote:
 Originally Posted by jollage I can understand your way of imposing the boundary conditions, which is in the same spirit as the one in Kim and Moin. You said that "...but also the evaluation of the derivatives on the faces lying on the boundary (RHS)." I think I'm confused by this statement. The stagger grid I use is attached. For example, for v (red arrows), I don't define it on the top and bottom boundaries. It seems to me that I cannot get any value of RHS of n.Grad phi = (1/dt) n.(v* -v) on the boundary for v. Please advice. Attachment 87148

Note that the red arrows must be defined also on top and bottom boundaries

November 16, 2021, 09:29
#11
Member

Join Date: Feb 2011
Posts: 41
Rep Power: 15
Quote:
 Originally Posted by FMDenaro In fact, for a staggered grid the tangential components is posed badly ... I highlighted this problem in the paper and the need to have more accurate intermediate BCs. Clearly, you could think u* located at a ghost node or considering a different derivative for the diffusive term along y in such a way to have the last cells close to the boundaries of half size and u* located exactly on the boundary. Then you have to construct the tangential derivative d phi/dt along the boundary.
Our discussions seem diverging... I appreciate you sending me your publications, but my initial question asks how to implement Kim and Moin's method of imposing their boundary conditions. I guess your last post implies that one-sided FD method is applicable?

Because I impose no-slip boundary conditions for the v velocity (red arrows), I don't have to include these boundary grid points in the solution process, right? I already know their values.

 November 16, 2021, 09:43 #12 Senior Member     Paolo Lampitella Join Date: Mar 2009 Location: Italy Posts: 2,168 Blog Entries: 29 Rep Power: 39 The Taylor series is used to eventually obtain the dp/dn bc for the pressure, which is needed on the boundary faces of the pressure cells. But the resulting dp/dn for a given face is, in fact, only dependent from the velocity known on that very face, the normal to the face velocity. Also, that very velocity (the normal to the face), also happens to appear in the source term for the neighbor cell in the pressure equation so, in the end, they cancel each other out.

November 16, 2021, 09:44
#13
Senior Member

Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,815
Rep Power: 73
Quote:
 Originally Posted by jollage Our discussions seem diverging... I appreciate you sending me your publications, but my initial question asks how to implement Kim and Moin's method of imposing their boundary conditions. I guess your last post implies that one-sided FD method is applicable? Because I impose no-slip boundary conditions for the v velocity (red arrows), I don't have to include these boundary grid points in the solution process, right? I already know their values.

No, you are wrong. The intermediate velocity on the wall is not the physical velocity! The formula proposed by Kim and Moin is valid everywhere and you have to use for both u* and v* along the walls.

November 16, 2021, 09:48
#14
Senior Member

Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,815
Rep Power: 73
Quote:
 Originally Posted by sbaffini The Taylor series is used to eventually obtain the dp/dn bc for the pressure, which is needed on the boundary faces of the pressure cells. But the resulting dp/dn for a given face is, in fact, only dependent from the velocity known on that very face, the normal to the face velocity. Also, that very velocity (the normal to the face), also happens to appear in the source term for the neighbor cell in the pressure equation so, in the end, they cancel each other out.

That's correct but the devil is in the details... using the implicit formulation (CN) requires to prescribe the Taylor expansion also for the tangential velocity and the tangential pressure gradient must be evaluated. And there ... is the devil. All that is in the approximation produces the so-called numerical boundary layer. And if the decomposition is not orthogonal, the error in the pressure enters into the tangential velocity and viceversa.

 Posting Rules You may not post new threads You may not post replies You may not post attachments You may not edit your posts BB code is On Smilies are On [IMG] code is On HTML code is OffTrackbacks are Off Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post CFXer CFX 4 July 16, 2020 23:44 gartz89 Fluent UDF and Scheme Programming 6 March 30, 2020 07:38 MichaelK CFX 12 September 1, 2016 05:15 ghobold Main CFD Forum 3 June 15, 2015 11:14 Attesz CFX 7 January 5, 2013 03:32

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