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

Where is the Boltzmann constant value set?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 11, 2018, 14:54
Default Where is the Boltzmann constant value set?
  #1
Member
 
Join Date: May 2014
Location: Germany
Posts: 31
Rep Power: 11
hester is on a distinguished road
Hello,

I am wondering where the Boltzmann constant value is set in OpenFOAM. The variable k is defined under src/OpenFOAM/global/constants/fundamental/fundamentalConstants.C.
I expected to find the value set here too, like for the Avogadro constant. (Actually, NA is the only value set her.)

Code:
 defineDimensionedConstantWithDefault
 (
     physicoChemical::group,
     physicoChemical::NA,
     Foam::dimensionedScalar
     (
         "NA",
         dimensionSet(0, 0, 0, 0, -1),
         6.0221417930e+23
     ),
     constantphysicoChemicalNA,
     "NA"
 );

 defineDimensionedConstant
 (
     physicoChemical::group,
     physicoChemical::k,
     constantphysicoChemicalk,
     "k"
 );
I also tried the doxygen documentation, but it only leads to the turbulence k value or some integer k in the LISA atomization method.

If anyone can point me in the right direction, I would be very grateful.

Regards,
hester
hester is offline   Reply With Quote

Old   June 12, 2018, 23:30
Default
  #2
Member
 
Martin
Join Date: Dec 2011
Posts: 40
Rep Power: 14
msaravia is on a distinguished road
The Boltzman's constant is is taken as variable by fundamentalConstants.H. Actuallyit is defined at line 41 of file LISASMDCalcMethod2.H. Check https://cpp.openfoam.org/v5/fundamen...stants_8H.html.
msaravia is offline   Reply With Quote

Old   June 13, 2018, 05:14
Default
  #3
Member
 
Join Date: May 2014
Location: Germany
Posts: 31
Rep Power: 11
hester is on a distinguished road
Hello msaravia,

thank you for your reply.
If you look at your mentioned source code, you will see that k in this file is not the Boltzmann constant but it is an integer used for iteration. This is the file the doxygen documentation will lead you to if your looking for physicoChemical::k (as mentioned in my initial post).

Regards,
hester
hester is offline   Reply With Quote

Old   June 17, 2018, 04:55
Default
  #4
Member
 
Vince
Join Date: Mar 2017
Posts: 45
Rep Power: 9
hyFoam is on a distinguished road
Hi Hester,


The Boltzmann constant value is given in $WM_PROJECT_DIR/etc/controlDict



Code:
DimensionedConstants
{
    unitSet             SI; // USCS

    SICoeffs
    {
        physicoChemical
        {
            mu              mu [1 0 0 0 0 0 0] 1.66054e-27;
            k               k [1 2 -2 -1 0 0 0] 1.38065e-23;
        }
    }
}
Thanks,


Vince
hyFoam is offline   Reply With Quote

Old   June 18, 2018, 04:47
Default
  #5
Member
 
Join Date: May 2014
Location: Germany
Posts: 31
Rep Power: 11
hester is on a distinguished road
Hi Vince,


this is exactly what I was looking for.
Thank you!


hester
hester is offline   Reply With Quote

Reply

Tags
boltzmann constant


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
[ICEM] ICEM Scripting Issues tylerplowright ANSYS Meshing & Geometry 33 September 27, 2021 16:35
decomposePar problem: Cell 0contains face labels out of range vaina74 OpenFOAM Pre-Processing 37 July 20, 2020 05:38
How to set a initial temperature and constant heat flux at same BC's?? Jane FLUENT 4 October 25, 2015 12:01
[ICEM] Question about the use of ICEM tcl scripting lnk ANSYS Meshing & Geometry 9 January 16, 2013 09:24
Env variable not set gruber2 OpenFOAM Installation 5 December 30, 2005 04:27


All times are GMT -4. The time now is 13:09.