41 const DimensionedField<vector, volMesh>& iF
44 partialSlipFvPatchVectorField(
p, iF),
47 psiName_(
"thermo:psi"),
50 accommodationCoeff_(1.0),
51 Uwall_(
p.size(),
Zero),
59 const maxwellSlipUFvPatchVectorField& mspvf,
61 const DimensionedField<vector, volMesh>& iF,
62 const fvPatchFieldMapper& mapper
65 partialSlipFvPatchVectorField(mspvf,
p, iF, mapper),
67 rhoName_(mspvf.rhoName_),
68 psiName_(mspvf.psiName_),
69 muName_(mspvf.muName_),
70 tauMCName_(mspvf.tauMCName_),
71 accommodationCoeff_(mspvf.accommodationCoeff_),
73 thermalCreep_(mspvf.thermalCreep_),
74 curvature_(mspvf.curvature_)
81 const DimensionedField<vector, volMesh>& iF,
82 const dictionary&
dict 85 partialSlipFvPatchVectorField(
p, iF),
86 TName_(
dict.getOrDefault<word>(
"T",
"T")),
87 rhoName_(
dict.getOrDefault<word>(
"rho",
"rho")),
88 psiName_(
dict.getOrDefault<word>(
"psi",
"thermo:psi")),
89 muName_(
dict.getOrDefault<word>(
"mu",
"thermo:mu")),
90 tauMCName_(
dict.getOrDefault<word>(
"tauMC",
"tauMC")),
91 accommodationCoeff_(
dict.
get<scalar>(
"accommodationCoeff")),
92 Uwall_(
"Uwall",
dict,
p.size()),
93 thermalCreep_(
dict.getOrDefault(
"thermalCreep", true)),
94 curvature_(
dict.getOrDefault(
"curvature", true))
98 mag(accommodationCoeff_) < SMALL
99 ||
mag(accommodationCoeff_) > 2.0
103 <<
"unphysical accommodationCoeff_ specified" 104 <<
"(0 < accommodationCoeff_ <= 1)" <<
endl 108 if (this->readValueEntry(
dict))
113 if (hasRefValue && hasFrac)
115 this->refValue().assign(*hasRefValue,
p.size());
116 this->valueFraction().assign(*hasFrac,
p.size());
120 this->refValue() = *
this;
121 this->valueFraction() = scalar(1);
129 const maxwellSlipUFvPatchVectorField& mspvf,
130 const DimensionedField<vector, volMesh>& iF
133 partialSlipFvPatchVectorField(mspvf, iF),
134 TName_(mspvf.TName_),
135 rhoName_(mspvf.rhoName_),
136 psiName_(mspvf.psiName_),
137 muName_(mspvf.muName_),
138 tauMCName_(mspvf.tauMCName_),
139 accommodationCoeff_(mspvf.accommodationCoeff_),
140 Uwall_(mspvf.Uwall_),
141 thermalCreep_(mspvf.thermalCreep_),
142 curvature_(mspvf.curvature_)
162 * (2.0 - accommodationCoeff_)/accommodationCoeff_
165 Field<scalar> pnu(pmu/prho);
166 valueFraction() = (1.0/(1.0 +
patch().deltaCoeffs()*C1*pnu));
174 label patchi = this->
patch().index();
176 Field<vector> gradpT(
fvc::grad(vsfT)().boundaryField()[patchi]);
179 refValue() -= 3.0*pnu/(4.0*pT)*
transform(
I -
n*
n, gradpT);
191 partialSlipFvPatchVectorField::updateCoeffs();
204 os.
writeEntry(
"accommodationCoeff", accommodationCoeff_);
223 maxwellSlipUFvPatchVectorField
List< ReturnType > get(const UPtrList< T > &list, const AccessOp &aop)
List of values generated by applying the access operation to each list item.
tmp< GeometricField< typename outerProduct< vector, Type >::type, fvPatchField, volMesh >> grad(const GeometricField< Type, fvsPatchField, surfaceMesh > &ssf)
virtual void write(Ostream &) const
Write.
fvPatchField< vector > fvPatchVectorField
errorManipArg< error, int > exit(error &err, const int errNo=1)
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
GeometricField< tensor, fvPatchField, volMesh > volTensorField
dimensionedScalar sqrt(const dimensionedScalar &ds)
Ostream & endl(Ostream &os)
Add newline and flush stream.
Ostream & writeEntry(const keyType &key, const T &value)
Write a keyword/value entry.
void writeValueEntry(Ostream &os) const
Write *this field as a "value" entry.
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
virtual void write(Ostream &) const
Write.
Macros for easy insertion into run-time selection tables.
GeometricField< scalar, fvPatchField, volMesh > volScalarField
static const Identity< scalar > I
fvPatchField< scalar > fvPatchScalarField
Calculate the gradient of the given field.
constexpr scalar piByTwo(0.5 *M_PI)
Ostream & writeEntryIfDifferent(const word &key, const T &value1, const T &value2)
Write a keyword/value entry only when the two values differ.
OBJstream os(runTime.globalPath()/outputName)
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
const std::string patch
OpenFOAM patch number as a std::string.
maxwellSlipUFvPatchVectorField(const fvPatch &, const DimensionedField< vector, volMesh > &)
Construct from patch and internal field.
Field< vector > vectorField
Specialisation of Field<T> for vector.
dimensionSet transform(const dimensionSet &ds)
Return the argument; transformations do not change the dimensions.
makePatchTypeField(fvPatchScalarField, atmBoundaryLayerInletEpsilonFvPatchScalarField)
IOerror FatalIOError
Error stream (stdout output on all processes), with additional 'FOAM FATAL IO ERROR' header text and ...
static constexpr const zero Zero
Global zero (0)