mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
BUG: writeMorpherCPs expects a controlBoxes entry
The controlBoxes wordList was removed from NURBS3DVolume in the pre-release phase but writeMorpherCPs was not updated accordingly. TUT: added the invocation of writeMorpherCPs in one of the tutotials to help identify future regression
This commit is contained in:
committed by
Andrew Heather
parent
227a0f5d43
commit
c413ec5009
@ -45,33 +45,37 @@ int main(int argc, char *argv[])
|
|||||||
#include "createTime.H"
|
#include "createTime.H"
|
||||||
#include "createMesh.H"
|
#include "createMesh.H"
|
||||||
|
|
||||||
IOdictionary dict
|
const dictionary NURBSdict
|
||||||
(
|
(
|
||||||
IOobject
|
IOdictionary
|
||||||
(
|
(
|
||||||
"dynamicMeshDict",
|
IOobject
|
||||||
mesh.time().constant(),
|
(
|
||||||
mesh,
|
"dynamicMeshDict",
|
||||||
IOobject::MUST_READ_IF_MODIFIED,
|
mesh.time().constant(),
|
||||||
IOobject::NO_WRITE
|
mesh,
|
||||||
)
|
IOobject::MUST_READ_IF_MODIFIED,
|
||||||
|
IOobject::NO_WRITE,
|
||||||
|
false
|
||||||
|
)
|
||||||
|
).subDict("volumetricBSplinesMotionSolverCoeffs")
|
||||||
);
|
);
|
||||||
|
// Read box names and allocate size
|
||||||
|
wordList controlBoxes(NURBSdict.toc());
|
||||||
|
|
||||||
const dictionary& coeffDict =
|
for (const word& boxName : controlBoxes)
|
||||||
dict.subDict("volumetricBSplinesMotionSolverCoeffs");
|
|
||||||
|
|
||||||
wordList controlBoxes(coeffDict.get<wordList>("controlBoxes"));
|
|
||||||
|
|
||||||
forAll(controlBoxes, iNURB)
|
|
||||||
{
|
{
|
||||||
// Creating an object writes the control points in the
|
if (NURBSdict.isDict(boxName))
|
||||||
// constructor
|
{
|
||||||
NURBS3DVolume::New
|
// Creating an object writes the control points in the
|
||||||
(
|
// constructor
|
||||||
coeffDict.subDict(controlBoxes[iNURB]),
|
NURBS3DVolume::New
|
||||||
mesh,
|
(
|
||||||
false // do not compute parametric coordinates
|
NURBSdict.subDict(boxName),
|
||||||
);
|
mesh,
|
||||||
|
false // do not compute parametric coordinates
|
||||||
|
);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Info<< "End\n" << endl;
|
Info<< "End\n" << endl;
|
||||||
|
|||||||
@ -7,6 +7,7 @@ resourcesDir=$FOAM_TUTORIALS/incompressible/adjointOptimisationFoam/resources
|
|||||||
|
|
||||||
\cp $resourcesDir/param/sbend/* 0
|
\cp $resourcesDir/param/sbend/* 0
|
||||||
\cp -r $resourcesDir/meshes/sbend/polyMesh constant
|
\cp -r $resourcesDir/meshes/sbend/polyMesh constant
|
||||||
|
runApplication writeMorpherCPs
|
||||||
runApplication decomposePar
|
runApplication decomposePar
|
||||||
runParallel $(getApplication)
|
runParallel $(getApplication)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user