46 displacementComponentLaplacianFvMotionSolver,
54 Foam::displacementComponentLaplacianFvMotionSolver::
55 displacementComponentLaplacianFvMotionSolver
67 "cellDisplacement" + cmptName_,
75 cellMotionBoundaryTypes<scalar>(pointDisplacement_.boundaryField())
77 pointLocation_(nullptr),
80 coeffDict().
found(
"interpolation")
90 coeffDict().
found(
"frozenPointsZone")
91 ? fvMesh_.pointZones().findZoneID
93 coeffDict().
get<
word>(
"frozenPointsZone")
118 Info<<
"displacementComponentLaplacianFvMotionSolver :" 119 <<
" Read pointVectorField " 120 << pointLocation_().name()
121 <<
" to be used for boundary conditions on points." 123 <<
"Boundary conditions:" 124 << pointLocation_().boundaryField().types() <<
endl;
142 interpolationPtr_->interpolate
152 pointDisplacement_.boundaryField().size()
153 != cellDisplacement_.boundaryField().size()
156 pointDisplacement_.correctBoundaryConditions();
164 Info<<
"displacementComponentLaplacianFvMotionSolver : applying " 165 <<
" boundary conditions on " << pointLocation_().name()
166 <<
" to new point location." 172 pointLocation_().primitiveFieldRef() = fvMesh_.points();
174 pointLocation_().primitiveFieldRef().replace
177 points0_ + pointDisplacement_.primitiveField()
180 pointLocation_().correctBoundaryConditions();
183 if (frozenPointsZone_ != -1)
185 const pointZone& pz = fvMesh_.pointZones()[frozenPointsZone_];
189 label pointi = pz[i];
191 pointLocation_()[pointi][cmpt_] = points0_[pointi];
197 return tmp<pointField>(pointLocation_().primitiveField());
202 auto& curPoints = tcurPoints.ref();
207 points0_ + pointDisplacement_.primitiveField()
211 if (frozenPointsZone_ != -1)
213 const pointZone& pz = fvMesh_.pointZones()[frozenPointsZone_];
217 label pointi = pz[i];
219 curPoints[pointi][cmpt_] = points0_[pointi];
223 twoDCorrectPoints(curPoints);
234 movePoints(fvMesh_.points());
236 diffusivityPtr_->correct();
237 pointDisplacement_.boundaryFieldRef().updateCoeffs();
248 *diffusivityPtr_->operator()(),
250 "laplacian(diffusivity,cellDisplacement)" 271 diffusivityPtr_.reset(
nullptr);
275 coeffDict().
lookup(
"diffusivity")
List< ReturnType > get(const UPtrList< T > &list, const AccessOp &aop)
List of values generated by applying the access operation to each list item.
void correct(GeometricField< Type, PatchField, GeoMesh > &field)
Apply correction to field.
fvMatrix< scalar > fvScalarMatrix
virtual void updateMesh(const mapPolyMesh &)
Update local data for topology changes.
~displacementComponentLaplacianFvMotionSolver()
Destructor.
static FOAM_NO_DANGLING_REFERENCE const pointMesh & New(const polyMesh &mesh, Args &&... args)
Get existing or create MeshObject registered with typeName.
constexpr char nl
The newline '\n' character (0x0a)
const dimensionSet dimViscosity
Ostream & endl(Ostream &os)
Add newline and flush stream.
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.
Calculate the matrix for the laplacian of the field.
const fvMesh & fvMesh_
The fvMesh to be moved.
const dictionary & coeffDict() const
Const access to the coefficients dictionary.
const Time & time() const
Return the top-level database.
Lookup type of boundary radiation properties.
virtual void updateMesh(const mapPolyMesh &)
Update topology.
SolverPerformance< Type > solveSegregatedOrCoupled(const dictionary &)
Solve segregated or coupled returning the solution statistics.
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
conserve primitiveFieldRef()+
Macros for easy insertion into run-time selection tables.
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
#define forAll(list, i)
Loop across all elements in list.
Base class for fvMesh based motionSolvers.
A class for handling words, derived from Foam::string.
static tmp< T > New(Args &&... args)
Construct tmp with forwarding arguments.
void constrain(fvMatrix< Type > &eqn)
Apply constraints to equation.
static word timeName(const scalar t, const int precision=precision_)
Return a time name for the given scalar time value formatted with the given precision.
Abstract base class for cell-centre mesh motion diffusivity.
int debug
Static debugging option.
Base class for interpolation of cell displacement fields, generated by fvMotionSolvers, to the points. This base class implements the default method which applies volPointInterpolation only.
defineTypeNameAndDebug(combustionModel, 0)
virtual void solve()
Solve for motion.
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
tmp< fvMatrix< Type > > laplacian(const GeometricField< Type, fvPatchField, volMesh > &vf, const word &name)
Automatically write from objectRegistry::writeObject()
messageStream Info
Information stream (stdout output on master, null elsewhere)
Mesh consisting of general polyhedral cells.
fvScalarMatrix TEqn(fvm::ddt(T)+fvm::div(phi, T) - fvm::laplacian(alphaEff, T)==radiation->ST(rhoCpRef, T)+fvOptions(T))
T getOrDefault(const word &keyword, const T &deflt, enum keyType::option matchOpt=keyType::REGEX) const
Find and return a T, or return the given default value. FatalIOError if it is found and the number of...
A class for managing temporary objects.
static autoPtr< motionDiffusivity > New(const fvMesh &mesh, Istream &mdData)
Select null constructed.
Virtual base class for displacement motion solver.
static options & New(const fvMesh &mesh)
Construct fvOptions and register to database if not present.
virtual tmp< pointField > curPoints() const
Return point location obtained from the current motion field.
Defines the attributes of an object for which implicit objectRegistry management is supported...
addToRunTimeSelectionTable(functionObject, pointHistory, dictionary)
static constexpr const zero Zero
Global zero (0)