Heat gap boundary condition with unstructured meshes

General discussion about Elmer
polakse
Posts: 6
Joined: 08 Oct 2013, 20:33
Antispam: Yes
Location: Colorado, USA

Heat gap boundary condition with unstructured meshes

Post by polakse »

Hi, I'm new to Elmer and this is my first post on the forum...

I'm attempting to use Elmer to solve a heat transfer simulation through solid bodies. Eventually I would like to simulate an assembly with 10+ individual bodies, but initially I'm just trying to get an example working with two solid cubes that are in contact. Between each of my solid bodies, there is some thermal contact conductance/resistance that I would like to define. The "heat gap" type boundary condition in Elmer appears well-suited to simulate this interface thermal resistance.

If I understand correctly, it appears the following steps are required to model a "heat gap":
1) The "interface" boundary needs to have a secondary set of nodes
2) Create a boundary condition where the "heat gap" option is selected/true, a heat transfer coeff is specified, and the external temperature (corresponding to the heat transfer coeff) is set to zero

Now, for my questions:
1) is the above procedure correct?
2) the actual geometry I'm simulating is complex and will be meshed with tets - can Elmergrid -discont x (invoked from the command line) be applied to unstructured meshes (i.e. *.msh)?
3) is Elmergrid -discont the only option I have for adding secondary nodes? or can this be done in Gmsh, Netgen, Salome, etc?

I have many more questions, but I'll try to find answers myself before bugging folks on this forum. Thanks in advance for the help. And also thanks to all who have helped develop Elmer - it appears to be a great tool!
Takala
Posts: 186
Joined: 23 Aug 2009, 23:59

Re: Heat gap boundary condition with unstructured meshes

Post by Takala »

Hi Polakse,

here you can find tests for most of the functionality in elmer: http://sourceforge.net/p/elmerfem/code/ ... fem/tests/

There is a test also for heat gap: http://sourceforge.net/p/elmerfem/code/ ... s/HeatGap/

when you have a look at the sif file (solver input file, http://sourceforge.net/p/elmerfem/code/ ... mpDist.sif), you'll see all that is needed for setting it up:

Code: Select all

Boundary Condition 1
  Name = "Constraint1"
  Target Boundaries(1) = 1
  Heat Gap = Logical True
  Heat Transfer Coefficient = 10
End
So it seems you'll only need to switch it on "Heat Gap = Logical True" and give the appropriate heat transfer coefficient.

Now to the questions:
1) I think you have it more or less correct.
2) Yes, it will work with tets
3) In principle, I think you could do this in Salome. However, I don't see the point because you have to translate the mesh to native Elmer format anyway... For example, if you make the mesh in Salome, the output will in unv-format. You need to call ElmerGrid:

Code: Select all

ElmerGrid 8 2 mesh.unv -autoclean
Then you have the mesh in the native format. Now, to have the discontinuity, you can further command:

Code: Select all

ElemrGrid 2 2 mesh -discont some_number
Cheers,

Eelis
polakse
Posts: 6
Joined: 08 Oct 2013, 20:33
Antispam: Yes
Location: Colorado, USA

Re: Heat gap boundary condition with unstructured meshes

Post by polakse »

Eelis,

Thanks for the valuable insight - you have definitely clarified the process for me. Unfortunately, my first attempts with this process were unsuccessful. Seemingly regardless of the mesh type I start with, I receive the error below.

Code: Select all

ElmerGrid 2 2 testCHT -discont 4
produces the following error
SetDiscontinuousBoundary: impossible to make the boundary of several materials
I get the same results if I start with a *.unv mesh from Salome (which needs to be "divided by sharp edges" first, before adding the -discont layer), or a Gmsh *.msh file.

I'll keep digging into this issue on my own, but if anybody has any suggestions, I would greatly appreciate the help. Thanks!
Scott
raback
Site Admin
Posts: 4812
Joined: 22 Aug 2009, 11:57
Antispam: Yes
Location: Espoo, Finland
Contact:

Re: Heat gap boundary condition with unstructured meshes

Post by raback »

Hi,

Now the discontinuity has some limitations. For one the boundary should be such that at least on either side the material (i.e. body) remains the same. Only this way can the logic deduce consistently the two sides. Also it has not been assumed that you would have many different discontinuous BCs that share nodes. Unfortunately I cannot see that this would be a limitations that would be solved in the near future. The meshing is just philosophically maybe not the place to introduce discontinuities after all.

I think that it would be a more generic and robust approach to use discontinuous galerkin method and implement jump conditions between different materials. Then it would be possible to combine discontinuous and continuous fields. Unfortunately some work to do there also.

-Peter
polakse
Posts: 6
Joined: 08 Oct 2013, 20:33
Antispam: Yes
Location: Colorado, USA

Re: Heat gap boundary condition with unstructured meshes

Post by polakse »

Peter, thanks for the explanation. At this point, it seems my only option is to model/mesh the interfaces. In reality these interfaces are only microns thick, but because I'm dealing with solid geometry that is centimeters in size, I will scale the thickness of the interfaces (to achieve a good mesh), and also scale the thermal properties (i.e. conductivity) of the interface materials accordingly, in order to achieve the necessary thermal conductance through each interface body.

Am I correct in assuming the method I just described is currently the only way to induce a thermal resistance between two solid bodies that are separate bodies/materials?

Slightly off-topic, I'll provide some background info as to how I arrived at Elmer...
I routinely perform CFD and CHT simulations using ANSYS CFX. CFX handles multi-body CHT simulations especially well because of its ability to provide mesh connections (i.e. GGI, "general grid interface") as well as various interface models (pressure change, thermal resistance/conductance, etc). However, I've been looking for an ope-source alternative to CFX - both because of my preference for open-source codes, and because of cost. The two I have considered seriously are OpenFOAM and Elmer, and currently Elmer has most of my attention because of the simple and intuitive GUI and because it runs easily in Windows. Unfortunately, neither Elmer nor OpenFOAM seem to support these mesh connection and interface models which I have become so dependent upon.

I am still very interested in Elmer, and I would like to help support the development any way I can. If there is anything I can do to help facilitate the incorporation of mesh connection algorithms or interface models, please let me know. Thank you!
raback
Site Admin
Posts: 4812
Joined: 22 Aug 2009, 11:57
Antispam: Yes
Location: Espoo, Finland
Contact:

Re: Heat gap boundary condition with unstructured meshes

Post by raback »

Hi

I understand your point. Now there are also quite severe limitations in the GUI of Elmer. It offers only a the most common features of ElmerSolver. For instance this discontinuous gap is hardly supported.

Now there closest Elmer comes with "general grid interface" would perhaps be the mortar finite element machinery developed very recently. This allows joining of nonconforming meshes. The routines have been used to model rotating machines, for example. Now currently this approach does not allow the setting of a jump but that could be a small modification. Haven't looked it more closely though. Still this might be more promising approach than the DG since almost all of the existing solvers can currently utilize this mortar finite element approach as a generic library routine.

-Peter
Takala
Posts: 186
Joined: 23 Aug 2009, 23:59

Re: Heat gap boundary condition with unstructured meshes

Post by Takala »

polakse wrote:Eelis,

Thanks for the valuable insight - you have definitely clarified the process for me. Unfortunately, my first attempts with this process were unsuccessful. Seemingly regardless of the mesh type I start with, I receive the error below.

Code: Select all

ElmerGrid 2 2 testCHT -discont 4
produces the following error
SetDiscontinuousBoundary: impossible to make the boundary of several materials
I get the same results if I start with a *.unv mesh from Salome (which needs to be "divided by sharp edges" first, before adding the -discont layer), or a Gmsh *.msh file.

I'll keep digging into this issue on my own, but if anybody has any suggestions, I would greatly appreciate the help. Thanks!
Scott
Hi Scott,

I didnt quite understand why this happens. Could you share a geometry where this can be reproduced? For example a salome hdf file. Maybe it just need some small adjustment.

Cheers,

Eelis
mzenker
Posts: 1999
Joined: 07 Dec 2009, 11:49
Location: Germany

Re: Heat gap boundary condition with unstructured meshes

Post by mzenker »

Hi Peter,
raback wrote: Now there closest Elmer comes with "general grid interface" would perhaps be the mortar finite element machinery developed very recently. This allows joining of nonconforming meshes. The routines have been used to model rotating machines, for example.
can this machinery resolve a nonconforming mesh at the interface between two neighbor volumes?
If so I would be most interested in testing it, since this is a problem which I have been fighting with for quite some time.
Where do I find more information?

Thanks,

Matthias
raback
Site Admin
Posts: 4812
Joined: 22 Aug 2009, 11:57
Antispam: Yes
Location: Espoo, Finland
Contact:

Re: Heat gap boundary condition with unstructured meshes

Post by raback »

Hi Matthias

I just put a new case on the svn: MortarPoisson2D. That might give you a clue of the possibilities. Also the RotatingBC* test cases utilize the same functionality but they are somewhat complicated by the rotation.

-Peter
polakse
Posts: 6
Joined: 08 Oct 2013, 20:33
Antispam: Yes
Location: Colorado, USA

Re: Heat gap boundary condition with unstructured meshes

Post by polakse »

Takala wrote: I didnt quite understand why this happens. Could you share a geometry where this can be reproduced? For example a salome hdf file. Maybe it just need some small adjustment.
Eelis
Sure. A Salome .hdf file is attached. Thanks for the help.
Scott
Attachments
testCHT.zip
(47.74 KiB) Downloaded 437 times
Post Reply