本文整理汇总了C++中tmp::clear方法的典型用法代码示例。如果您正苦于以下问题:C++ tmp::clear方法的具体用法?C++ tmp::clear怎么用?C++ tmp::clear使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类tmp
的用法示例。
在下文中一共展示了tmp::clear方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: tvf
tmp<GeometricField<Type, faPatchField, areaMesh> > laplacian
(
const tmp<edgeScalarField>& tgamma,
const tmp<GeometricField<Type, faPatchField, areaMesh> >& tvf
)
{
tmp<GeometricField<Type, faPatchField, areaMesh> > Laplacian
(
fac::laplacian(tgamma(), tvf())
);
tgamma.clear();
tvf.clear();
return Laplacian;
}
示例2: tvf
tmp<GeometricField<Type, fvPatchField, volMesh> > laplacian
(
const tmp<GeometricField<GType, fvsPatchField, surfaceMesh> >& tgamma,
const tmp<GeometricField<Type, fvPatchField, volMesh> >& tvf
)
{
tmp<GeometricField<Type, fvPatchField, volMesh> > Laplacian
(
fvc::laplacian(tgamma(), tvf())
);
tgamma.clear();
tvf.clear();
return Laplacian;
}
示例3: tvf
tmp<GeometricField<Type, faPatchField, areaMesh> >
div
(
const tmp<edgeScalarField>& tflux,
const tmp<GeometricField<Type, faPatchField, areaMesh> >& tvf
)
{
tmp<GeometricField<Type, faPatchField, areaMesh> > Div
(
fac::div(tflux(), tvf())
);
tflux.clear();
tvf.clear();
return Div;
}
示例4: tvf
tmp<GeometricField<Type, fvPatchField, volMesh> >
div
(
const tmp<surfaceScalarField>& tflux,
const tmp<GeometricField<Type, fvPatchField, volMesh> >& tvf
)
{
tmp<GeometricField<Type, fvPatchField, volMesh> > Div
(
fvc::div(tflux(), tvf())
);
tflux.clear();
tvf.clear();
return Div;
}
示例5: tvf
tmp<GeometricField<Type, fvsPatchField, surfaceMesh>>
flux
(
const tmp<surfaceScalarField>& tphi,
const tmp<GeometricField<Type, fvPatchField, volMesh>>& tvf
)
{
tmp<GeometricField<Type, fvsPatchField, surfaceMesh>> Flux
(
fvc::flux(tphi(), tvf())
);
tphi.clear();
tvf.clear();
return Flux;
}
示例6: tfaceHpsi
Foam::tmp<Foam::gpuField<Type> >
Foam::lduMatrix::faceH(const tmp<gpuField<Type> >& tpsi) const
{
tmp<gpuField<Type> > tfaceHpsi(faceH(tpsi()));
tpsi.clear();
return tfaceHpsi;
}
示例7: tdf
tmp<gpuField<Type> >
volumeIntegrate(const tmp<DimensionedField<Type, volMesh> >& tdf)
{
tmp<gpuField<Type> > tdidf = tdf().mesh().V()*tdf().field();
tdf.clear();
return tdidf;
}
示例8: tfield
tmp<complexVectorField> fft::reverseTransform
(
const tmp<complexVectorField>& tfield,
const labelList& nn
)
{
tmp<complexVectorField> tifftVectorField
(
new complexVectorField
(
tfield().size()
)
);
for (direction cmpt=0; cmpt<vector::nComponents; cmpt++)
{
tifftVectorField().replace
(
cmpt,
reverseTransform(tfield().component(cmpt), nn)
);
}
tfield.clear();
return tifftVectorField;
}
示例9:
tmp
<
GeometricField
<
typename outerProduct<vector,Type>::type, faPatchField, areaMesh
>
>
grad
(
const tmp<GeometricField<Type, faPatchField, areaMesh> >& tvf,
const word& name
)
{
tmp
<
GeometricField
<
typename outerProduct<vector, Type>::type, faPatchField, areaMesh
>
> tGrad
(
fac::grad(tvf(), name)
);
tvf.clear();
return tGrad;
}
示例10: tpsi
void Foam::lduMatrix::Amul
(
scalarField& Apsi,
const tmp<scalarField>& tpsi,
const FieldField<Field, scalar>& interfaceBouCoeffs,
const lduInterfaceFieldPtrsList& interfaces,
const direction cmpt
) const
{
scalar* __restrict__ ApsiPtr = Apsi.begin();
const scalarField& psi = tpsi();
const scalar* const __restrict__ psiPtr = psi.begin();
const scalar* const __restrict__ diagPtr = diag().begin();
const label* const __restrict__ uPtr = lduAddr().upperAddr().begin();
const label* const __restrict__ lPtr = lduAddr().lowerAddr().begin();
const scalar* const __restrict__ upperPtr = upper().begin();
const scalar* const __restrict__ lowerPtr = lower().begin();
// Initialise the update of interfaced interfaces
initMatrixInterfaces
(
interfaceBouCoeffs,
interfaces,
psi,
Apsi,
cmpt
);
const label nCells = diag().size();
for (label cell=0; cell<nCells; cell++)
{
ApsiPtr[cell] = diagPtr[cell]*psiPtr[cell];
}
const label nFaces = upper().size();
for (label face=0; face<nFaces; face++)
{
ApsiPtr[uPtr[face]] += lowerPtr[face]*psiPtr[lPtr[face]];
ApsiPtr[lPtr[face]] += upperPtr[face]*psiPtr[uPtr[face]];
}
// Update interface interfaces
updateMatrixInterfaces
(
interfaceBouCoeffs,
interfaces,
psi,
Apsi,
cmpt
);
tpsi.clear();
}
示例11: calculate
Foam::boundBox::boundBox(const tmp<pointField>& points, const bool doReduce)
:
min_(Zero),
max_(Zero)
{
calculate(points(), doReduce);
points.clear();
}
示例12: domainIntegrate
dimensioned<Type> domainIntegrate
(
const tmp<DimensionedField<Type, volMesh> >& tdf
)
{
dimensioned<Type> integral = domainIntegrate(tdf());
tdf.clear();
return integral;
}
示例13: sample
Foam::tmp<Foam::Field<Type> > Foam::cuttingPlane::sample
(
const tmp<Field<Type> >& tsf
) const
{
tmp<Field<Type> > tint = sample(tsf());
tsf.clear();
return tint;
}
开发者ID:Unofficial-Extend-Project-Mirror,项目名称:openfoam-extend-Core-OpenFOAM-1.5-dev,代码行数:9,代码来源:cuttingPlaneSample.C
示例14: weightedAverage
dimensioned<Type> DimensionedField<Type, GeoMesh>::weightedAverage
(
const tmp<DimensionedField<scalar, GeoMesh> >& tweightField
) const
{
dimensioned<Type> wa = weightedAverage(tweightField());
tweightField.clear();
return wa;
}
示例15: sample
Foam::tmp<Foam::Field<Type> > Foam::cuttingPlane::sample
(
const tmp<Field<Type> >& tfld
) const
{
tmp<Field<Type> > tsf = sample(tfld());
tfld.clear();
return tsf;
}