diff --git a/src/functionObjects/field/Make/options b/src/functionObjects/field/Make/options index efaea7c1b8..2372619dd3 100644 --- a/src/functionObjects/field/Make/options +++ b/src/functionObjects/field/Make/options @@ -14,6 +14,7 @@ EXE_INC = \ -I$(LIB_SRC)/TurbulenceModels/compressible/lnInclude \ -I$(LIB_SRC)/transportModels/compressible/lnInclude \ -I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \ + -I$(LIB_SRC)/thermophysicalModels/solidThermo/lnInclude \ -I$(LIB_SRC)/thermophysicalModels/chemistryModel/lnInclude \ -I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \ -I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \ @@ -31,6 +32,7 @@ LIB_LIBS = \ -lsampling \ -lsurfMesh \ -lfluidThermophysicalModels \ + -lsolidThermo \ -lincompressibleTransportModels \ -lturbulenceModels \ -lcompressibleTransportModels \ diff --git a/src/functionObjects/field/wallHeatFlux/wallHeatFlux.C b/src/functionObjects/field/wallHeatFlux/wallHeatFlux.C index c0b7ea4f51..e4984c478a 100644 --- a/src/functionObjects/field/wallHeatFlux/wallHeatFlux.C +++ b/src/functionObjects/field/wallHeatFlux/wallHeatFlux.C @@ -24,6 +24,8 @@ License \*---------------------------------------------------------------------------*/ #include "wallHeatFlux.H" +#include "turbulentFluidThermoModel.H" +#include "solidThermo.H" #include "surfaceInterpolate.H" #include "fvcSnGrad.H" #include "wallPolyPatch.H" @@ -196,10 +198,7 @@ bool Foam::functionObjects::wallHeatFlux::read(const dictionary& dict) bool Foam::functionObjects::wallHeatFlux::execute() { - volScalarField& wallHeatFlux = const_cast - ( - lookupObject(type()) - ); + volScalarField& wallHeatFlux = lookupObjectRef(type()); if ( @@ -234,6 +233,13 @@ bool Foam::functionObjects::wallHeatFlux::execute() wallHeatFlux ); } + else if (foundObject(solidThermo::dictName)) + { + const solidThermo& thermo = + lookupObject(solidThermo::dictName); + + calcHeatFlux(thermo.alpha(), thermo.he(), wallHeatFlux); + } else { FatalErrorInFunction diff --git a/src/functionObjects/field/wallHeatFlux/wallHeatFlux.H b/src/functionObjects/field/wallHeatFlux/wallHeatFlux.H index c5530f057e..bfa3326956 100644 --- a/src/functionObjects/field/wallHeatFlux/wallHeatFlux.H +++ b/src/functionObjects/field/wallHeatFlux/wallHeatFlux.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2016 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2016-2017 OpenFOAM Foundation \\/ M anipulation | Copyright (C) 2016 OpenCFD Ltd. ------------------------------------------------------------------------------- License @@ -42,6 +42,7 @@ Usage type wallHeatFlux; libs ("libfieldFunctionObjects.so"); ... + region fluid; patches (".*Wall"); } \endverbatim @@ -52,6 +53,7 @@ Usage type | type name: wallHeatFlux | yes | patches | list of patches to process | no | all wall patches qr | name of radiative heat flux field | no | qr + region | region to be evaluated | no | default region \endtable See also