|
[Sponsors] |
July 2, 2013, 12:28 |
cyclic BC
|
#1 |
Member
Join Date: Feb 2012
Posts: 59
Rep Power: 14 |
I try to set up a translational periodic boundary condition. Any idea on how to specify it and set up pressure gradient?
Cheers, Raymond |
|
July 2, 2013, 14:40 |
|
#2 | ||
Senior Member
Mohsen KiaMansouri
Join Date: Jan 2010
Location: CFD Lab
Posts: 118
Rep Power: 16 |
I quote the user guide section 5.2.2 Base types :
Quote:
Code:
type cyclic; I quote it again: Quote:
you can explain your case in detail for further help!
__________________
“If you have an apple and I have an apple and we exchange these apples then you and I will still each have one apple. But if you have an idea and I have an idea and we exchange these ideas, then each of us will have two ideas.” |
|||
July 3, 2013, 04:59 |
|
#3 |
Member
Join Date: Feb 2012
Posts: 59
Rep Power: 14 |
Let's say the case is the fully-developed laminar flow in a pipe, where the outlet is the same to the inlet. In general, we can specify the velocity or the pressure gradient. Is it clear to you?
|
|
July 4, 2013, 07:06 |
In which file?
|
#4 |
New Member
Mohammad
Join Date: Jul 2013
Posts: 10
Rep Power: 13 |
Thanks for your good comment.
I am new to OpenFOAM, so forgive my simple question. 1. I did not understand; shall we write this cyclic commands: left type cyclic; neighbourPatch right; faces ((0 4 7 3)); right type cyclic; neighbourPatch left; faces ((1 5 6 2)); "in blockMeshDict" file or "boundary" file? since I think the format you entered here seems to be for boundary, but it is said that it is for blochMeshDict. 2. What shall we also write for U and P conditions? something like this: for p: type: cyclic value: uniform 0 for U: type: cyclic value: uniform (0 0 0) Thanks again. |
|
July 25, 2013, 18:35 |
|
#5 |
New Member
Juan Pablo Toro Labbe
Join Date: Jun 2013
Location: Davis CA
Posts: 7
Rep Power: 13 |
Dear mohammad81:
Generally speaking write in BlockMeshDict, actually boundary file is an output. Regards, JP |
|
July 26, 2013, 07:08 |
|
#6 | |
New Member
Andre Weiner
Join Date: Aug 2012
Posts: 29
Rep Power: 14 |
Quote:
Hello, i was facing the same problem some time ago. Have a look at the channel395 tutorial .../tutorials/incompressible/pimpleFoam/channel395 There is a fvOption called "pressureGradientExplicitSource" in which the pressure gradient source is calculated by an average velocity. As your problem is translatory, it should work easily. (at least in my mind it works :-) Keep in mind that currently only the kinematic pressure is handled so that you will get an unphysical static pressure field. If you don't need it for further calculations, it doesn't matter. Best regards |
||
July 30, 2013, 06:46 |
|
#7 |
Member
Leonardo Honfi Camilo
Join Date: Mar 2009
Location: Delft, Zuid Holland, The Netherlands
Posts: 60
Rep Power: 17 |
Indeed you can either follow the example of the channelFoam tutorial, where a constant mass flow is imposed and a pressure gradient correction is applied after each iteration. Or you can set a fixed pressure gradient into the solver, which I reckon is a wee bit more realistic for turbulent flows.
This can be done by adding an entry to the readFields.H file that reads the value of a dimensioned vector (or scalar if you multiply it by a flowDirection vector) that reads the transportProperties file. It goes without saying that you need to add an entry to the transportProperties file as well. In the momenum equation of the channelFoam tutorial you should have ... == flowDirection*gradP }; in case gradP is a scalar and ... == gradP }; in case gradP is a vector. |
|
January 21, 2014, 08:16 |
|
#8 |
Member
Manan
Join Date: Oct 2013
Location: Göteborg
Posts: 37
Rep Power: 13 |
Hi lhcamilo
I tried modifying the simpleFoam solver to have a constant pressure gradient whose magnitude is equal to -1 (i.e. gradP = -1 * flow direction (1 0 0), where gradP is a dimensioned vector which I define in the createFields.H I added the following lines in createFields.H Info<< "Reading gradP \n"<<endl; volVectorField gradP ( IOobject ( "gradP", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::AUTO_WRITE ), mesh, dimensionedVector("gradP", dimensionSet(0,1,-2,0,0,0,0), Foam::vector(-1,0,0)) ); Also, I modified my simpleFoam Solver by changing the momentum predictor equation in UEqn.H // Momentum predictor tmp<fvVectorMatrix> UEqn ( fvm::div(phi, U) + turbulence->divDevReff(U) == fvOptions(U) ); UEqn().relax(); fvOptions.constrain(UEqn()); // solve(UEqn() == -fvc::grad(p)); solve(UEqn() == -gradP); fvOptions.correct(U); Do you think this should do the trick? Do you know if I need to change something in pEqn.H? |
|
August 26, 2016, 16:34 |
|
#9 |
New Member
Udvavisk Technologies
Join Date: Jun 2016
Location: India
Posts: 1
Rep Power: 0 |
Hey Andre, Thanks. I struggled a lot for this.
__________________
Best Regards, Udvavisk Technologies |
|
December 13, 2016, 12:40 |
How to set up cyclic boundary condition in a 3D model
|
#10 |
New Member
N/A
Join Date: Dec 2016
Posts: 5
Rep Power: 10 |
Hi All,
I am new in OP, I have a rotating object which has axisymmetric feature in a 3D geometry. I modeled it with MRF method, however since it is a large model, it takes a long time to converge, so I want to use symmetry of the geometry and just solve part of the geomtry. I don't know how I should apply cyclic boundary for meshing (blockmesh, snappyHexmesh), I was wondering if anybody could help me. Thank you in advance. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[mesh manipulation] Cyclic Mesh Error | vbchris | OpenFOAM Meshing & Mesh Conversion | 4 | November 15, 2012 14:04 |
Cyclic bc. and overlapGgi | Pekka | OpenFOAM | 12 | February 15, 2012 08:10 |
[Commercial meshers] Handling cyclic BC from gambit to openfoam for a cascade airfoil problem - OF 1.6 | maverick | OpenFOAM Meshing & Mesh Conversion | 2 | June 18, 2011 05:36 |
Pressure instability with rhoSimpleFoam | daniel_mills | OpenFOAM Running, Solving & CFD | 44 | February 17, 2011 18:08 |
[snappyHexMesh] snappyHexMesh with cyclic patches? | Axel_T | OpenFOAM Meshing & Mesh Conversion | 1 | October 12, 2010 11:03 |