37 namespace fvMotionSolvers
68 pointMeshMovers::displacementComponent(
mesh,
dict,
type()),
73 "cellDisplacement" + cmptName_,
81 cellMotionBoundaryTypes<scalar>(pointDisplacement_.boundaryField())
83 pointLocation_(nullptr),
110 Info<<
"displacementComponentLaplacian:" <<
nl
111 <<
" diffusivity : " << diffusivityPtr_().type() <<
nl
112 <<
" frozenPoints zone : " << frozenPointsZone_ <<
endl;
135 Info<<
"displacementComponentLaplacian :"
136 <<
" Read pointVectorField "
137 << pointLocation_().name()
138 <<
" to be used for boundary conditions on points."
140 <<
"Boundary conditions:"
141 << pointLocation_().boundaryField().types() <<
endl;
174 diffusivityPtr_->correct();
175 pointDisplacement_.boundaryFieldRef().updateCoeffs();
181 diffusivityPtr_->operator()(),
183 "laplacian(diffusivity,cellDisplacement)"
193 if (pointLocation_.valid())
197 Info<<
"displacementComponentLaplacian : applying "
198 <<
" boundary conditions on " << pointLocation_().name()
199 <<
" to new point location."
205 pointLocation_().primitiveFieldRef() =
mesh().
points();
207 pointLocation_().primitiveFieldRef().
replace
210 points0_ + pointDisplacement_.primitiveField()
213 pointLocation_().correctBoundaryConditions();
216 if (frozenPointsZone_ != -1)
222 label pointi = pz[i];
224 pointLocation_()[pointi][cmpt_] = points0_[pointi];
240 points0_ + pointDisplacement_.primitiveField()
244 if (frozenPointsZone_ != -1)
250 label pointi = pz[i];
252 curPoints[pointi][cmpt_] = points0_[pointi];
256 twoDCorrectPoints(curPoints);
272 diffusivityPtr_.reset(
nullptr);
273 diffusivityType_.rewind();
291 diffusivityPtr_.reset(
nullptr);
292 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...
A list of keywords followed by any number of values (e.g. words and numbers) or sub-dictionaries.
Abstract base class for fvMesh movers.
fvMesh & mesh()
Return the fvMesh.
Mesh data needed to do the Finite Volume discretisation.
Base class for fvMesh motion solvers.
Mesh motion solver for an fvMesh. Based on solving the cell-centre Laplacian for the given component ...
~displacementComponentLaplacian()
Destructor.
displacementComponentLaplacian(fvMesh &, const dictionary &)
Construct from fvMesh and dictionary.
virtual void topoChange(const polyTopoChangeMap &)
Update corresponding to the given map.
virtual tmp< pointField > newPoints()
Return point location obtained from the current motion field.
virtual void mapMesh(const polyMeshMap &)
Update from another mesh using the given map.
Abstract base class for cell-centre mesh motion diffusivity.
static autoPtr< motionDiffusivity > New(const fvMesh &mesh, Istream &mdData)
Select null constructed.
Abstract base class for pointMesh movers.
virtual void topoChange(const polyTopoChangeMap &)
Update local data for topology changes.
virtual void mapMesh(const polyMeshMap &)
Update from another mesh using the given map.
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.
const pointZoneList & pointZones() const
Return point zones.
virtual const pointField & points() const
Return raw points.
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.
Foam::fvMesh mesh(Foam::IOobject(regionName, runTime.name(), runTime, Foam::IOobject::MUST_READ), false)
Calculate the matrix for the laplacian of the field.
defineTypeNameAndDebug(displacementLaplacian, 0)
addToRunTimeSelectionTable(fvMeshMover, displacementLaplacian, fvMesh)
tmp< fvMatrix< Type > > laplacian(const VolField< Type > &vf, const word &name)
const unitSet & lookup(const word &unitName)
Lookup and return the named unit from the table.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Ostream & endl(Ostream &os)
Add newline and flush stream.
vectorField pointField
pointField is a vectorField.
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,.
tmp< DimensionedField< TypeR, GeoMesh, Field > > New(const tmp< DimensionedField< TypeR, GeoMesh, Field >> &tdf1, const word &name, const dimensionSet &dimensions)
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()+