Heat transfer between two blocks

Numerical methods and mathematical models of Elmer
Post Reply
Gary R
Posts: 162
Joined: 12 Apr 2012, 07:23
Antispam: Yes
Location: Long Beach CA, USA

Heat transfer between two blocks

Post by Gary R »

Hi all,
I have been fighting the problem of coupling between two 3D object for various projects. The following is the simplest example that illustrates the problem.

Two blocks of metal - one steel the other aluminum - are placed together. The steel blocks outer face is maintained at 400C and the aluminum blocks outer face is held at 0C. The simulation shows no heat transfer between the blocks even though they are in direct contact. I am having similar problems in acoustics and electromagetics. The paraview result of the simulation is :
Cubes.png
Cubes.png (8.64 KiB) Viewed 678 times
The .brep and .sif files are included in the attached .tar file.
Attachments
TestCubes.tar.gz
(7.44 KiB) Downloaded 40 times
kevinarden
Posts: 2237
Joined: 25 Jan 2019, 01:28
Antispam: Yes

Re: Heat transfer between two blocks

Post by kevinarden »

My first thought is that there are coincident nodes at the boundary, each block has its own node at the interface, therefore one block doesn't know about the other block.

I confirmed this by meshing the geometry and there are coincident nodes at the boundary, the blocks have to share nodes to share data at the interface.

I resolved this by using the -merge option in ElmerGrid.

In gmsh you would use Coherence command to merge coincident points.

Do not know if FreeCad has a merge coincident points option.
Rich_B
Posts: 421
Joined: 24 Aug 2009, 20:18

Re: Heat transfer between two blocks

Post by Rich_B »

Definitely a double boundary between the two blocks.

Load the brep file in gmsh, mesh 3d with default options, save the msh file. Start ElmerGUI and load the msh file.
twoblocks.png
twoblocks.png (139.57 KiB) Viewed 673 times
First thing to notice, there are 12 boundaries. For two separate cubes, that is correct. For two cubes that share a face, there should only be eleven boundaries.

Click on each of the front faces, and hide them. Then click on the middle face, boundary 1 will be selected. Hide that face, and the second middle boundary will be exposed as boundary 8.

Rich

Edit: using elmergrid to merge the coincident nodes reduces the number of nodes from 477 to 432, which makes sense. It looks like the 12 boundaries are not merged into 11, which doesn't make sense. Am I missing something here? Or is this an example of a discontinuous boundary?

commands used:
elmergrid 14 2 Cubes
elmergrid 2 2 Cubes -merge 0.01 -autoclean
Rich_B
Posts: 421
Joined: 24 Aug 2009, 20:18

Re: Heat transfer between two blocks

Post by Rich_B »

Hello,

gmsh has an option to sew faces together. The options in gmsh for OCC Healing don't seem to be the answer for this issue, and the Coherence command does fix the issue.

Rich.
Last edited by Rich_B on 31 Aug 2022, 01:06, edited 1 time in total.
Rich_B
Posts: 421
Joined: 24 Aug 2009, 20:18

Re: Heat transfer between two blocks

Post by Rich_B »

Use the Coherence command in gmsh to fix double internal boundaries.

Rich.
Last edited by Rich_B on 31 Aug 2022, 01:07, edited 1 time in total.
Rich_B
Posts: 421
Joined: 24 Aug 2009, 20:18

Re: Heat transfer between two blocks

Post by Rich_B »

Hello again,

After searching the internet, I found a post by Christophe Geuzaine that said:
As others have pointed out, the simplest solution is to add "Coherence;" after "Merge" - provided that you add "SetFactory("OpenCASCADE");" before, i.e.

SetFactory("OpenCASCADE");
Merge "nanopore-rev-600.brep";
Coherence;
.....
Christophe
So create a cubes.geo file that contains:
SetFactory("OpenCASCADE");
Merge "Cubes.brep";
Coherence;
Open the cubes.geo file in gmsh, mesh 3d with default settings, save the msh file. Start ElmerGUI, open the msh file, and you should see 11 boundaries and 2 bodies. You could also run elmergrid with -merge and -autoclean as a matter of good practice, and you will also see 11 boundaries.

Rich.
kevinarden
Posts: 2237
Joined: 25 Jan 2019, 01:28
Antispam: Yes

Re: Heat transfer between two blocks

Post by kevinarden »

Just note that the 1 internal boundary is not needed unless you need to impose something on it. As long as the two bodies share nodes they will transmit data at the nodes. So the problem as stated could be run with ten boundaries. 5 on each cube with no internal boundary,
Gary R
Posts: 162
Joined: 12 Apr 2012, 07:23
Antispam: Yes
Location: Long Beach CA, USA

Re: Heat transfer between two blocks

Post by Gary R »

Hi all,
Setting a boundary condition at the interface and using merge 1 on ElmerGrid solved the problem. Putting the parts together with FreeCAD's compound command does the perfect setup for the process.

Thanks again for the help.

Gary R
Post Reply