CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

chtMultiRegionFoam wrong value of kappa using constAnIsoSolid

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 3, 2022, 09:48
Default chtMultiRegionFoam wrong value of kappa using constAnIsoSolid
  #1
New Member
 
Join Date: Nov 2022
Posts: 1
Rep Power: 0
Bazyl29 is on a distinguished road
Hello everyone!

Currently, I'm working on simulations of battery cooling using chtMultiRegionFoam with OpenFOAM 10. I performed my first simulation and compared the results to the ANSYS Fluent, which unfortunately had significant differences in cells' temperatures between each other. As one of the steps of searching for the reason for discrepancies, I have prepared a simple simulation consisting only of one solid region with simple boundary conditions that I can calculate analytically. The key here is that I want to use anisotropic thermal conductivity in a cylindrical coordinate system to model conduction in cells, so I created a model as in the picture below:




Using this model I have found that I get a strange behaviour of thermal conductivity in OpenFOAM when using constAnIsoSolid with a cylindrical coordinate system. I have performed 5 simulations:
  1. OpenFOAM with isotropic thermal conductivity set to 1.3 W/mK
  2. OpenFOAM with anisotropic thermal conductivity in a cylindrical coordinate system set to (1.3 28 28) #by my understanding it is (r, theta, z)
  3. OpenFOAM with anisotropic thermal conductivity in a cylindrical coordinate system set to (1.3 1.3 1.3)
  4. Fluent with isotropic thermal conductivity set to 1.3
  5. Fluent with anisotropic thermal conductivity in a cylindrical coordinate system set to (1.3 28 28)

The results are compared below:







As you can see, using ANSYS Fluent the results are very close to analytical. Also, the results for isotropic 1.3 and anisotropic (1.3 28 28) are the same, which in my reasoning makes sense as the top, bottom and side walls are insulated and the only heat transfer direction is radial thus other conductivity vector components do not matter. The results for OpenFOAM with isotropic conductivity 1.3 and anisotropic conductivity (1.3 1.3 1.3) were the same and also close to analytical and Fluent. The problem starts when I use anisotropic thermal conductivity (1.3 28 28) - the maximum temperature is around 4 K lower compared to analytical and Fluent, as well as there is a discrepancy between (1.3 28 28) and (1.3 1.3 1.3) - based on the analytical calculation the kappa in radial direction would need to be 2.38 W/mK to match the temperature achieved at the inner radius wall.

I have attached fragments of code with T boundary conditions and conductivity definition in the cylindrical coordinate system as I presume the potential error is somewhere there. There is also no tutorial in $FOAM_TUTORIALS that covers anisotropic conductivity. Based on the results and looking into examples definition of a cylindrical coordinate system seems OK, but maybe I have missed something. I have tried to define additional properties of "externalWallHeatFluxTemperature" boundary conditions (as well as "compressible::turbulentTemperatureCoupledBaffleMi xed", which I have used initially in the more complicated simulation) based on the various threads I have found online (kappaMethod directionalSolidThermo, alphaAni Anialpha, etc.) but none of it seemed to work.

Code:
dimensions      [ 0 0 0 1 0 0 0 ];

internalField   uniform 300;

boundaryField
{
    #includeEtc "caseDicts/setConstraintTypes"

    "sides"
    {
        type            zeroGradient;
    }    
    "inner"
    {
        type            externalWallHeatFluxTemperature;
        q               uniform 1000;
        value           uniform 300;
    }
    "outer"
    {
        type            fixedValue;
        value           uniform 300;
    }
}
Code:
thermoType
{
    type            heSolidThermo;
    mixture         pureMixture;
    transport       constAnIsoSolid;
    thermo          eConst;
    equationOfState rhoConst;
    specie          specie;
    energy          sensibleInternalEnergy;
}

mixture
{
    specie
    {
        molWeight       18;
    }
    equationOfState
    {
        rho             2650;
    }
    thermodynamics
    {
        Hf              0;
        Cv              1263;
    }
    transport
    {
        kappa           ( 1.3 28 28 );
    }
}

coordinateSystem
{
    type            cartesian;
    origin          ( 0 0 0 );
    coordinateRotation
    {
        type            cylindrical;
        e3              ( 0 0 1 );
    }
}
Did anyone encounter a similar issue and knows how to fix it? I would really appreciate your help as I'm not an experienced OpenFOAM user and have tried everything that I could find without any success and have run out of potential resolutions. If someone would like to dive deeper into the code, I can upload other fragments or send the whole directory (unfortunately file size limit didn't let me attach it).

Last edited by Bazyl29; November 4, 2022 at 03:45. Reason: Forgot to post version of software used
Bazyl29 is offline   Reply With Quote

Reply

Tags
anisotropic, chtmultiregionfoam, constanisosolid, cylindrical


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 Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Help with PIMPLE algorithm in chtMultiregionFoam Chris T OpenFOAM Running, Solving & CFD 0 August 30, 2022 09:49
Something wrong running rhoSimpleFoam (urgent!) PeterShi OpenFOAM Running, Solving & CFD 7 March 1, 2017 10:21
Explanation of thermophysical variables (e.g. kappa) + tutorial example MBttR OpenFOAM Running, Solving & CFD 10 August 8, 2016 03:34
Free Convection using chtMultiRegionFoam - wrong results peterhess OpenFOAM Running, Solving & CFD 1 May 23, 2016 02:34
fully developed channel flow with kOmega, wrong results boshynova OpenFOAM Programming & Development 1 April 20, 2016 11:54


All times are GMT -4. The time now is 16:12.