CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Causes of checkerboarding

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

Like Tree8Likes
  • 1 Post By sturgeon
  • 2 Post By mAlletto
  • 2 Post By mAlletto
  • 1 Post By mAlletto
  • 1 Post By mAlletto
  • 1 Post By mAlletto

Reply
 
LinkBack Thread Tools Display Modes
Old   April 16, 2018, 10:17
Default Causes of checkerboarding
  #1
Member
 
Join Date: Jun 2017
Posts: 58
Rep Power: 3
sturgeon is on a distinguished road
Hi all

I'm attempting to develop a new solver and keep running into checkerboarding issues. I've been looking online and trying to find the cause. In the wiki describing buoyantBoussenesqPisoFoam, it mentions:

Quote:
Most importantly, lines 17--20 set up the Poisson equation for the pressure correction and can be seen to be the face-located analog to Equation 27. This shows that pressure is being predicted at the cell centers using face-centered information. This procedure effectively applies Rhie-Chow interpolation which avoids the checkerboard pressure oscillations that can occur on a co-located grid
http://openfoamwiki.net/index.php/Bu...sinesqPisoFoam

However, I closely followed the methods described in the above link when creating the solver and used the same way of building the equations to apply Rhie-Chow interpolation, so I don't think that is it.

In this thread (How to avoid checkerboard?), a user mentions checkerboarding caused by using slip and noSlip boundary conditions, which I am using. However, his issue is solved by increasing corrector loops (which doesn't help me) and another user points out that this means his case just hadn't converged yet. So I'm not sure if his assessment that his boundary conditions were causing checkerboarding or not is accurate.

In another thread (Checkerboarding with interFoam) a user mentions from literature that there's a minimum courrant number allowable to avoid checkerboarding. I couldn't find the literature in question but I tried messing around with cell size and timestep to remove checkerboarding, but unsuccessfully. Am I correct in understanding that there's in fact a minimum allowable courrant number? And is this the absolute minimum for any cell in the entire domain, or an average?

My case is a very simple one (2D, left inlet, right fixed pressure outlet, ceiling and floor are slip and noslip respectively) and my solver is a modification of buoyantBoussenesqPimpleFoam. I've disabled my modifications and it simply behaves like bBPF so I am fairly certain my coding isn't the issue. (Running the same case with bBPF produces identical results.)



Above is the vertical velocity profile at the inlet. There should be nothing really affecting the vertical velocity at all.

Now obviously I don't expect anyone to look through my code and case files to figure out why this is occurring - I was hoping someone could give me some insight as to why this kind of problem might be occurring, or expand upon the information I've found already

Cheers

EDIT: Also, I spent a lot of time messing around with the schemes but this also never seemed to make much difference. Courrant number was always kept well below 1

Second edit:

I found these threads: Oscillatory inlet velocity and Mesh problem/ coarse OK - fine not OK

The issues seem to be very similar. The fixedMean velocity as suggested in the first thread didn't make any difference but I'll attempt the other possible fixes related to the issue. If anyone could provide any insight into any of this,I would be grateful

Third edit:

I tried the method of having a patch of slip adjacent to the inlet, but this just caused the strange vertical velocities to be pushed further down the domain. I also used laminar instead of kEpsilon for turbulence and the vertical velocity anomaly in the corner was lessened by several orders of magnitude, but still present.

Last edited by sturgeon; April 16, 2018 at 15:50.
sturgeon is offline   Reply With Quote

Old   November 26, 2018, 05:17
Default Checkerboard
  #2
New Member
 
Thomas Flint
Join Date: Jan 2016
Posts: 28
Rep Power: 4
tom_flint2012 is on a distinguished road
Hi,

Iím dealing woth a similar issue and found some success by taking the courant number right down to 0.01. Iím dealing with state change and this issue presents itself as my phases transition so slightly different to your case.
Did you have any other success getting rid of the checkerboard?

All the best,

Tom
tom_flint2012 is offline   Reply With Quote

Old   November 29, 2018, 12:54
Default
  #3
Member
 
Join Date: Jun 2017
Posts: 58
Rep Power: 3
sturgeon is on a distinguished road
Quote:
Originally Posted by tom_flint2012 View Post
Hi,

Iím dealing woth a similar issue and found some success by taking the courant number right down to 0.01. Iím dealing with state change and this issue presents itself as my phases transition so slightly different to your case.
Did you have any other success getting rid of the checkerboard?

All the best,

Tom
Hi Tom

No success really. Put this whole thing on the back burner because it was going nowhere. Getting back into it now. I'll post here/PM you if I have any success

Cheers
sturgeon
tom_flint2012 likes this.
sturgeon is offline   Reply With Quote

Old   November 30, 2018, 12:35
Default
  #4
Senior Member
 
Michael Alletto
Join Date: Jun 2018
Posts: 133
Rep Power: 2
mAlletto is on a distinguished road
Did you try to have a bit finer grid in streamwise direction close to the inlet boundary. Usually this kind of oscillation come from second order discretization and the truncation error leads to oscillation.

Furthermore if you apply a block profile at the inlet this is not consistent with the slip boundary conditions. (it's only a guess you apply a block profile since you did not post the boundary conditions).

A block profile in combination with a no slip boundary condition leads high velocity gradients in stream wise direction close to the ground which should be resolved adequately with a finer grid in stream wise direction
tom_flint2012 and sturgeon like this.
mAlletto is offline   Reply With Quote

Old   November 30, 2018, 12:50
Default
  #5
Member
 
Join Date: Jun 2017
Posts: 58
Rep Power: 3
sturgeon is on a distinguished road
Quote:
Originally Posted by mAlletto View Post
Did you try to have a bit finer grid in streamwise direction close to the inlet boundary. Usually this kind of oscillation come from second order discretization and the truncation error leads to oscillation.

Furthermore if you apply a block profile at the inlet this is not consistent with the slip boundary conditions. (it's only a guess you apply a block profile since you did not post the boundary conditions).

A block profile in combination with a no slip boundary condition leads high velocity gradients in stream wise direction close to the ground which should be resolved adequately with a finer grid in stream wise direction
Thanks for the reply. I will see if this resolves my issue. If by block profile you mean fixedValue then yes that is what I used.

For clarification, when you say a block profile is not consistent with slip boundary... do you mean it's not consistent with slip or no slip? Because intuitively I feel like the block would be consistent with slip but not no slip. Isn't slip essentially symmetry with no wall effects, so the block fixedValue boundary would be consistent?

Cheers
sturgeon
sturgeon is offline   Reply With Quote

Old   November 30, 2018, 13:37
Default
  #6
Senior Member
 
Michael Alletto
Join Date: Jun 2018
Posts: 133
Rep Power: 2
mAlletto is on a distinguished road
Sorry I mean that a constant velocity profile is not consistent with a no slip boundary condition
tom_flint2012 and sturgeon like this.
mAlletto is offline   Reply With Quote

Old   December 4, 2018, 08:51
Default
  #7
Member
 
Join Date: Jun 2017
Posts: 58
Rep Power: 3
sturgeon is on a distinguished road
Quote:
Originally Posted by mAlletto View Post
Sorry I mean that a constant velocity profile is not consistent with a no slip boundary condition
Thanks for the response. Messing about with the refinements you suggested seems to improve the case, so I'll see if it's good enough to work with my actual application.

I am still quite confused though - I was building my case based on the tutorials, specifically circuitBoardCooling. In the results for that tutorial, you can see there are perturbations in the left hand corners, where the inlet meets the noSlip boundaries. But that case doesn't seem to require any special treatment or non-uniform grids to avoid the checkerboarding I experience. Why is this?

Cheers
sturgeon
sturgeon is offline   Reply With Quote

Old   December 4, 2018, 16:01
Default
  #8
Senior Member
 
Michael Alletto
Join Date: Jun 2018
Posts: 133
Rep Power: 2
mAlletto is on a distinguished road
What Kind of boundary conditions do you apply for the Temperature?
sturgeon likes this.
mAlletto is offline   Reply With Quote

Old   December 4, 2018, 16:23
Default
  #9
Member
 
Join Date: Jun 2017
Posts: 58
Rep Power: 3
sturgeon is on a distinguished road
Quote:
Originally Posted by mAlletto View Post
What Kind of boundary conditions do you apply for the Temperature?
zeroGradient for the floor and ceiling, fixed value for inlet, inletoutlet for the outlet.

EDIT: I've also tried using meanValue for the velocity inlet and pressure outlet, not sure if I'm really using them right since I can't find much online or anything in the tutorials. Most of the checkerboarding seems to vanish except in the extreme corners of the inlet, but the horizontal velocity isn't consistent down the horizontal axis. Along the middle it drops off by about 5%, and along the noSlip wall it varies quite wildly, so I still don't have this set up right.

Last edited by sturgeon; December 4, 2018 at 19:27.
sturgeon is offline   Reply With Quote

Old   December 5, 2018, 13:13
Default
  #10
Senior Member
 
Michael Alletto
Join Date: Jun 2018
Posts: 133
Rep Power: 2
mAlletto is on a distinguished road
Ok the check board velocity is quite normal in the corner I think.

Let's think about a constant inlet profile. This profile is not consistent with the no slip boundary condition since one has to have zero velocity at the wall.

This leads to a deceleration of the flow in stream wise direction in the first cell after the boundary. Due to the continuity equation to the flow is imposed a velocity normal to the wall at the second cell away of the wall. This together with the sharp gradient in the pressure (the truncation error of the rhiew and Chow interpolation is proportional to the 4th derivative of the pressure) leads to an oscillating velocity close to the corner.

The reason of the retardation of the flow away from the wall is not clear to me. At least the average velocity should be equal every where because of mass conservation.
sturgeon likes this.
mAlletto is offline   Reply With Quote

Old   December 5, 2018, 14:13
Default
  #11
Member
 
Join Date: Jun 2017
Posts: 58
Rep Power: 3
sturgeon is on a distinguished road
Quote:
Originally Posted by mAlletto View Post
Ok the check board velocity is quite normal in the corner I think.

Let's think about a constant inlet profile. This profile is not consistent with the no slip boundary condition since one has to have zero velocity at the wall.

This leads to a deceleration of the flow in stream wise direction in the first cell after the boundary. Due to the continuity equation to the flow is imposed a velocity normal to the wall at the second cell away of the wall. This together with the sharp gradient in the pressure (the truncation error of the rhiew and Chow interpolation is proportional to the 4th derivative of the pressure) leads to an oscillating velocity close to the corner.

The reason of the retardation of the flow away from the wall is not clear to me. At least the average velocity should be equal every where because of mass conservation.

Thank you for the information. Like I said, using meanValue for the velocity inlet seems to improve things a little but the result doesn't seem physical. Do you have any experience in using meanValue?

Also, are you saying that in theory, fixedValue for the inlet should be fine, as long as the mesh is sufficiently refined around this area?

EDIT: I'm actually just doing these runs in vanilla buoyantBoussinesqPimpleFoam now, so my custom solver is definitely not the issue.
sturgeon is offline   Reply With Quote

Old   December 6, 2018, 04:53
Default
  #12
Senior Member
 
Michael Alletto
Join Date: Jun 2018
Posts: 133
Rep Power: 2
mAlletto is on a distinguished road
I do not have any experience with meanValue. I think using fixedValue at the inlet is fine enough if your zone of interest is enough away from the inlet in order that the flow can adjust and became fully developed.

The best inlet condition is the one which perfectly reproduces the actual condition at the point very you artificially cut the domain.

Using fixedValue is for sure not a boundary condition like this. However if your boundary is far away from the zone of interest, the flow can adjust to the geometry and wall boundary conditions applied and you get realistic condition at the zone you are interested in.
sturgeon likes this.
mAlletto is offline   Reply With Quote

Old   December 6, 2018, 04:55
Default
  #13
Member
 
Join Date: Jun 2017
Posts: 58
Rep Power: 3
sturgeon is on a distinguished road
Quote:
Originally Posted by mAlletto View Post
I do not have any experience with meanValue. I think using fixedValue at the inlet is fine enough if your zone of interest is enough away from the inlet in order that the flow can adjust and became fully developed.

The best inlet condition is the one which perfectly reproduces the actual condition at the point very you artificially cut the domain.

Using fixedValue is for sure not a boundary condition like this. However if your boundary is far away from the zone of interest, the flow can adjust to the geometry and wall boundary conditions applied and you get realistic condition at the zone you are interested in.
Okay, thanks for your advice, I will continue to try and figure out what else is causing the problem.

Cheers
sturgeon
sturgeon is offline   Reply With Quote

Reply

Thread Tools
Display Modes

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
adjointShapeOptimizationFoam checkerboarding inlet sylvester OpenFOAM Running, Solving & CFD 5 May 28, 2018 11:36
Checkerboarding with interFoam fs82 OpenFOAM Running, Solving & CFD 1 July 15, 2015 08:19
Checkerboarding stuart23 Main CFD Forum 4 October 16, 2012 10:36
Checkerboarding problem in LES Matteo85 OpenFOAM Running, Solving & CFD 3 September 15, 2012 23:15
Checkerboarding problem in LES Matteo85 OpenFOAM Running, Solving & CFD 0 June 9, 2009 10:47


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