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

Do you really need image or ghost cells ?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 8, 2015, 15:53
Default Do you really need image or ghost cells ?
  #1
New Member
 
sam
Join Date: Jan 2011
Posts: 20
Rep Power: 15
mczero57 is on a distinguished road
If you are coding up a 2D finite volume Euler solver on a structured grid, image or phantom or ghost or aux cells are often used to apply the boundary conditions. My question is - Is this absolutely necessary ? Why not just go to the boundary faces and set the value of the normal flux on that boundary there.

One reason I can think of is perhaps you want to compute the flux using a Riemann solver even on the boundary faces. If this is so, then you need some data on the other side and hence ghost cells. But, do you have to use a Riemann solver even on the boundary faces ? why ?

Any questions/comments ?
Thanks

M
mczero57 is offline   Reply With Quote

Old   July 8, 2015, 17:15
Default
  #2
Senior Member
 
Filippo Maria Denaro
Join Date: Jul 2010
Posts: 6,882
Rep Power: 73
FMDenaro has a spectacular aura aboutFMDenaro has a spectacular aura aboutFMDenaro has a spectacular aura about
Quote:
Originally Posted by mczero57 View Post
If you are coding up a 2D finite volume Euler solver on a structured grid, image or phantom or ghost or aux cells are often used to apply the boundary conditions. My question is - Is this absolutely necessary ? Why not just go to the boundary faces and set the value of the normal flux on that boundary there.

One reason I can think of is perhaps you want to compute the flux using a Riemann solver even on the boundary faces. If this is so, then you need some data on the other side and hence ghost cells. But, do you have to use a Riemann solver even on the boundary faces ? why ?

Any questions/comments ?
Thanks

M

indeed FV requires to prescribe the flux at the face of a boundary... however, ghost cell are nothing else than extrapolation formula therefore you get similar results with backward/forward formula at the boundary.

However, for Euler you have no derivative to specify at the boundary
FMDenaro is offline   Reply With Quote

Old   July 8, 2015, 17:56
Default
  #3
Member
 
Mianzhi Wang
Join Date: Jan 2015
Location: Columbus, IN
Posts: 34
Rep Power: 11
wangmianzhi is on a distinguished road
Hi,
I've been through the same debate in my mind when I was inplementing this (http://www.cfd-online.com/Forums/mai...uler-code.html)

It turned out that applying Riemann solver on boundary makes it very easy to apply BCs of all kinds.
The characteristics are just taken care of automatically by the Riemann solver.

What I did was following the BC strategies of Fluent (https://www.sharcnet.ca/Software/Flu...ug/node203.htm) and calculating the ghost cell state accordingly.
Then my Riemann solver would just work it out.

For data storage, in my case all BC related data and "ghost" state are on "facet", instead of in actual "ghost cells".
And the "facets" are included in the neighbour table, so that my Riemann solver can treat it just like a cell.
I'm not sure what is the simplest approach in your structured project, but either way should work.

Quote:
Originally Posted by mczero57 View Post
If you are coding up a 2D finite volume Euler solver on a structured grid, image or phantom or ghost or aux cells are often used to apply the boundary conditions. My question is - Is this absolutely necessary ? Why not just go to the boundary faces and set the value of the normal flux on that boundary there.

One reason I can think of is perhaps you want to compute the flux using a Riemann solver even on the boundary faces. If this is so, then you need some data on the other side and hence ghost cells. But, do you have to use a Riemann solver even on the boundary faces ? why ?

Any questions/comments ?
Thanks

M
wangmianzhi is offline   Reply With Quote

Old   July 9, 2015, 04:47
Default
  #4
Senior Member
 
sbaffini's Avatar
 
Paolo Lampitella
Join Date: Mar 2009
Location: Italy
Posts: 2,192
Blog Entries: 29
Rep Power: 39
sbaffini will become famous soon enoughsbaffini will become famous soon enough
Send a message via Skype™ to sbaffini
I don't know how much debate there is on this topic but, in my opinion, there are serious advantages in NOT using ghost cells:

1) Ghost cells require extrapolation. The state in the extrapolated cells might require some trick to keep the thermodynamics consistent (if using it).

2) Most b.c. do not require any Riemann problem to be solved (e.g., walls). You just know the fluxes on the faces.

3) Storage for ghost cells can explode more easily than you think, especially if your scheme requires 2 cells per side (for a given face). Imagine a wall resolved viscous simulation; having ghost cells means having two more cells in wall normal direction without any special advantage.
sbaffini is offline   Reply With Quote

Old   July 10, 2015, 17:24
Default
  #5
New Member
 
alma_mech's Avatar
 
Alma
Join Date: Feb 2015
Location: Iran
Posts: 1
Rep Power: 0
alma_mech is on a distinguished road
hi all




I am a beginner at CFD
And I study on the 1 quasi of eular equation with shock (chapter of 12 of computational of fluid dynamics hoffmann)


Who has worked previously on this topic?
Please Help me
Thank you
.
.
.
and i
Apologize from starter of the thread that I asked my question here. Sorry.
alma_mech is offline   Reply With Quote

Reply

Tags
boundary conditions, ghost cells, riemann solvers


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
Foam::error::PrintStack almir OpenFOAM Running, Solving & CFD 92 May 21, 2024 08:56
snappyhexmesh remove blockmesh geometry philipp1 OpenFOAM Running, Solving & CFD 2 December 12, 2014 11:58
[snappyHexMesh] Layers:problem with curvature giulio.topazio OpenFOAM Meshing & Mesh Conversion 10 August 22, 2012 10:03
[ICEM] error analysis despaired student ANSYS Meshing & Geometry 7 June 27, 2012 12:57
Highly Skewed Cells chrisoturner FLUENT 7 July 22, 2010 07:43


All times are GMT -4. The time now is 22:13.