38 #include "surfaceInterpolate.H" 50 dynamicMotionSolverFvMeshAMI,
56 dynamicMotionSolverFvMeshAMI,
64 Foam::dynamicMotionSolverFvMeshAMI::dynamicMotionSolverFvMeshAMI
90 const auto&
pbm = boundaryMesh();
91 bool changeRequired =
false;
94 const auto* cycAmiPtr = isA<cyclicAMIPolyPatch>(
pbm[patchi]);
98 changeRequired = cycAmiPtr->createAMIFaces() || changeRequired;
102 const auto* cycAcmiPtr = isA<cyclicACMIPolyPatch>(
pbm[patchi]);
106 cycAcmiPtr->cyclicAMIPolyPatch::createAMIFaces()
120 Foam::dynamicMotionSolverFvMeshAMI::dynamicMotionSolverFvMeshAMI
136 std::move(allNeighbour),
161 if (!isA<processorFvPatch>(fvp))
163 Info<<
"1 --- patch:" << fvp.patch().name()
164 <<
" area:" <<
gSum(fvp.magSf()) <<
endl;
169 pointField newPoints(motionPtr_->curPoints());
171 polyBoundaryMesh&
pbm =
const_cast<polyBoundaryMesh&
>(boundaryMesh());
174 bool changeRequired =
false;
177 const polyPatch&
pp =
pbm[patchi];
180 <<
"pre-topology change: patch " <<
pp.name()
185 changeRequired =
pp.changeTopology() || changeRequired;
190 polyTopoChange polyTopo(*
this);
193 polyTopo.movePoints(newPoints);
200 for (polyPatch&
pp :
pbm)
202 pp.setTopology(polyTopo);
213 autoPtr<mapPolyMesh> map =
237 if (map().hasMotionPoints())
239 movePoints(map().preMotionPoints());
262 for (
const fvPatch& fvp :
boundary())
264 if (!isA<processorFvPatch>(fvp))
266 Info<<
"2 --- patch:" << fvp.patch().name()
267 <<
" area:" <<
gSum(fvp.magSf()) <<
endl;
const Field< point_type > & faceAreas() const
Return face area vectors for patch.
const polyBoundaryMesh & pbm
virtual bool update()
Update the mesh for both mesh motion and topology change.
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
GeometricField< vector, fvsPatchField, surfaceMesh > surfaceVectorField
Ostream & endl(Ostream &os)
Add newline and flush stream.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh >> &tf1, const word &name, const dimensionSet &dimensions, const bool initCopy=false)
Global function forwards to reuseTmpDimensionedField::New.
virtual bool movePoints()
Do what is necessary if the mesh has moved.
Virtual base class for mesh motion solver.
virtual bool init(const bool doInit)
Initialise all non-demand-driven data.
static autoPtr< motionSolver > New(const polyMesh &)
Select constructed from polyMesh.
GeometricField< vector, fvPatchField, volMesh > volVectorField
const motionSolver & motion() const
Return the motionSolver.
Macros for easy insertion into run-time selection tables.
List< face > faceList
List of faces.
vectorField pointField
pointField is a vectorField.
Type gSum(const FieldField< Field, Type > &f)
T returnReduce(const T &value, BinaryOp bop, const int tag=UPstream::msgType(), const int communicator=UPstream::worldComm)
Perform reduction on a copy, using specified binary operation.
bool returnReduceOr(const bool value, const int communicator=UPstream::worldComm)
Perform logical (or) MPI Allreduce on a copy. Uses UPstream::reduceOr.
#define DebugInfo
Report an information message using Foam::Info.
int debug
Static debugging option.
defineTypeNameAndDebug(combustionModel, 0)
static tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > interpolate(const GeometricField< Type, fvPatchField, volMesh > &tvf, const surfaceScalarField &faceFlux, Istream &schemeData)
Interpolate field onto faces using scheme given by Istream.
Abstract base class for geometry and/or topology changing fvMesh.
void correctBoundaryConditions()
Correct boundary field.
messageStream Info
Information stream (stdout output on master, null elsewhere)
List< label > labelList
A List of labels.
IOobject io("surfaceFilmProperties", mesh.time().constant(), mesh, IOobject::READ_IF_PRESENT, IOobject::NO_WRITE, IOobject::NO_REGISTER)
label nNonProcessor() const
The number of patches before the first processor patch.
Defines the attributes of an object for which implicit objectRegistry management is supported...
virtual bool init(const bool doInit)
Initialise all non-demand-driven data.
uindirectPrimitivePatch pp(UIndirectList< face >(mesh.faces(), faceLabels), mesh.points())
addToRunTimeSelectionTable(functionObject, pointHistory, dictionary)