64 "cellDisplacement" + cmptName_,
72 cellMotionBoundaryTypes<scalar>(pointDisplacement_.boundaryField())
74 pointLocation_(nullptr),
75 diffusivityType_(
dict.lookup(
"diffusivity")),
83 ? fvMesh_.pointZones().
findIndex(
dict.lookup(
"frozenPointsZone"))
98 Info<<
"displacementComponentLaplacianFvMotionSolver:" <<
nl
99 <<
" diffusivity : " << diffusivityPtr_().type() <<
nl
100 <<
" frozenPoints zone : " << frozenPointsZone_ <<
endl;
123 Info<<
"displacementComponentLaplacianFvMotionSolver :"
124 <<
" Read pointVectorField "
125 << pointLocation_().name()
126 <<
" to be used for boundary conditions on points."
128 <<
"Boundary conditions:"
129 << pointLocation_().boundaryField().types() <<
endl;
153 if (pointLocation_.valid())
157 Info<<
"displacementComponentLaplacianFvMotionSolver : applying "
158 <<
" boundary conditions on " << pointLocation_().name()
159 <<
" to new point location."
165 pointLocation_().primitiveFieldRef() = fvMesh_.points();
167 pointLocation_().primitiveFieldRef().replace
170 points0_ + pointDisplacement_.primitiveField()
173 pointLocation_().correctBoundaryConditions();
176 if (frozenPointsZone_ != -1)
178 const pointZone& pz = fvMesh_.pointZones()[frozenPointsZone_];
182 label pointi = pz[i];
184 pointLocation_()[pointi][cmpt_] = points0_[pointi];
200 points0_ + pointDisplacement_.primitiveField()
204 if (frozenPointsZone_ != -1)
206 const pointZone& pz = fvMesh_.pointZones()[frozenPointsZone_];
210 label pointi = pz[i];
212 curPoints[pointi][cmpt_] = points0_[pointi];
216 twoDCorrectPoints(curPoints);
227 movePoints(fvMesh_.points());
229 diffusivityPtr_->correct();
230 pointDisplacement_.boundaryFieldRef().updateCoeffs();
236 diffusivityPtr_->operator()(),
238 "laplacian(diffusivity,cellDisplacement)"
253 diffusivityPtr_.reset(
nullptr);
254 diffusivityType_.rewind();
272 diffusivityPtr_.reset(
nullptr);
273 diffusivityType_.rewind();
#define forAll(list, i)
Loop across all elements in list.
Macros for easy insertion into run-time selection tables.
static pointMesh & New(const word &name, const polyMesh &mesh)
Construct and return the named DemandDrivenMeshObject.
void replace(const direction, const UList< cmptType > &)
Replace a component field of the field.
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
Virtual base class for displacement motion solver.
virtual void topoChange(const polyTopoChangeMap &)
Update local data for topology changes.
virtual void mapMesh(const polyMeshMap &)
Update from another mesh using the given map.
A list of keywords followed by any number of values (e.g. words and numbers) or sub-dictionaries.
const word & name() const
Return const reference to name.
Mesh motion solver for an fvMesh. Based on solving the cell-centre Laplacian for the given component ...
virtual tmp< pointField > curPoints() const
Return point location obtained from the current motion field.
virtual void topoChange(const polyTopoChangeMap &)
Update corresponding to the given map.
displacementComponentLaplacianFvMotionSolver(const word &name, const polyMesh &, const dictionary &)
Construct from polyMesh and dictionary.
~displacementComponentLaplacianFvMotionSolver()
Destructor.
virtual void mapMesh(const polyMeshMap &)
Update from another mesh using the given map.
virtual void solve()
Solve for motion.
const Time & time() const
Return the top-level database.
Base class for fvMesh based motionSolvers.
const fvMesh & fvMesh_
The fvMesh to be moved.
Abstract base class for cell-centre mesh motion diffusivity.
static autoPtr< motionDiffusivity > New(const fvMesh &mesh, Istream &mdData)
Select null constructed.
Virtual base class for mesh motion solver.
Named list of point indices representing a sub-set of the mesh faces.
Class containing mesh-to-mesh mapping information.
Mesh consisting of general polyhedral cells.
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
A class for managing temporary objects.
T & ref() const
Return non-const reference or generate a fatal error.
Templated form of IOobject providing type information for file reading and header type checking.
bool headerOk()
Read header (uses typeGlobalFile to find file) and check.
tmp< PointField< Type > > interpolate(const VolField< Type > &) const
Interpolate volField using inverse distance weighting.
A class for handling words, derived from string.
Foam::fvMesh mesh(Foam::IOobject(regionName, runTime.name(), runTime, Foam::IOobject::MUST_READ), false)
Calculate the matrix for the laplacian of the field.
autoPtr< CompressibleMomentumTransportModel > New(const volScalarField &rho, const volVectorField &U, const surfaceScalarField &phi, const viscosity &viscosity)
tmp< fvMatrix< Type > > laplacian(const VolField< Type > &vf, const word &name)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
addToRunTimeSelectionTable(polyPatch, mergedCyclicPolyPatch, word)
const HashTable< dimensionSet > & dimensions()
Get the table of dimension sets.
Ostream & endl(Ostream &os)
Add newline and flush stream.
vectorField pointField
pointField is a vectorField.
defineTypeNameAndDebug(combustionModel, 0)
word name(const LagrangianState state)
Return a string representation of a Lagrangian state enumeration.
label findIndex(const ListType &, typename ListType::const_reference, const label start=0)
Find first occurrence of given element and return index,.
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.
SolverPerformance< Type > solve(fvMatrix< Type > &, const word &)
Solve returning the solution statistics given convergence tolerance.
conserve primitiveFieldRef()+