Public Types | Public Member Functions | Static Public Attributes | Private Attributes
externalWallHeatFluxTemperatureFvPatchScalarField Class Reference

This boundary condition supplies a heat flux condition for temperature on an external wall. Optional thin thermal layer resistances can be specified through thicknessLayers and kappaLayers entries for the fixed heat transfer coefficient mode. More...

Inheritance diagram for externalWallHeatFluxTemperatureFvPatchScalarField:
Inheritance graph
[legend]
Collaboration diagram for externalWallHeatFluxTemperatureFvPatchScalarField:
Collaboration graph
[legend]

Public Types

enum  operationMode { fixedHeatFlux, fixedHeatTransferCoeff, unknown }
 Operation mode enumeration. More...
 
- Public Types inherited from temperatureCoupledBase
enum  KMethodType { mtFluidThermo, mtSolidThermo, mtDirectionalSolidThermo, mtLookup }
 Type of supplied Kappa. More...
 

Public Member Functions

 TypeName ("externalWallHeatFluxTemperature")
 Runtime type information. More...
 
 externalWallHeatFluxTemperatureFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &)
 Construct from patch and internal field. More...
 
 externalWallHeatFluxTemperatureFvPatchScalarField (const fvPatch &, const DimensionedField< scalar, volMesh > &, const dictionary &)
 Construct from patch, internal field and dictionary. More...
 
 externalWallHeatFluxTemperatureFvPatchScalarField (const externalWallHeatFluxTemperatureFvPatchScalarField &, const fvPatch &, const DimensionedField< scalar, volMesh > &, const fvPatchFieldMapper &)
 Construct by mapping given. More...
 
 externalWallHeatFluxTemperatureFvPatchScalarField (const externalWallHeatFluxTemperatureFvPatchScalarField &)
 Construct as copy. More...
 
virtual tmp< fvPatchScalarFieldclone () const
 Construct and return a clone. More...
 
 externalWallHeatFluxTemperatureFvPatchScalarField (const externalWallHeatFluxTemperatureFvPatchScalarField &, const DimensionedField< scalar, volMesh > &)
 Construct as copy setting internal field reference. More...
 
virtual tmp< fvPatchScalarFieldclone (const DimensionedField< scalar, volMesh > &iF) const
 Construct and return a clone setting internal field reference. More...
 
virtual void autoMap (const fvPatchFieldMapper &)
 Map (and resize as needed) from self given a mapping object. More...
 
virtual void rmap (const fvPatchScalarField &, const labelList &)
 Reverse map the given fvPatchField onto this fvPatchField. More...
 
virtual void updateCoeffs ()
 Update the coefficients associated with the patch field. More...
 
void write (Ostream &) const
 Write. More...
 
- Public Member Functions inherited from temperatureCoupledBase
 temperatureCoupledBase (const fvPatch &patch, const word &calculationMethod, const word &kappaName, const word &alphaAniName)
 Construct from patch and K name. More...
 
 temperatureCoupledBase (const fvPatch &patch, const dictionary &dict)
 Construct from patch and dictionary. More...
 
 temperatureCoupledBase (const fvPatch &patch, const temperatureCoupledBase &base)
 Construct from patch and temperatureCoupledBase. More...
 
word KMethod () const
 Method to obtain K. More...
 
const wordkappaName () const
 Name of thermal conductivity field. More...
 
tmp< scalarFieldkappa (const scalarField &Tp) const
 Given patch temperature calculate corresponding K field. More...
 
void write (Ostream &) const
 Write. More...
 

Static Public Attributes

static const NamedEnum< operationMode, 3 > operationModeNames
 

Private Attributes

operationMode mode_
 Operation mode. More...
 
scalarField q_
 Heat flux / [W/m2]. More...
 
scalarField h_
 Heat transfer coefficient / [W/m2K]. More...
 
scalarField Ta_
 Ambient temperature / [K]. More...
 
scalarField QrPrevious_
 Chache Qr for relaxation. More...
 
scalar QrRelaxation_
 Relaxation for Qr. More...
 
const word QrName_
 Name of the radiative heat flux. More...
 
scalarList thicknessLayers_
 Thickness of layers. More...
 
scalarList kappaLayers_
 Conductivity of layers. More...
 

Additional Inherited Members

- Protected Attributes inherited from temperatureCoupledBase
const fvPatchpatch_
 Underlying patch. More...
 
const KMethodType method_
 How to get K. More...
 
const word kappaName_
 Name of thermal conductivity field (if looked up from database) More...
 
const word alphaAniName_
 Name of the non-Isotropic alpha (default: Anialpha) More...
 
- Static Protected Attributes inherited from temperatureCoupledBase
static const NamedEnum< KMethodType, 4 > KMethodTypeNames_
 

Detailed Description

This boundary condition supplies a heat flux condition for temperature on an external wall. Optional thin thermal layer resistances can be specified through thicknessLayers and kappaLayers entries for the fixed heat transfer coefficient mode.

The condition can operate in two modes:

where:

$ h $ = heat transfer coefficient [W/m^2/K]
$ Ta $ = ambient temperature [K]
$ q $ = heat flux [W/m^2]

The thermal conductivity, kappa, can either be retrieved from the mesh database using the lookup option, or from a solidThermo thermophysical package.


Patch usage

Property Description Required Default value
kappa thermal conductivity option yes
q heat flux [W/m^2] yes*
Ta ambient temperature [K] yes*
h heat transfer coefficient [W/m^2/K] yes*
thicknessLayers list of thicknesses per layer [m] yes
kappaLayers list of thermal conductivites per layer [W/m/K] yes
kappaName name of thermal conductivity field yes
Qr name of the radiative field no no
relaxation relaxation factor for radiative field no 1

Example of the boundary condition specification:

    myPatch
    {
        type            externalWallHeatFluxTemperature;
        kappa           fluidThermo;
        q               uniform 1000;
        Ta              uniform 300.0;
        h               uniform 10.0;
        thicknessLayers (0.1 0.2 0.3 0.4);
        kappaLayers     (1 2 3 4);
        value           uniform 300.0;
        kappaName       none;
        Qr              none;
        relaxation      1;
    }
Note
  • Only supply h and Ta, or q in the dictionary (see above)
  • kappa entries can be: fluidThermo, solidThermo or lookup
Source files

Definition at line 170 of file externalWallHeatFluxTemperatureFvPatchScalarField.H.

Member Enumeration Documentation

◆ operationMode

Operation mode enumeration.

Enumerator
fixedHeatFlux 
fixedHeatTransferCoeff 
unknown 

Definition at line 180 of file externalWallHeatFluxTemperatureFvPatchScalarField.H.

Constructor & Destructor Documentation

◆ externalWallHeatFluxTemperatureFvPatchScalarField() [1/5]

Construct from patch and internal field.

Definition at line 62 of file externalWallHeatFluxTemperatureFvPatchScalarField.C.

Referenced by externalWallHeatFluxTemperatureFvPatchScalarField::clone().

Here is the caller graph for this function:

◆ externalWallHeatFluxTemperatureFvPatchScalarField() [2/5]

externalWallHeatFluxTemperatureFvPatchScalarField ( const fvPatch p,
const DimensionedField< scalar, volMesh > &  iF,
const dictionary dict 
)

Construct from patch, internal field and dictionary.

Definition at line 110 of file externalWallHeatFluxTemperatureFvPatchScalarField.C.

References dict, dimensionedInternalField(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, Foam::FatalIOError, FatalIOErrorInFunction, p, and scalarField().

Here is the call graph for this function:

◆ externalWallHeatFluxTemperatureFvPatchScalarField() [3/5]

Construct by mapping given.

externalWallHeatFluxTemperatureFvPatchScalarField onto a new patch

Definition at line 87 of file externalWallHeatFluxTemperatureFvPatchScalarField.C.

◆ externalWallHeatFluxTemperatureFvPatchScalarField() [4/5]

Construct as copy.

Definition at line 193 of file externalWallHeatFluxTemperatureFvPatchScalarField.C.

◆ externalWallHeatFluxTemperatureFvPatchScalarField() [5/5]

Construct as copy setting internal field reference.

Definition at line 213 of file externalWallHeatFluxTemperatureFvPatchScalarField.C.

Member Function Documentation

◆ TypeName()

TypeName ( "externalWallHeatFluxTemperature"  )

Runtime type information.

◆ clone() [1/2]

virtual tmp<fvPatchScalarField> clone ( ) const
inlinevirtual

Construct and return a clone.

Definition at line 263 of file externalWallHeatFluxTemperatureFvPatchScalarField.H.

References externalWallHeatFluxTemperatureFvPatchScalarField::externalWallHeatFluxTemperatureFvPatchScalarField().

Here is the call graph for this function:

◆ clone() [2/2]

virtual tmp<fvPatchScalarField> clone ( const DimensionedField< scalar, volMesh > &  iF) const
inlinevirtual

Construct and return a clone setting internal field reference.

Definition at line 280 of file externalWallHeatFluxTemperatureFvPatchScalarField.H.

References externalWallHeatFluxTemperatureFvPatchScalarField::externalWallHeatFluxTemperatureFvPatchScalarField().

Here is the call graph for this function:

◆ autoMap()

void autoMap ( const fvPatchFieldMapper m)
virtual

Map (and resize as needed) from self given a mapping object.

Definition at line 235 of file externalWallHeatFluxTemperatureFvPatchScalarField.C.

◆ rmap()

void rmap ( const fvPatchScalarField ptf,
const labelList addr 
)
virtual

◆ updateCoeffs()

void updateCoeffs ( )
virtual

◆ write()

void write ( Ostream os) const

Field Documentation

◆ operationModeNames

◆ mode_

operationMode mode_
private

◆ q_

scalarField q_
private

◆ h_

scalarField h_
private

◆ Ta_

scalarField Ta_
private

◆ QrPrevious_

scalarField QrPrevious_
private

◆ QrRelaxation_

scalar QrRelaxation_
private

◆ QrName_

const word QrName_
private

Name of the radiative heat flux.

Definition at line 213 of file externalWallHeatFluxTemperatureFvPatchScalarField.H.

Referenced by externalWallHeatFluxTemperatureFvPatchScalarField::updateCoeffs().

◆ thicknessLayers_

scalarList thicknessLayers_
private

◆ kappaLayers_

scalarList kappaLayers_
private

The documentation for this class was generated from the following files: