CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > General Forums > Main CFD Forum

How to apply zero gradient pressure BC on tilted grid?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 15, 2023, 09:04
Smile How to apply zero gradient pressure BC on tilted grid?
  #1
New Member
 
Yujoo KANG
Join Date: Jul 2020
Location: South Korea
Posts: 2
Rep Power: 0
yujoo KANG is on a distinguished road
Dear all,
I'm glad to post my fist question.

I'm developing my own finite difference method (FDM) code to solve compressible NS equations.
My simulation is unstable because of the boundary condition at the wall.
I use the isothermal-nonslip boundary condition.
so, uvw is zero and T is constant and P should satisfy dP/dn=0 and rho is from P=rho*R*T.

The problem is dP/dn=0 since the grid points and wall is not orthogonal. Here is an example of my mesh. slash is grid point (sorry.. real picture doesn't appear....)

........./
......../
......./
....../
...../
-------------
wall

If the points are orthogonal to the wall, I can directly use the equation P0=P1 in 1st order or P0=2/3(2*P1-1/2*P2) in 2nd order. However, I don't have good idea how to apply dP/dn=0 in tilted grid. If you have a good idea, please help me.

Thank you for reading this.
yujoo KANG is offline   Reply With Quote

Old   March 15, 2023, 10:09
Default
  #2
Senior Member
 
sbaffini's Avatar
 
Paolo Lampitella
Join Date: Mar 2009
Location: Italy
Posts: 2,190
Blog Entries: 29
Rep Power: 39
sbaffini will become famous soon enoughsbaffini will become famous soon enough
Send a message via Skype™ to sbaffini
Your wall face pressure should be equal to the pressure in the point that is the projection of the first cell point on the normal passing trough the face (center). That value is the first cell center value + a gradient correction. The former is typically treated implicitly and the latter explicitly
However, at first order, P1 is just as good and no gradient term should be needed. Are you having troubles (besides accuracy ones) for the first order treatment?
sbaffini is offline   Reply With Quote

Old   March 15, 2023, 10:29
Default
  #3
New Member
 
Yujoo KANG
Join Date: Jul 2020
Location: South Korea
Posts: 2
Rep Power: 0
yujoo KANG is on a distinguished road
Quote:
Originally Posted by sbaffini View Post
Your wall face pressure should be equal to the pressure in the point that is the projection of the first cell point on the normal passing trough the face (center). That value is the first cell center value + a gradient correction. The former is typically treated implicitly and the latter explicitly
However, at first order, P1 is just as good and no gradient term should be needed. Are you having troubles (besides accuracy ones) for the first order treatment?
Thank u for your reply!

For FDM simulation, I use 6th-order discretization.
When I apply the P0=P1, there's a big oscillation from the wall that makes the simulation very very unstable. So, I usually used 3rd-order dP/dn=0 in the orthogonal grid. But recently I use non-orthogonal grid and P0=P1 is not good solution for my simulation...

Can I get more information about the gradient correction?

Thank u again!
yujoo KANG is offline   Reply With Quote

Old   March 15, 2023, 10:38
Default
  #4
Senior Member
 
sbaffini's Avatar
 
Paolo Lampitella
Join Date: Mar 2009
Location: Italy
Posts: 2,190
Blog Entries: 29
Rep Power: 39
sbaffini will become famous soon enoughsbaffini will become famous soon enough
Send a message via Skype™ to sbaffini
Oh, ok, I don't think then the gradient solution is going to help here. However, it is based on a taylor series expansion of the pressure in the point along the normal starting from 1, something used in 2nd order unstructured codes. If you know the gradient in 1 you can extrapolate the pressure at 2nd order.

I have no experience with high order codes on non orthogonal meshes, as I only ever heatd about those working in computational space with orthogonal grids. Maybe, you can use an interpolation of your choice and rewrite that as P = P1 + correction, treating the correction explicitly. But there are certainly people who would know better here for your specific case
sbaffini is offline   Reply With Quote

Old   March 15, 2023, 14:53
Default
  #5
Senior Member
 
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,849
Rep Power: 73
FMDenaro has a spectacular aura aboutFMDenaro has a spectacular aura aboutFMDenaro has a spectacular aura about
Quote:
Originally Posted by yujoo KANG View Post
Dear all,
I'm glad to post my fist question.

I'm developing my own finite difference method (FDM) code to solve compressible NS equations.
My simulation is unstable because of the boundary condition at the wall.
I use the isothermal-nonslip boundary condition.
so, uvw is zero and T is constant and P should satisfy dP/dn=0 and rho is from P=rho*R*T.

The problem is dP/dn=0 since the grid points and wall is not orthogonal. Here is an example of my mesh. slash is grid point (sorry.. real picture doesn't appear....)

........./
......../
......./
....../
...../
-------------
wall

If the points are orthogonal to the wall, I can directly use the equation P0=P1 in 1st order or P0=2/3(2*P1-1/2*P2) in 2nd order. However, I don't have good idea how to apply dP/dn=0 in tilted grid. If you have a good idea, please help me.

Thank you for reading this.



And why are you assuming dP/dn=0? This is a boundary layer condition that requires a very low viscosity value to be quite approximate. Actually, the normal derivative of the pressure is balanced by viscous term.


However, you can build the normal derivative from nx*dp/dx+ny*dp/dy and approximate the derivatives at a certain accuracy order using interior points.
FMDenaro is offline   Reply With Quote

Reply

Tags
boudary condition, cfd - post, finite difference, pressre


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 Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Intuition for why flow follows convex surfaces lopp Main CFD Forum 47 February 1, 2022 14:14
pimpleFoam in OF1612 shows same time step twice in log file shang OpenFOAM Bugs 10 January 24, 2018 11:43
pisoFOAM (LES) - internal pipe flow - convergence gu1 OpenFOAM Running, Solving & CFD 0 January 11, 2018 17:39
static vs. total pressure auf dem feld FLUENT 17 February 26, 2016 14:04
vortex cause pressure gradient or pressure gradient induce vortex? fruitkiwi Main CFD Forum 4 June 12, 2012 02:12


All times are GMT -4. The time now is 05:30.