|
[Sponsors] |
Possible bug in chtMultiRegionFoam with 2 solids in contact? |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
February 5, 2021, 05:07 |
[Solved]Possible bug in chtMultiRegionFoam with 2 solids in contact?
|
#1 |
Member
JuanMi
Join Date: Nov 2017
Posts: 41
Rep Power: 9 |
Hi,
I noticed a very strange behaviour in chtMultiRegionFoam. I prefer to share my question to the community before report a bug, because I could be wrong. I have two solids (two squares) in contact. Very very simple. I want to know Temperature at t=200s. All boundaries are zeroGradient except the right face, with fixed temperature. Heat transfer is governed by the Heat Equation, where diffusivity is the key. Solid 1 | Solid 2 Solid 1: Code:
/*--------------------------------*- C++ -*----------------------------------*\ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org \\ / A nd | Version: 8 \\/ M anipulation | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class dictionary; object thermophysicalProperties; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // thermoType { type heSolidThermo; mixture pureMixture; transport constIso; thermo eConst; equationOfState rhoConst; specie specie; energy sensibleInternalEnergy; } mixture { specie { nMoles 1; molWeight 100.02; // [g/mol] } transport { kappa 10; // [W/m/K] } thermodynamics { Hf 0; Cv 1000; // [J/kg/K] } equationOfState { rho 2200; // [kg/m^3] } } // ************************************************************************* // Solid 2: Code:
/*--------------------------------*- C++ -*----------------------------------*\ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org \\ / A nd | Version: 8 \\/ M anipulation | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class dictionary; object thermophysicalProperties; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // thermoType { type heSolidThermo; mixture pureMixture; transport constIso; thermo eConst; equationOfState rhoConst; specie specie; energy sensibleInternalEnergy; } mixture { specie { nMoles 1; molWeight 100.02; // [g/mol] } transport { kappa 10; // [W/m/K] } thermodynamics { Hf 0; Cv 1000; // [J/kg/K] } equationOfState { rho 2200; // [kg/m^3] } } // ************************************************************************* // For this problem (regarding to the squares), I get this result from the log, when solver finishes. Code:
Solving for solid region capa_2 DICPCG: Solving for e, Initial residual = 0.0037510124, Final residual = 6.6981383e-07, No Iterations 3 Min/max T:333.83288 453 ExecutionTime = 0.27 s ClockTime = 0 s Solid 1: Code:
/*--------------------------------*- C++ -*----------------------------------*\ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org \\ / A nd | Version: 8 \\/ M anipulation | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class dictionary; object thermophysicalProperties; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // thermoType { type heSolidThermo; mixture pureMixture; transport constIso; thermo eConst; equationOfState rhoConst; specie specie; energy sensibleInternalEnergy; } mixture { specie { nMoles 1; molWeight 100.02; // [g/mol] } transport { kappa 0.01; // [W/m/K] } thermodynamics { Hf 0; Cv 1; // [J/kg/K] } equationOfState { rho 2200; // [kg/m^3] } } // ************************************************************************* // Code:
Solving for solid region capa_1 DICPCG: Solving for e, Initial residual = 0.015590819, Final residual = 1.955389e-07, No Iterations 4 Min/max T:309.80765 371.48362 Solving for solid region capa_2 DICPCG: Solving for e, Initial residual = 0.0090723273, Final residual = 8.2453758e-08, No Iterations 4 Min/max T:371.48425 453 ExecutionTime = 0.29 s ClockTime = 0 s The minimum temperature of the second block is changing!! Why? I tried to change de ddtScheme, size of the mesh, adjustTimeStep, the maxDi...impossible. I don't know if I am stupid or really there is a bug in OpenFOAM I attach the case for OF-8, so you can test to change k and Cv mantaining the same thermal diffusivity. Thank you so much!! Last edited by keitaro7_14; February 5, 2021 at 14:53. |
|
February 5, 2021, 14:19 |
|
#2 |
Member
JuanMi
Join Date: Nov 2017
Posts: 41
Rep Power: 9 |
Well, as expected, I am the stupid here, and not the OpenFOAM developers. The problem here is that the problem is wrongly formulated. Let me explain.
When we have two solids in contact, we can model the problem like two solids of different properties in contact, or like a unique solid with variable thermal properties. It is fine, but we have to pay attention to the formulation. I assumed that two solids can be modelled as a solid with variable diffusivity, and the equation governing his physical behaviours is the following: but it is wrong! Why? Well,the success of the analysis/modelling depends on many factors, but the basis is the correct application ofthe heat conduction theory which is more important in case of transient thermal processes. I paid attention to the tool (OpenFOAM), but not to the formulation. Most of the cases we can assume that there is no movement, no force field at the surface, no volume heat generation, and the pressure is constant. Neither the density nor the thermal capacity are changing with the time. Taking into account these conditions, the simplified heat conduction equation will be as it follows Now, I can do a little transformation: But..Can I introduce into the derivative? NO! Because they are not constant! My real model are two solids, with different thermal properties. If I assume one solid, , and change with the position. The correct formulation following this approach of one solid with variable thermal diffusivity should be as follows: And well...we should derivate new ODEs to solve the problem. The other approach, with two solids, is the approach of OpenFOAM, and if we have two solids, we have a system of equations. and in the interface, we have where I hope this will help other researchers who have the same doubts as me and the same errors. I also recommend consulting the following publication: https://doi.org/10.1007/s10973-018-7014-4 Last edited by keitaro7_14; February 8, 2021 at 13:02. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Dynamic contact angle issue: fluent UDF couldn't set the correct contact angle | FelixJJ | FLUENT | 2 | October 20, 2021 03:39 |
Meshing concentration for Contact stress study between two solids | bolbol | Structural Mechanics | 4 | February 4, 2020 17:04 |
Contact between 2 solids Ansys Workbench | dadouxx | ANSYS | 0 | June 15, 2016 11:22 |
chtMultiRegionFoam, conduction with a contact resistance between two solids | romain.h | OpenFOAM Running, Solving & CFD | 1 | October 8, 2013 02:25 |
chtMultiRegionFoam: heat transfer coefficient between solids | brent | OpenFOAM Running, Solving & CFD | 0 | November 1, 2012 09:22 |