本文整理汇总了C++中patchInternalField函数的典型用法代码示例。如果您正苦于以下问题:C++ patchInternalField函数的具体用法?C++ patchInternalField怎么用?C++ patchInternalField使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了patchInternalField函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: patchInternalField
// Update the coefficients associated with the patch field
void nusseltFvPatchScalarField::updateCoeffs()
{
if (updated())
{
return;
}
scalarField Tinternal = patchInternalField();
// Lookup temperature diffusivity of the patch
const fvPatchField<scalar>& DT =
this->patch().lookupPatchField<volScalarField, scalar>(DTName_);
// Calculate flux
scalarField tempFlux = alpha_*(Tinternal - Tinf_);
refValue() =
neg(tempFlux)*
min
(
Tinternal - tempFlux/(DT*patch().deltaCoeffs()),
Tinf_
)
+ pos(tempFlux)*
max
(
Tinternal - tempFlux/(DT*patch().deltaCoeffs()),
Tinf_
);
refGrad() = -tempFlux;
valueFraction() = pos(tempFlux);
mixedFvPatchScalarField::updateCoeffs();
}
开发者ID:GoldenMan123,项目名称:openfoam-extend-foam-extend-3.1,代码行数:36,代码来源:nusseltFvPatchScalarField.C
示例2: fixedGradientFvPatchScalarField
inviscidWallPFvPatchScalarField::inviscidWallPFvPatchScalarField
(
const fvPatch& p,
const DimensionedField<scalar, volMesh>& iF,
const dictionary& dict
)
:
fixedGradientFvPatchScalarField(p, iF),
fluxFraction_(readScalar(dict.lookup("fluxFraction")))
{
if (dict.found("gradient"))
{
gradient() = scalarField("gradient", dict, p.size());
fixedGradientFvPatchScalarField::updateCoeffs();
fixedGradientFvPatchScalarField::evaluate();
}
else
{
fvPatchField<scalar>::operator=(patchInternalField());
gradient() = 0.0;
}
if (fluxFraction_<0.0 || fluxFraction_ > 1.0)
{
FatalIOErrorIn
(
"inviscidWallPFvPatchScalarField::"
"supersonicFreeStreamFvPatchVectorField"
"(const fvPatch&, const scalarField&, const dictionary&)",
dict
) << " unphysical fluxFraction specified (< 0.0 or > 1.0)"
<< exit(FatalIOError);
}
}
开发者ID:GoldenMan123,项目名称:openfoam-extend-foam-extend-3.1,代码行数:35,代码来源:inviscidWallPFvPatchScalarField.C
示例3: patchInternalField
Foam::tmp<Foam::labelField> Foam::overlapGgiFvPatch::interfaceInternalField
(
const unallocLabelList& internalData
) const
{
return patchInternalField(internalData);
}
开发者ID:TsukasaHori,项目名称:openfoam-extend-foam-extend-3.1,代码行数:7,代码来源:overlapGgiFvPatch.C
示例4: patchInternalField
tmp<labelField> cyclicFvPatch::interfaceInternalField
(
const unallocLabelList& internalData
) const
{
return patchInternalField(internalData);
}
开发者ID:TsukasaHori,项目名称:openfoam-extend-foam-extend-3.1,代码行数:7,代码来源:cyclicFvPatch.C
示例5: patchInternalField
Foam::tmp<Foam::labelField> Foam::regionCoupleFvPatch::interfaceInternalField
(
const unallocLabelList& internalData
) const
{
return patchInternalField(internalData);
}
开发者ID:CFMS,项目名称:foam-extend-foam-extend-3.2,代码行数:7,代码来源:regionCoupleFvPatch.C
示例6: tpNeighbour
void
ProcessorPointPatchField
<PatchField, Mesh, PointPatch, ProcessorPointPatch, MatrixType, Type>::
evaluate
(
const Pstream::commsTypes commsType
)
{
if (this->isPointField())
{
// Get the neighbour side values
tmp<Field<Type> > tpNeighbour = receivePointField<Type>(commsType);
Field<Type>& tpn = tpNeighbour();
if (doTransform())
{
const processorPolyPatch& ppp = procPatch_.procPolyPatch();
const tensorField& forwardT = ppp.forwardT();
transform(tpn, forwardT[0], tpn);
}
// Average over two sides
tpn = 0.5*(patchInternalField(this->internalField()) + tpn);
// Get internal field to insert values into
Field<Type>& iF = const_cast<Field<Type>&>(this->internalField());
this->setInInternalField(iF, tpn);
}
}
开发者ID:Unofficial-Extend-Project-Mirror,项目名称:openfoam-extend-Core-OpenFOAM-1.5-dev,代码行数:31,代码来源:ProcessorPointPatchField.C
示例7: patchInternalField
tmp<Field<Type1> > pointPatchField<Type>::patchInternalField
(
const Field<Type1>& iF
) const
{
return patchInternalField(iF, patch().meshPoints());
}
开发者ID:hokieengr,项目名称:OpenFOAM-dev,代码行数:7,代码来源:pointPatchField.C
示例8: patchInternalField
Foam::tmp<Foam::labelField> Foam::mixingPlaneFvPatch::interfaceInternalField
(
const unallocLabelList& internalData
) const
{
return patchInternalField(internalData);
}
开发者ID:Unofficial-Extend-Project-Mirror,项目名称:openfoam-extend-foam-extend-3.0,代码行数:7,代码来源:mixingPlaneFvPatch.C
示例9: fixedGradientFvPatchScalarField
fixedFluxPressureFvPatchScalarField::fixedFluxPressureFvPatchScalarField
(
const fvPatch& p,
const DimensionedField<scalar, volMesh>& iF,
const dictionary& dict
)
:
fixedGradientFvPatchScalarField(p, iF),
UName_(dict.lookup("U")),
phiName_(dict.lookup("phi")),
rhoName_(dict.lookup("rho")),
adjoint_(dict.lookup("adjoint"))
{
if (dict.found("gradient"))
{
gradient() = scalarField("gradient", dict, p.size());
fixedGradientFvPatchScalarField::updateCoeffs();
fixedGradientFvPatchScalarField::evaluate();
}
else
{
fvPatchField<scalar>::operator=(patchInternalField());
gradient() = 0.0;
}
}
开发者ID:Unofficial-Extend-Project-Mirror,项目名称:openfoam-extend-Core-OpenFOAM-1.5-dev,代码行数:25,代码来源:fixedFluxPressureFvPatchScalarField.C
示例10: patchInternalField
Foam::tmp<Foam::labelField> Foam::cyclicACMIFvPatch::interfaceInternalField
(
const labelUList& internalData
) const
{
return patchInternalField(internalData);
}
开发者ID:Kiiree,项目名称:RapidCFD-dev,代码行数:7,代码来源:cyclicACMIFvPatch.C
示例11: patchInternalField
Foam::tmp<Foam::labelgpuField> Foam::regionCoupledFvPatch::interfaceInternalField
(
const labelgpuList& internalData
) const
{
return patchInternalField(internalData);
}
开发者ID:Benjamin-git,项目名称:RapidCFD-dev,代码行数:7,代码来源:regionCoupledFvPatch.C
示例12: mixedFvPatchScalarField
smoluchowskiJumpTFvPatchScalarField::smoluchowskiJumpTFvPatchScalarField
(
const fvPatch& p,
const DimensionedField<scalar, volMesh>& iF,
const dictionary& dict
)
:
mixedFvPatchScalarField(p, iF),
accommodationCoeff_(readScalar(dict.lookup("accommodationCoeff"))),
Twall_("Twall", dict, p.size())
{
if
(
mag(accommodationCoeff_) < SMALL
||
mag(accommodationCoeff_) > 2.0
)
{
FatalIOErrorIn
(
"smoluchowskiJumpTFvPatchScalarField::"
"smoluchowskiJumpTFvPatchScalarField"
"("
" const fvPatch&,"
" const DimensionedField<scalar, volMesh>&,"
" const dictionary&"
")",
dict
) << "unphysical accommodationCoeff_ specified"
<< "(0 < accommodationCoeff_ <= 1)" << endl
<< exit(FatalError);
}
if (dict.found("value"))
{
fvPatchField<scalar>::operator=
(
scalarField("value", dict, p.size())
);
}
else
{
fvPatchField<scalar>::operator=(patchInternalField());
}
if (dict.found("gamma"))
{
gamma_ = readScalar(dict.lookup("gamma"));
}
else
{
gamma_ = 1.4;
}
refValue() = *this;
refGrad() = 0.0;
valueFraction() = 0.0;
}
开发者ID:Unofficial-Extend-Project-Mirror,项目名称:openfoam-extend-Core-OpenFOAM-1.5-dev,代码行数:58,代码来源:smoluchowskiJumpTFvPatchScalarField.C
示例13: mixedFvPatchScalarField
nusseltFvPatchScalarField::nusseltFvPatchScalarField
(
const fvPatch& p,
const DimensionedField<scalar, volMesh>& iF,
const dictionary& dict
)
:
mixedFvPatchScalarField(p, iF),
DTName_(dict.lookup("DT")),
Tinf_(readScalar(dict.lookup("Tinf"))),
alpha_("alpha", dict, p.size())
{
if (dict.found("value"))
{
fvPatchField<scalar>::operator=
(
scalarField("value", dict, p.size())
);
}
else
{
fvPatchField<scalar>::operator=(patchInternalField());
}
refValue() = *this;
refGrad() = 0.0;
valueFraction() = 0.0;
if (Tinf_ < SMALL)
{
FatalIOErrorIn
(
"nusseltFvPatchScalarField::nusseltFvPatchScalarField\n"
"(\n"
" const fvPatch&,\n"
" const DimensionedField<scalar, volMesh>&,\n"
" const dictionary&\n"
")",
dict
) << "unphysical Tinf specified (Tinf = 0 or negative)"
<< exit(FatalError);
}
if (min(alpha_) < -SMALL)
{
FatalIOErrorIn
(
"nusseltFvPatchScalarField::nusseltFvPatchScalarField\n"
"(\n"
" const fvPatch&,\n"
" const DimensionedField<scalar, volMesh>&,\n"
" const dictionary&\n"
")",
dict
) << "unphysical alpha specified (alpha = 0 or negative)" << endl
<< exit(FatalError);
}
}
开发者ID:GoldenMan123,项目名称:openfoam-extend-foam-extend-3.1,代码行数:58,代码来源:nusseltFvPatchScalarField.C
示例14: updateCoeffs
void wedgeFvPatchField<scalar>::evaluate(const Pstream::commsTypes)
{
if (!updated())
{
updateCoeffs();
}
operator==(patchInternalField());
}
开发者ID:AmaneShino,项目名称:OpenFOAM-2.0.x,代码行数:9,代码来源:wedgeFvPatchScalarField.C
示例15: sendField
void ProcessorPointPatchField
<PatchField, Mesh, PointPatch, ProcessorPointPatch, MatrixType, Type>::
initAddFieldTempl
(
const Pstream::commsTypes commsType,
const Field<Type2>& pField
) const
{
sendField(patchInternalField(pField), commsType);
}
开发者ID:Unofficial-Extend-Project-Mirror,项目名称:openfoam-extend-Core-OpenFOAM-1.5-dev,代码行数:10,代码来源:ProcessorPointPatchField.C
示例16: mixedFvPatchScalarField
Foam::smoluchowskiJumpTFvPatchScalarField::smoluchowskiJumpTFvPatchScalarField
(
const fvPatch& p,
const DimensionedField<scalar, volMesh>& iF,
const dictionary& dict
)
:
mixedFvPatchScalarField(p, iF),
UName_(dict.lookupOrDefault<word>("U", "U")),
rhoName_(dict.lookupOrDefault<word>("rho", "rho")),
psiName_(dict.lookupOrDefault<word>("psi", "thermo:psi")),
muName_(dict.lookupOrDefault<word>("mu", "thermo:mu")),
accommodationCoeff_(readScalar(dict.lookup("accommodationCoeff"))),
Twall_("Twall", dict, p.size()),
gamma_(dict.lookupOrDefault<scalar>("gamma", 1.4))
{
if
(
mag(accommodationCoeff_) < SMALL
|| mag(accommodationCoeff_) > 2.0
)
{
FatalIOErrorIn
(
"smoluchowskiJumpTFvPatchScalarField::"
"smoluchowskiJumpTFvPatchScalarField"
"("
" const fvPatch&,"
" const DimensionedField<scalar, volMesh>&,"
" const dictionary&"
")",
dict
) << "unphysical accommodationCoeff specified"
<< "(0 < accommodationCoeff <= 1)" << endl
<< exit(FatalIOError);
}
if (dict.found("value"))
{
fvPatchField<scalar>::operator=
(
scalarField("value", dict, p.size())
);
}
else
{
fvPatchField<scalar>::operator=(patchInternalField());
}
refValue() = *this;
refGrad() = 0.0;
valueFraction() = 0.0;
}
开发者ID:BarisCumhur,项目名称:OpenFOAM-2.3.x,代码行数:53,代码来源:smoluchowskiJumpTFvPatchScalarField.C
示例17: updateCoeffs
void Foam::basicSymmetryFvPatchField<Foam::scalar>::evaluate
(
const Pstream::commsTypes
)
{
if (!updated())
{
updateCoeffs();
}
scalargpuField::operator=(patchInternalField());
transformFvPatchField<scalar>::evaluate();
}
开发者ID:Kiiree,项目名称:RapidCFD-dev,代码行数:13,代码来源:basicSymmetryFvPatchScalarField.C
示例18: fixedGradientFvPatchScalarField
geostrophicZeroFluxFvPatchScalarField::
geostrophicZeroFluxFvPatchScalarField
(
const fvPatch& p,
const DimensionedField<scalar, volMesh>& iF,
const dictionary&
)
:
fixedGradientFvPatchScalarField(p, iF)
{
fvPatchField<scalar>::operator=(patchInternalField());
gradient() = 0.0;
}
开发者ID:AtmosFOAM,项目名称:AtmosFOAM,代码行数:13,代码来源:geostrophicZeroFluxFvPatchScalarField.C
示例19: fixedGradientFvPatchScalarField
extrapolatedGradientFvPatchScalarField::
extrapolatedGradientFvPatchScalarField
(
const fvPatch& p,
const DimensionedField<scalar, volMesh>& iF,
const dictionary& dict
)
:
fixedGradientFvPatchScalarField(p, iF)
{
fvPatchField<scalar>::operator=(patchInternalField());
gradient() = 0.0;
}
开发者ID:olegrog,项目名称:openfoam,代码行数:13,代码来源:extrapolatedGradientFvPatchScalarField.C
示例20: fixedGradientFvPatchScalarField
buoyantPressureFvPatchScalarField::
buoyantPressureFvPatchScalarField
(
const fvPatch& p,
const DimensionedField<scalar, volMesh>& iF,
const dictionary& dict
)
:
fixedGradientFvPatchScalarField(p, iF),
rhoName_(dict.lookupOrDefault<word>("rho", "rho"))
{
fvPatchField<scalar>::operator=(patchInternalField());
gradient() = 0.0;
}
开发者ID:Ingenierias2003,项目名称:OpenFOAM-1.7.x,代码行数:14,代码来源:buoyantPressureFvPatchScalarField.C
注:本文中的patchInternalField函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论