alphaSgsWallFunctionFvPatchScalarField.C
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027 #include "alphaSgsWallFunctionFvPatchScalarField.H"
00028 #include "LESModel.H"
00029 #include "fvPatchFieldMapper.H"
00030 #include "volFields.H"
00031 #include "addToRunTimeSelectionTable.H"
00032 #include "wallFvPatch.H"
00033
00034
00035
00036 namespace Foam
00037 {
00038 namespace compressible
00039 {
00040 namespace LESModels
00041 {
00042
00043
00044
00045 void alphaSgsWallFunctionFvPatchScalarField::checkType()
00046 {
00047 if (!isA<wallFvPatch>(patch()))
00048 {
00049 FatalErrorIn
00050 (
00051 "alphaSgsWallFunctionFvPatchScalarField::checkType()"
00052 )
00053 << "Patch type for patch " << patch().name() << " must be wall\n"
00054 << "Current patch type is " << patch().type() << nl
00055 << exit(FatalError);
00056 }
00057 }
00058
00059
00060
00061
00062 alphaSgsWallFunctionFvPatchScalarField::
00063 alphaSgsWallFunctionFvPatchScalarField
00064 (
00065 const fvPatch& p,
00066 const DimensionedField<scalar, volMesh>& iF
00067 )
00068 :
00069 fixedValueFvPatchScalarField(p, iF),
00070 Prt_(0.85)
00071 {
00072 checkType();
00073 }
00074
00075
00076 alphaSgsWallFunctionFvPatchScalarField::
00077 alphaSgsWallFunctionFvPatchScalarField
00078 (
00079 const alphaSgsWallFunctionFvPatchScalarField& ptf,
00080 const fvPatch& p,
00081 const DimensionedField<scalar, volMesh>& iF,
00082 const fvPatchFieldMapper& mapper
00083 )
00084 :
00085 fixedValueFvPatchScalarField(ptf, p, iF, mapper),
00086 Prt_(ptf.Prt_)
00087 {}
00088
00089
00090 alphaSgsWallFunctionFvPatchScalarField::
00091 alphaSgsWallFunctionFvPatchScalarField
00092 (
00093 const fvPatch& p,
00094 const DimensionedField<scalar, volMesh>& iF,
00095 const dictionary& dict
00096 )
00097 :
00098 fixedValueFvPatchScalarField(p, iF, dict),
00099 Prt_(dict.lookupOrDefault<scalar>("Prt", 0.85))
00100 {
00101 checkType();
00102 }
00103
00104
00105 alphaSgsWallFunctionFvPatchScalarField::
00106 alphaSgsWallFunctionFvPatchScalarField
00107 (
00108 const alphaSgsWallFunctionFvPatchScalarField& awfpsf
00109 )
00110 :
00111 fixedValueFvPatchScalarField(awfpsf),
00112 Prt_(awfpsf.Prt_)
00113 {
00114 checkType();
00115 }
00116
00117
00118 alphaSgsWallFunctionFvPatchScalarField::
00119 alphaSgsWallFunctionFvPatchScalarField
00120 (
00121 const alphaSgsWallFunctionFvPatchScalarField& awfpsf,
00122 const DimensionedField<scalar, volMesh>& iF
00123 )
00124 :
00125 fixedValueFvPatchScalarField(awfpsf, iF),
00126 Prt_(awfpsf.Prt_)
00127
00128 {
00129 checkType();
00130 }
00131
00132
00133
00134
00135 void alphaSgsWallFunctionFvPatchScalarField::evaluate
00136 (
00137 const Pstream::commsTypes
00138 )
00139 {
00140 const LESModel& lesModel = db().lookupObject<LESModel>("LESProperties");
00141
00142 const scalarField muSgsw =
00143 lesModel.muSgs()().boundaryField()[patch().index()];
00144
00145 operator==(muSgsw/Prt_);
00146 }
00147
00148
00149
00150
00151 makePatchTypeField
00152 (
00153 fvPatchScalarField,
00154 alphaSgsWallFunctionFvPatchScalarField
00155 );
00156
00157
00158
00159 }
00160 }
00161 }
00162
00163
Copyright © 2000-2009 OpenCFD Ltd