# simple problem with internal faces Boundary condition

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

 August 8, 2010, 13:20 simple problem with internal faces Boundary condition #1 Member   Mohammad.R.Shetab Join Date: Jul 2010 Posts: 49 Rep Power: 7 Hi everyone!!!! I am new with openfoam.I have studied about almost all boundary conditions in openfoam but I haven't seen any B.B. for internal(interior) faces.I mean faces with no special condition and just between two region of fluids.How should I describe their boundary condition in boundary Dictionary and folder 0. To be more clear I give a simple example.it is a solid cylinder inside a 2D channel.I could use just one part mesh but to test B.C. for internal face I used two regions of mesh.what is the boundary condition for that internal face?! can anyone help?!!! thank you

 August 9, 2010, 11:09 #2 New Member   Robert Langner Join Date: Dec 2009 Location: Freiburg, Germany Posts: 27 Rep Power: 7 Hi Mohammad, I don't think a patch is suitable to describe a movable (and even splitable) fluid interface. Following your explanation, the solver "interFoam" (laminar) or "lesInterFoam" should be a good way. It's a two fluid approach so you can define the different fluid properties as well. InterFoam calculates the interface from the volume fraction of the two fluids, which is given by the additional field value "gamma" (or alpha since OF1.6) for each cell. The status you illustrated in your picture you can set up easily as an "internal Field" in the 0/alpha file with the aid of the "setFieldsDict". The "damBreak" tutorial should give you a good basement for your case and even shows how the setFieldsDict works. Bests, Robert

 August 9, 2010, 17:50 ..... #3 Member   Mohammad.R.Shetab Join Date: Jul 2010 Posts: 49 Rep Power: 7 Dear Robert thanks for your reply and your useful guidance.but first I want to be sure if my problem is completely clear to you.my original problem is a fan that is much more complicated than this example but to understand the way defining internal faces,I made this example. the internal boundary is not between two different fluids.It is just between two kind of Meshes.so I've found a way to describe this kind of internal faces by means of stitchMesh.you know any better way!? thank you again Mohammad

 August 10, 2010, 13:48 #4 Senior Member   Ben K Join Date: Feb 2010 Location: Ottawa, Canada Posts: 140 Rep Power: 10 For internal faces, check our chtMultiRegionFoam or conjugateHeatFoam. conjugateHeatFoam is only available in 1.5-dev.

 August 12, 2010, 02:08 #5 Senior Member   Arne Stahlmann Join Date: Nov 2009 Location: Hanover, Germany Posts: 209 Rep Power: 8 Mohammad, why do you need an internal boundary? You can put a mesh with different resolutions and types (I guess that is what you want to do) together, without defining an internal boundary. But I'm not familiar with how this is working in blockMesh, if you are using this, as I'm using Salome instead. What kind of mesh are you using, structured or unstructured? Arne Last edited by Arnoldinho; August 12, 2010 at 02:25.

 August 12, 2010, 03:31 solved!!!! #6 Member   Mohammad.R.Shetab Join Date: Jul 2010 Posts: 49 Rep Power: 7 Dear Arne My problem has been solved!!!! It was easy and I wonder why I couldn't anywhere read about it!!!! you know my fan(main problem that I want to model) is much complicated than this model.so I cant use diffrent mesh resolution for that!!!I just have to mesh different parts and then with internal faces gather them together. but it is solved!!!!it is easy. you should just mesh two volumes separately in gambit(any type of mesh you want),but it is essential that one and just one face should be between 2 volumes, and then when you want to mention boundaries and their types in gambit, dont even choose this internal face. openfoam automatically name it default-patch and finally set it interior face and not a boundary. anyway thank youfor your reply Mohammad peppino, ali-group and pruthvi1991 like this.

 August 22, 2010, 01:30 #7 Senior Member   Nilesh Rane Join Date: Apr 2010 Posts: 122 Rep Power: 7 Hello Mohammad, Just to get the idea cleared, i suppose the internal face u r talking about is the boundary face between the non-conformal meshes i.e. meshes who dont have same distribution on either sides of the particular face right??? And you just want the fluid flow through the face and no special boundary condition as such, am i right??? So that Openfoam will just interpolate the values from one mesh nodes to the other one. Actually i also was wondering whether this is possible in openfoam using the mesh of blockMesh. __________________ Imagination is more important than knowledge..

 August 22, 2010, 17:37 yeah!! #8 Member   Mohammad.R.Shetab Join Date: Jul 2010 Posts: 49 Rep Power: 7 yeah!!! you're right and the solution was what I had posted in previous post. I use gambit for making my meshes and not blockMesh. I had to not to define that internal face in Gambit as a boundary, and it must be just one face between two volumes of course.I mean it must be a part of two volumes. anyway thank you Mohammad reza Arslan Arshad likes this.

 August 23, 2010, 02:34 #9 Senior Member   Arne Stahlmann Join Date: Nov 2009 Location: Hanover, Germany Posts: 209 Rep Power: 8 Mohammed, you should then be careful when sticking two different meshes together. If the nodes of your meshes are not at the same positions in both meshes, this might result in artificial high velocities at the interface due to the interpolation in OpenFoam.

August 23, 2010, 04:03
#10
Senior Member

Bernhard Linseisen
Join Date: May 2010
Location: Magdeburg/Geneva
Posts: 178
Blog Entries: 1
Rep Power: 7
Quote:
 Originally Posted by Arnoldinho If the nodes of your meshes are not at the same positions in both meshes, this might result in artificial high velocities at the interface due to the interpolation in OpenFoam.
Thank you for the suggestion!
Just right now I am doing preliminary simulations that include such a block-change...

For those working with blockMesh only: It seems even simpler than in Gambit! Just do not give a specific patch-type to the internal face. Though it seems the meshes are calculated separately (I did not look into that too sharply), flow like normal definitely does take place through that internal face.

Nevertheless, what I experienced (just doing a confirmatory simulation, waiting for results) : Even if the nodes of the meshes at the boundary are perfectly identical, different size of the mesh cells in the other dimension seems to really influence the simulation result!

 August 23, 2010, 06:16 #11 Senior Member   Nilesh Rane Join Date: Apr 2010 Posts: 122 Rep Power: 7 Hello friends, I guess if the face has same number of nodes its not a non-conformal mesh. And i dont understand, why should the fact that the nodes are not matching on the face affect the solution so critically. I mean, as far as i know, the values just need to be interpolated from one node mapping (from one side of the internal face) to another (on the other side of the face). Its suppose to be a simple interpolation calculation e.g. weighted average of values of surrounding nodes of the 2nd node map from the 1st node mapping. Please correct me if i am way to wrong. __________________ Imagination is more important than knowledge..

December 20, 2010, 08:31
#12
Member

Claudio
Join Date: Mar 2010
Posts: 57
Rep Power: 7
Quote:
 Originally Posted by mrshb4 Dear Arne My problem has been solved!!!! It was easy and I wonder why I couldn't anywhere read about it!!!! you know my fan(main problem that I want to model) is much complicated than this model.so I cant use diffrent mesh resolution for that!!!I just have to mesh different parts and then with internal faces gather them together. but it is solved!!!!it is easy. you should just mesh two volumes separately in gambit(any type of mesh you want),but it is essential that one and just one face should be between 2 volumes, and then when you want to mention boundaries and their types in gambit, dont even choose this internal face. openfoam automatically name it default-patch and finally set it interior face and not a boundary. anyway thank youfor your reply Mohammad

Dear Sir,

You said that OF automatically name it patch into the boundary file. However, once the patch appears into the boundary file, one has to define for it the proper boundary conditions in p, U T, etc., files. My question is, is there an "interior" (which simulates a "neutral" patch) boundary condition implemented in OF?
Thank You very much,

Claudio Comis

 December 20, 2010, 12:19 neutral patch #13 Member   Mohammad.R.Shetab Join Date: Jul 2010 Posts: 49 Rep Power: 7 Dear Claudio, When I said that OF convert internal face into patch, I didn't mean that it must be defined in boundary conditions. Look at this example: I have a mesh in gambit with one face (and just one face) between 2 volumes and I won't define them as boundaries in gambit. Then bring them in .msh format and use fluentMeshToFoam command to convert that to OF type. In this conversion, OF automatically set that face into a default patch that you should have not define it in /polyMesh/boundary and 0 folder. It is a NEUTRAL interior, and that's it. Just test it. ( If it is 2 faces between 2 volumes it won't be internal face anymore, and you have 2 choices: 1- define both faces in gambit as boundaries that your case would work properly BUT with that BC that is not internal face anymore ( you should define it in /boundary in OF too). 2- not to define them in gambit as boundaries ( and so it won't come to OF boundaries too) that your case would not give you answer properly.) Hope this helps Mohammadreza

 June 26, 2014, 18:18 #14 New Member   Jue Wang Join Date: Apr 2014 Posts: 6 Rep Power: 3 Hi, Mohammad, I'm a beginner in OF. I faced the same problem in defining internal faces BC. It sounds you have solved the problem by not defining internal faces as boundaries, right? Did you solve the problem with blockMesh? Four years has passed, I'm not sure whether you could kindly paste your blockMeshDict for reference. Thanks a lot. Joe

 June 28, 2014, 09:19 #15 Senior Member   Nima Sam Join Date: Sep 2009 Location: Tehran, Iran Posts: 1,124 Blog Entries: 1 Rep Power: 14 Dear Jue 1- do you have separated region ? then u can give the idea from chtMultiRegion tutorials 2- if you have connected region you can define a baffle would you please define your problem much specifically ? __________________ Training Course on OpenFOAM at (http://www.isme.ir/) My Weblog (http://openfoam.blogfa.com/)

June 28, 2014, 11:45
#16
New Member

Jue Wang
Join Date: Apr 2014
Posts: 6
Rep Power: 3
Hi Nima,
I fixed some problems but the new problem is that one master patch has dozens of different slave patches, like walls and baffles. I may divide the master patch into pieces but it needs too much work. Can I connect the master patch with those slave patches simultaneously? Does it work with "mergePatchPairs"? Thank you.

Joe

Quote:
 Originally Posted by nimasam Dear Jue 1- do you have separated region ? then u can give the idea from chtMultiRegion tutorials 2- if you have connected region you can define a baffle would you please define your problem much specifically ?

 June 29, 2014, 01:49 #17 Senior Member   Nima Sam Join Date: Sep 2009 Location: Tehran, Iran Posts: 1,124 Blog Entries: 1 Rep Power: 14 yes, it works, just u should define all your slave faces as one patch name, because you can use mergePatchPairs once __________________ Training Course on OpenFOAM at (http://www.isme.ir/) My Weblog (http://openfoam.blogfa.com/)

 April 22, 2015, 03:12 #18 New Member   zahra Join Date: Jun 2014 Location: Iran-Tehran Posts: 28 Rep Power: 3 Hi every body I am new to openfoam and I have a case with three region, one solid phase and 2 fluid phases. I have used Chtmultiregionfoam as a solver, the boundary between 2 fluids which are two different gases is internal, I have 4 polymesh folders in my case, three for 3 parts( one solid and 2 fluids) and one polymesh folder for total mesh of structure. I have made all meshes in Gambit. Now please help me with: 1)which kind of boundary condition I should use for this internal boundary in gambit and openfoam in each polymesh/boundary folder? 2) which kind of boundary condition I should use in 0/p, 0/u or in 0/T for this internal boundary?

 April 22, 2015, 04:16 internal interfaces #19 Senior Member   Bernhard Linseisen Join Date: May 2010 Location: Magdeburg/Geneva Posts: 178 Blog Entries: 1 Rep Power: 7 Dear Zahra, for chtMRF basically it is the same principle as for the cases above: If you have fluid flowing through this internal interface, it should not be split into different regions but remain one flow region. Even if you combine different parts during meshing, these internal interfaces should not be defined as boundaries. If in contrast you are thinking of two regions of immiscible fluids, just let splitMeshRegions do its magic and set the wall conditions. If you are trying to use different flow settings in the two different fluid regions and there is supposed to be full communication between them: I have worked on some interfaces for such a case some time ago, but that work is not yet finished - although I plan to revive it during May and June. To my knowledge, so far there is no such interconnection-condition in the official release yet. But if you just want to define e.g. two different temperatures for the fluid "regions" I suggest not taking the way of defining different regions but using the setSet- or topoSet-functionality. Definition of the cellsets should be working similar to the region-setting, but you will not have to partition the mesh for the different fluid zones. As an example for what I mean you could look at the damBreak-tutorial, I think there it is put up in a way easy to follow. Cheers, Bernhard Edit: If you want to consider multiphase flow within chtMultiRegionFoam I am quite certain you would have to do some programming in the solver... luiscardona likes this.

 April 22, 2015, 04:46 #20 New Member   zahra Join Date: Jun 2014 Location: Iran-Tehran Posts: 28 Rep Power: 3 Thank you bernhard In fact I have only one kind of gas in my model, it is air. I have a channel which half part of it, is porous. In porous media we have the same fluid but with different governing equation ( researchers model porous media as a fluid but with different governing equation). Air can pass through the line between porous zone and the other half of the channel. Now I am confused, what I should do?!! Zahra

 Thread Tools Display Modes Linear Mode

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

 Similar Threads Thread Thread Starter Forum Replies Last Post almir OpenFOAM Running, Solving & CFD 51 June 28, 2015 16:36 Jetfire OpenFOAM Running, Solving & CFD 107 December 9, 2014 14:38 Saturn CFX 34 October 16, 2014 05:27 ghobold Main CFD Forum 8 September 29, 2014 03:20 ARC Open Source Meshers: Gmsh, Netgen, CGNS, ... 0 February 27, 2010 11:56

All times are GMT -4. The time now is 20:21.