www.mooseframework.org
IdealGasFreeEnergy.C
Go to the documentation of this file.
1 /****************************************************************/
2 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
3 /* */
4 /* All contents are licensed under LGPL V2.1 */
5 /* See LICENSE for full restrictions */
6 /****************************************************************/
7 #include "IdealGasFreeEnergy.h"
8 
9 template <>
10 InputParameters
12 {
13  InputParameters params = validParams<GasFreeEnergyBase>();
14  params.addClassDescription("Free energy of an ideal gas.");
15  return params;
16 }
17 
18 IdealGasFreeEnergy::IdealGasFreeEnergy(const InputParameters & parameters)
19  : GasFreeEnergyBase(parameters)
20 {
21  // Definition of the free energy for the expression builder
22  EBFunction free_energy;
23  free_energy(_c, _T) = -_n * _kB * _T * (log(_nq / _n) + 1.0);
24 
25  // Parse function for automatic differentiation
26  functionParse(free_energy);
27 }
const EBTerm _n
gas number density n = N/V = c/Omega (where Omega is the lattice site volume)
InputParameters validParams< IdealGasFreeEnergy >()
const EBTerm _nq
quantum concentration
User facing host object for a function. This combines a term with an argument list.
InputParameters validParams< GasFreeEnergyBase >()
const EBTerm _T
Coupled variable value for the Temperature.
void functionParse(const std::string &function_expression)
Material class that provides the free energy of an ideal gas with the expression builder and uses aut...
IdealGasFreeEnergy(const InputParameters &parameters)
const EBTerm _c
Coupled variable value for the concentration .