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

Understanding the cyclic boundary condition

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

Like Tree2Likes
  • 1 Post By snak
  • 1 Post By Ardali

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 13, 2014, 10:54
Post Understanding the cyclic boundary condition
  #1
Member
 
Vincent Leroy
Join Date: Jul 2012
Location: Rhode-Saint-Genèse, Belgium
Posts: 43
Rep Power: 14
leroyv is on a distinguished road
Dear foamers,

I need to solve problems with cyclic BCs 'all around the place'. To be clearer, this is the geometry I am considering:
https://www.dropbox.com/s/amuzikceam...nder_array.png

On this screenshot, the colouring is the velocity (U) magnitude, U being obtained using the simpleFoam solver and a uniform inlet BC on the x = 0 face. What I want to do is simply simulate the flow in the (6,4) cell using periodic boundary conditions:
https://www.dropbox.com/s/v5nz4mvx6user06/6-4_cell.png

Firstly, let's have a look at what we want to reproduce. Here are the velocity magnitude and orientation in the (6,4) cell (let's call this the reference problem):
https://www.dropbox.com/s/8eivt2e1ai...eference_U.png
This velocity field seems periodic. If we subtract a periodic field from this one, we should get another periodic field, maybe better as an evidence. So we do that and plot the so-called deviation field, UTilde, obtained by subtracting the volume average of U (which is constant over the cell) from U:

UTilde = U - UAverage

Here is what we get:
https://www.dropbox.com/s/8gnccd1pzy...nce_UTilde.png
This deviation field is periodic 'x-wise' and 'y-wise'.

I tried to simulate the flow in the (6,4) cell using the simpleFoam solver (though if might not be the best, AFAIK; anyway, this is not the worst problem here). I therefore simply applied cyclic patches at the boundaries of the cell. Although this insufficiently constraints the problem, the SIMPLE algorithm converges to a solution which only depends on the initial condition, yielding the following velocity field:
https://www.dropbox.com/s/rufn5k53mf...periodic_U.png

Given that image, we can doubt that this field is periodic. The deviation field gives a clearer proof:
https://www.dropbox.com/s/nf81rnnj4h...dic_UTilde.png
UTilde is not periodic, while it should be.

So here is my question: Is there any reason why the periodic BC wouldn't be satisfied in the cyclic problem? Did I do something wrong?

The associated OpenFOAM cases come attached. Screenshot gallery:
https://www.dropbox.com/sh/hmq2qx6jcvjc6lx/LFKCB1X32b
Attached Files
File Type: zip multiCylinder_simpleFoam.zip (75.5 KB, 31 views)
File Type: zip singleCylinderPeriodic_simpleFoam.zip (63.3 KB, 53 views)

Last edited by leroyv; February 13, 2014 at 11:05. Reason: Corrected bad hyperlinks
leroyv is offline   Reply With Quote

Old   February 13, 2014, 13:08
Post Update
  #2
Member
 
Vincent Leroy
Join Date: Jul 2012
Location: Rhode-Saint-Genèse, Belgium
Posts: 43
Rep Power: 14
leroyv is on a distinguished road
I ran an additional simulation with a correctly constrained problem, replacing the inlet and outlet cyclic patches with regular inlet and outlet patches.

Inlet: zeroGradient pressure, fixedValue uniform velocity
Outlet: fixedValue uniform pressure, zeroGradient velocity
https://www.dropbox.com/s/38s9ap0ev5...periodic_U.png

The 'y-wise' periodicity is not satisfied either.

Last edited by leroyv; February 13, 2014 at 13:18. Reason: Added screenshot
leroyv is offline   Reply With Quote

Old   February 14, 2014, 06:30
Default
  #3
Senior Member
 
shinji nakagawa
Join Date: Mar 2009
Location: Japan
Posts: 113
Blog Entries: 1
Rep Power: 18
snak is on a distinguished road
hi,

something in cyclic patch in your original case is wrong.
checkMesh shows some error.

Using createPatch fixed this problem.
a modified case with createPatchDict and modified Allrun is here,
singleCylinderPeriodic_simpleFoam_createPatch.zip

Periodic fields is obtained with this case. tested with OF222.


Quote:
Originally Posted by leroyv View Post
I ran an additional simulation with a correctly constrained problem, replacing the inlet and outlet cyclic patches with regular inlet and outlet patches.

Inlet: zeroGradient pressure, fixedValue uniform velocity
Outlet: fixedValue uniform pressure, zeroGradient velocity
https://www.dropbox.com/s/38s9ap0ev5...periodic_U.png

The 'y-wise' periodicity is not satisfied either.
leroyv likes this.
snak is offline   Reply With Quote

Old   February 14, 2014, 13:38
Smile Problem solved
  #4
Member
 
Vincent Leroy
Join Date: Jul 2012
Location: Rhode-Saint-Genèse, Belgium
Posts: 43
Rep Power: 14
leroyv is on a distinguished road
Thank you very much! It seems like patch orientation is much more of a big deal than I expected.

Quote:
Originally Posted by snak View Post
hi,

something in cyclic patch in your original case is wrong.
checkMesh shows some error.

Using createPatch fixed this problem.
a modified case with createPatchDict and modified Allrun is here,
Attachment 28671

Periodic fields is obtained with this case. tested with OF222.
leroyv is offline   Reply With Quote

Old   March 20, 2014, 10:01
Default
  #5
Member
 
Vincent Leroy
Join Date: Jul 2012
Location: Rhode-Saint-Genèse, Belgium
Posts: 43
Rep Power: 14
leroyv is on a distinguished road
Dear foamers,

I have an additional question about the cyclic boundary condition: what does it actually do? Does it ensure equality of fields and derivatives at the associated boundaries? Or does it only ensure equality of fields?
leroyv is offline   Reply With Quote

Old   May 29, 2020, 21:55
Default
  #6
Senior Member
 
Arijit Saha
Join Date: Feb 2019
Location: Singapore
Posts: 132
Rep Power: 7
ari003 is on a distinguished road
Quote:
Originally Posted by leroyv View Post
Dear foamers,

I have an additional question about the cyclic boundary condition: what does it actually do? Does it ensure equality of fields and derivatives at the associated boundaries? Or does it only ensure equality of fields?
Hi, I was also searching for some doc which contains the details of the cyclic bc but unfortunately there isn't enough. Did you get the answer to this? If so are you willing to share your understanding here?
ari003 is offline   Reply With Quote

Old   May 30, 2020, 00:15
Default
  #7
Member
 
Ardalan
Join Date: Jul 2012
Location: Atlanta, USA
Posts: 77
Rep Power: 14
Ardali is on a distinguished road
That is a simple idea. It recycle the quantity between two patches or planes! What is complex with the b.L.
Ardali is offline   Reply With Quote

Old   May 30, 2020, 00:24
Default
  #8
Senior Member
 
Arijit Saha
Join Date: Feb 2019
Location: Singapore
Posts: 132
Rep Power: 7
ari003 is on a distinguished road
Quote:
Originally Posted by Ardali View Post
That is a simple idea. It recycle the quantity between two patches or planes! What is complex with the b.L.
Thanks for responding to my concern. Can you please elaborate with an example if possible?
ari003 is offline   Reply With Quote

Old   May 30, 2020, 00:27
Default
  #9
Member
 
Ardalan
Join Date: Jul 2012
Location: Atlanta, USA
Posts: 77
Rep Power: 14
Ardali is on a distinguished road
yes, sure. For example the velocity on the outlet will be exactly mapped to the inlet. In other word, the length of the domain will be assumed infinity. You can see the channel395 tutorial for more details.
SHANRU likes this.
Ardali is offline   Reply With Quote

Old   May 30, 2020, 20:31
Default
  #10
Senior Member
 
Arijit Saha
Join Date: Feb 2019
Location: Singapore
Posts: 132
Rep Power: 7
ari003 is on a distinguished road
Yaa I understood that in cyclic boundary condition the patches have same physical behavior but specifically for this channel 395 case why do we need cyclic bc and why not some other kind of boundary condition?
ari003 is offline   Reply With Quote

Old   May 31, 2020, 10:05
Default
  #11
Member
 
Ardalan
Join Date: Jul 2012
Location: Atlanta, USA
Posts: 77
Rep Power: 14
Ardali is on a distinguished road
Because you do not have entrance length in the channel. you want to have fully developed flow inside the channel. As I said before, you making the length infinity when you use cyclic bc.
Ardali is offline   Reply With Quote

Reply

Tags
cyclic bc, periodic bc, simplefoam

Thread Tools Search this Thread
Search this Thread:

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Cyclic boundary condition for dnsFoam antoinep76 OpenFOAM Programming & Development 7 March 18, 2013 05:54
cyclic boundary condition xxxx OpenFOAM Pre-Processing 2 March 16, 2013 03:25
cyclic boundary condition flotran OpenFOAM 3 December 19, 2011 21:13
Cyclic jump boundary condition hjasak OpenFOAM Running, Solving & CFD 10 April 16, 2010 16:35
RPM in Wind Turbine Pankaj CFX 9 November 23, 2009 05:05


All times are GMT -4. The time now is 12:40.