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

cyclic boundary condition

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

Like Tree4Likes

Reply
 
LinkBack Thread Tools Display Modes
Old   March 10, 2011, 12:38
Default cyclic boundary condition
  #1
New Member
 
huxiaoxia
Join Date: Oct 2010
Posts: 18
Rep Power: 6
huxiaoxia is on a distinguished road
Hi,

I want to simulate the thin liquid film flow on the substrate and I need the periodic boundary condition for left, right, front and back sides of the domain. However, only the front and back sides work. When I put the cyclic BC on left and right, it shows the error "Attempt to cast type wall to type lduInterface". Does anyone know what's the problem and how to solve it?

Thanks.
huxiaoxia is offline   Reply With Quote

Old   March 10, 2011, 12:49
Default
  #2
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Rotterdam, The Netherlands
Posts: 1,594
Rep Power: 24
ngj will become famous soon enoughngj will become famous soon enough
Hi

This error shows up, because there is a mismatch between the boundary condition in your variables, i.e. type cyclic; , and the type of boundary condition in your boundary file in <case>/constant/polyMesh/boundary. In the latter, the boundary type is set to wall, but it should be set to cyclic.

I have experienced problems in changing boundary type in my blockMeshDict and running blockMesh, however, this does not always change the boundary file.

Best regards,

Niels
large_eddy likes this.
ngj is offline   Reply With Quote

Old   March 10, 2011, 14:12
Default cyclic BC
  #3
New Member
 
huxiaoxia
Join Date: Oct 2010
Posts: 18
Rep Power: 6
huxiaoxia is on a distinguished road
Thanks a lot.
huxiaoxia is offline   Reply With Quote

Old   March 14, 2011, 15:18
Default Cyclic BC
  #4
Member
 
longamon's Avatar
 
David Aljure
Join Date: Mar 2011
Location: CTTC Universidad Politécnica de Catalunya. Spain
Posts: 38
Rep Power: 6
longamon is on a distinguished road
Thanks for this, I was all afternoon trying to understand why the paraFOAM exited when I tryed to view the initial conditions (very knew to OF).
longamon is offline   Reply With Quote

Old   April 13, 2011, 06:34
Default
  #5
New Member
 
HuyHoang
Join Date: Mar 2011
Posts: 7
Rep Power: 6
bongbongxanh is on a distinguished road
Quote:
Originally Posted by huxiaoxia View Post
Hi,

I want to simulate the thin liquid film flow on the substrate and I need the periodic boundary condition for left, right, front and back sides of the domain. However, only the front and back sides work. When I put the cyclic BC on left and right, it shows the error "Attempt to cast type wall to type lduInterface". Does anyone know what's the problem and how to solve it?

Thanks.
Dear huxiaoxia,

Your subject happens to be my graduating thesis. I'm trying to set boundary condition for the case. Unfortunately, i don't know how to use the cyclic boundary condition, i can't set the pressure drop on the opposite cyclic planes like i did in fluent . Can you tell me how you set up your case, especially the cyclic boundary condition (i.e the pressure drop, the mass flow rate ). I use the solver InterDyMFoam. I investigates the openFoam - 1.6-ext example, the channel395 but it's seems helpless until now.
I'm very grateful if you can help. Thanks in advance

Hduy
bongbongxanh is offline   Reply With Quote

Old   April 13, 2011, 07:37
Default
  #6
Senior Member
 
maddalena's Avatar
 
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 12
maddalena is on a distinguished road
Quote:
Originally Posted by bongbongxanh View Post
Dear huxiaoxia,

Your subject happens to be my graduating thesis. I'm trying to set boundary condition for the case. Unfortunately, i don't know how to use the cyclic boundary condition, i can't set the pressure drop on the opposite cyclic planes like i did in fluent . Can you tell me how you set up your case, especially the cyclic boundary condition (i.e the pressure drop, the mass flow rate ). I use the solver InterDyMFoam. I investigates the openFoam - 1.6-ext example, the channel395 but it's seems helpless until now.
I'm very grateful if you can help. Thanks in advance

Hduy
If you want to fix a pressure drop between the two sides of a patch, than you should use a fan bc. Search in the forum for it.

mad
bongbongxanh and mgg like this.
maddalena is offline   Reply With Quote

Old   April 13, 2011, 22:16
Default
  #7
New Member
 
HuyHoang
Join Date: Mar 2011
Posts: 7
Rep Power: 6
bongbongxanh is on a distinguished road
thank Maddalena
your comment have just saved my day :d

Btw, last night i had a look at channel foam in the tutorial of OpenFoam. It use the pressure drop at two opposite cyclic planes to create a gradient pressure. I just have a thought to implement this method in the interDyMFoam solver. My work have just begun, do you have any recommend ?
bongbongxanh is offline   Reply With Quote

Old   April 14, 2011, 02:30
Default
  #8
Senior Member
 
maddalena's Avatar
 
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 12
maddalena is on a distinguished road
Quote:
Originally Posted by bongbongxanh View Post
thank Maddalena
your comment have just saved my day :d

Btw, last night i had a look at channel foam in the tutorial of OpenFoam. It use the pressure drop at two opposite cyclic planes to create a gradient pressure. I just have a thought to implement this method in the interDyMFoam solver. My work have just begun, do you have any recommend ?
Well, fan is a BC, thus you can use it with every solver you like without modification! I use it in every of my simpleFoam cases, but also if using chtMultiRegionFoam!


mad
maddalena is offline   Reply With Quote

Old   April 14, 2011, 22:03
Default
  #9
New Member
 
HuyHoang
Join Date: Mar 2011
Posts: 7
Rep Power: 6
bongbongxanh is on a distinguished road
Hi maddelena,
Have you ever tried the fan bc on the 3d case. I have some unexplainable result in simulation
bongbongxanh is offline   Reply With Quote

Old   April 15, 2011, 03:09
Default
  #10
Senior Member
 
maddalena's Avatar
 
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 12
maddalena is on a distinguished road
Quote:
Originally Posted by bongbongxanh View Post
Have you ever tried the fan bc on the 3d case.
Well, I do it in almost every of my simulations...
There are some issues with the fan bc you must take care of. There are some thread I have written about the subject, please search in the forum for them...


mad
maddalena is offline   Reply With Quote

Old   April 20, 2011, 10:30
Default cyclic BC
  #11
New Member
 
huxiaoxia
Join Date: Oct 2010
Posts: 18
Rep Power: 6
huxiaoxia is on a distinguished road
Dear HuyHoang:

Sorry to reply you late. First of all, in constant/polyMesh/blockMeshDic, you have to define the cyclic boundary, e.g
cyclic back
(
(0 2 3 1)
(6 7 9 8)
)
Then , when you define all the initial or boundary conditions under the folder 0, simply use the type cyclic. e.g
back
{
type cyclic;
}

Is it clear for you?
huxiaoxia is offline   Reply With Quote

Old   May 17, 2011, 06:07
Default setting cyclic BC
  #12
Member
 
Nicolas
Join Date: Apr 2011
Location: Biarritz / France
Posts: 33
Rep Power: 6
NicolasB is on a distinguished road
Hi,
For a better understanding of OF, I'm trying to set up the Fluent's tutorials in OF.
I'm currently working on the second tutorial about Modeling Periodic Flow and Heat Transfer, with periodic conditions.
Here is what I've made:
- copy the caelinux-1.7.0/run/tutorials/heatTransfer/buoyantBoussinesqSimpleFoam/hotRoom tutorial;
- delete the constant/polyMesh directory;
- transform the mesh provided with Fluent's tutorial using the command
Code:
fluentMeshToFoam -scale 0.01 tubebank.msh
- write and execute a createPatchDict;
- copy and modify files from 0 to 1;
- prompt a foamJob buoyantBoussinesqSimpleFoam.

The point is the results are far from those obtained in Fluent, and I'm quite certain I've failed in setting up the cyclic BCs.
It would be pretty nice if someone should help me.

See the attachments for my case (due to its size, I can't join the mesh here nor the tutorial's pdf, but if you're interested in, I'd be pleased to send them by email)
Attached Files
File Type: gz tuto2_buoyantBoussinesqSimpleFoam.tar.gz (46.7 KB, 146 views)
NicolasB is offline   Reply With Quote

Old   April 12, 2013, 02:20
Default
  #13
New Member
 
Esmaeil Ahmadiyan
Join Date: Sep 2011
Posts: 26
Rep Power: 5
e.ahmadiyan is on a distinguished road
Hi dear foamers
I am working with dsmcFoam and trying to modeling a cyclic boundary conditions in a channel. My case is freeSpacePeriodic in /run/discriteMethods/dsmcFoam/freeSpacePeriodic directory.
Boundary file in this case is as below:
6
(
xPeriodic_half0
{
type cyclic;
nFaces 256;
startFace 14464;
matchTolerance 0.0001;
neighbourPatch xPeriodic_half1;
}
xPeriodic_half1
{
type cyclic;
nFaces 256;
startFace 14720;
matchTolerance 0.0001;
neighbourPatch xPeriodic_half0;
}
yPeriodic_half0
{
type cyclic;
nFaces 320;
startFace 14976;
matchTolerance 0.0001;
neighbourPatch yPeriodic_half1;
}
yPeriodic_half1
{
type cyclic;
nFaces 320;
startFace 15296;
matchTolerance 0.0001;
neighbourPatch yPeriodic_half0;
}
zPeriodic_half0
{
type cyclic;
nFaces 320;
startFace 15616;
matchTolerance 0.0001;
neighbourPatch zPeriodic_half1;
}
zPeriodic_half1
{
type cyclic;
nFaces 320;
startFace 15936;
matchTolerance 0.0001;
neighbourPatch zPeriodic_half0;
}
)

Then I have changed this boundary file as below:
6
(
xPeriodic_half0 //(wall)
{
type wall;
nFaces 256;
startFace 14464;
}
xPeriodic_half1 //(outlet)
{
type cyclic;
nFaces 256;
startFace 14720;
matchTolerance 0.0001;
neighbourPatch yPeriodic_half0;
}
yPeriodic_half0 //(inlet)
{
type cyclic;
nFaces 320;
startFace 14976;
matchTolerance 0.0001;
neighbourPatch xPeriodic_half1;
}
yPeriodic_half1 //(wall)
{
type wall;
nFaces 320;
startFace 15296;
}
zPeriodic_half0 //(frontAndBack)
{
type empty;
nFaces 320;
startFace 15616;
}
zPeriodic_half1 //(frontAndBAck)
{
type empty;
nFaces 320;
startFace 15936;
}
)
But when I run this case give this error :
--> FOAM FATAL ERROR:
face 0 area does not match neighbour by 22.22222222% -- possible face ordering problem.
patchutlet my area:64 neighbour area:80 matching tolerance:0.0001
Mesh face:1 fc-5 0 0)
Neighbour fc0 4 0)
If you are certain your matching is correct you can increase the 'matchTolerance' setting in the patch dictionary in the boundary file.
Rerun with cyclic debug flag set for more information.

From function cyclicPolyPatch::calcTransforms()
in file meshes/polyMesh/polyPatches/constraint/cyclic/cyclicPolyPatch.C at line 220.

FOAM exiting

Please help me to resolve this error and please introduce a tutorial about cyclic BC modeling for me.
Thanks a lot.
Best regards

e.ahmadiyan
e.ahmadiyan is offline   Reply With Quote

Old   April 12, 2013, 03:52
Default
  #14
Senior Member
 
maddalena's Avatar
 
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 12
maddalena is on a distinguished road
Hi e.ahmadiyan,
maybe more detail can help us to understand what you want to do.
what openfoam version are you using? hat is your geometry? do you want to create cyclic or do you want to take given geometry and delete cyclic?

mad
maddalena is offline   Reply With Quote

Old   April 12, 2013, 04:16
Default
  #15
New Member
 
Esmaeil Ahmadiyan
Join Date: Sep 2011
Posts: 26
Rep Power: 5
e.ahmadiyan is on a distinguished road
Hi maddalena
Thanks for your reply
I am using openFoam 2.0.1 and my geometry is a cubic L shape channel as show in the attached image Screenshot.jpg
I want to give cyclic BC in inlet and outlet

Best

e.ahmadiyan
e.ahmadiyan is offline   Reply With Quote

Old   April 12, 2013, 04:29
Default
  #16
Senior Member
 
maddalena's Avatar
 
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 12
maddalena is on a distinguished road
Answer is quite simple then...
Quote:
Originally Posted by e.ahmadiyan View Post
xPeriodic_half1 //(outlet)
{
type cyclic;
nFaces 256;
startFace 14720;
matchTolerance 0.0001;
neighbourPatch yPeriodic_half0;
}
yPeriodic_half0 //(inlet)
{
type cyclic;
nFaces 320;
startFace 14976;
matchTolerance 0.0001;
neighbourPatch xPeriodic_half1;
}
Two faces are not equal at all!
My suggestion is to create a mesh using blockMesh or your preferred meshing software and then run createPatch.

mad
maddalena is offline   Reply With Quote

Old   April 12, 2013, 04:55
Default
  #17
New Member
 
Esmaeil Ahmadiyan
Join Date: Sep 2011
Posts: 26
Rep Power: 5
e.ahmadiyan is on a distinguished road
Whats your mean about two faces are not equal?
Could is salome be a good meshing software? What is your suggestion about preferred meshing software?
In fact when we use of createPatch utility?

Tanks again.
Best.

e.ahmadiyan
e.ahmadiyan is offline   Reply With Quote

Old   April 12, 2013, 05:00
Default
  #18
Senior Member
 
maddalena's Avatar
 
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 12
maddalena is on a distinguished road
Two faces are not equal since cell number is different!
You can use whatever you want as meshing software or utility. After you have a mesh, you use createPatch to crete cyclic.

Good luck.

mad
maddalena is offline   Reply With Quote

Old   April 12, 2013, 05:04
Default
  #19
New Member
 
Esmaeil Ahmadiyan
Join Date: Sep 2011
Posts: 26
Rep Power: 5
e.ahmadiyan is on a distinguished road
Thanks dear maddalena
Good luck.

e.ahmadiyan
e.ahmadiyan is offline   Reply With Quote

Old   April 14, 2013, 12:50
Default
  #20
New Member
 
Esmaeil Ahmadiyan
Join Date: Sep 2011
Posts: 26
Rep Power: 5
e.ahmadiyan is on a distinguished road
Hi dear maddalena
I have creates a mesh with salome and uses of createPatch and creates a cyclic BC but I have received to below error:
FOAM Serious Error :
From function cyclicPolyPatch:rder(const primitivePatch&, labelList&, labelList&) const

No base point for face 15903, 4(5708 6065 6066 5709), produces a valid tet decomposition.

All my test case...
cyclic.zip

Have you any suggestion?

Best regards.

e.ahadiyan

Last edited by e.ahmadiyan; April 15, 2013 at 09:53.
e.ahmadiyan 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
Boundary Conditions Thomas P. Abraham Main CFD Forum 20 July 7, 2013 05:05
Mixed/Robin boundary condition aaev OpenFOAM Bugs 2 December 15, 2011 15:03
cyclic boundary condition doesn't work in a tube ?? Cyp OpenFOAM 6 April 16, 2010 15:21
fan cyclic boundary condition leejc OpenFOAM 0 April 15, 2010 16:38
How to set boundary condition in Fluent for the fo Peiyong FLUENT 1 November 10, 2006 12:44


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