functionObjects::nearWallFields: Set patch types of the sampled field to calculated
Resolves bug-report https://bugs.openfoam.org/view.php?id=2729
This commit is contained in:
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -56,12 +56,21 @@ void Foam::functionObjects::nearWallFields::createFields
|
|||||||
label sz = sflds.size();
|
label sz = sflds.size();
|
||||||
sflds.setSize(sz+1);
|
sflds.setSize(sz+1);
|
||||||
|
|
||||||
IOobject io(fld);
|
sflds.set
|
||||||
io.readOpt() = IOobject::NO_READ;
|
(
|
||||||
io.writeOpt() = IOobject::NO_WRITE;
|
sz,
|
||||||
io.rename(sampleFldName);
|
new VolFieldType
|
||||||
|
(
|
||||||
sflds.set(sz, new VolFieldType(io, fld));
|
IOobject
|
||||||
|
(
|
||||||
|
sampleFldName,
|
||||||
|
time_.timeName(),
|
||||||
|
mesh_
|
||||||
|
),
|
||||||
|
fld,
|
||||||
|
calculatedFvPatchScalarField::typeName
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
Log << " created " << sflds[sz].name()
|
Log << " created " << sflds[sz].name()
|
||||||
<< " to sample " << fld.name() << endl;
|
<< " to sample " << fld.name() << endl;
|
||||||
|
|||||||
Reference in New Issue
Block a user