40#ifndef Foam_layerAdditionRemoval_H
41#define Foam_layerAdditionRemoval_H
56class layerAdditionRemoval
58 public polyMeshModifier
66 mutable scalar minLayerThickness_;
69 mutable scalar maxLayerThickness_;
73 const bool thicknessFromVolume_;
77 mutable scalar oldLayerThickness_;
80 mutable std::unique_ptr<labelList> pointsPairingPtr_;
83 mutable std::unique_ptr<labelList> facesPairingPtr_;
86 mutable label triggerRemoval_;
89 mutable label triggerAddition_;
95 layerAdditionRemoval(
const layerAdditionRemoval&) =
delete;
98 void operator=(
const layerAdditionRemoval&) =
delete;
101 void checkDefinition();
107 bool validCollapse()
const;
110 bool setLayerPairing()
const;
128 void clearAddressing()
const;
134 static const scalar addDelta_;
139 static const scalar removeDelta_;
155 const word& zoneName,
156 const scalar minThickness,
157 const scalar maxThickness,
158 const bool thicknessFromVolume =
true
196 return minLayerThickness_;
205 return maxLayerThickness_;
213 virtual void write(Ostream&)
const;
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
scalar maxLayerThickness() const
Return max layer thickness which triggers removal.
void setMaxLayerThickness(const scalar t) const
Set max layer thickness which triggers removal.
TypeName("layerAdditionRemoval")
Runtime type information.
virtual bool changeTopology() const
Check for topology change.
virtual void writeDict(Ostream &) const
Write dictionary.
virtual void setRefinement(polyTopoChange &) const
Insert the layer addition/removal instructions.
void setMinLayerThickness(const scalar t) const
Set min layer thickness which triggers removal.
virtual void modifyMotionPoints(pointField &motionPoints) const
Modify motion points to comply with the topological change.
scalar minLayerThickness() const
Return min layer thickness which triggers removal.
virtual void updateMesh(const mapPolyMesh &)
Force recalculation of locally stored data on topological change.
virtual ~layerAdditionRemoval()=default
Destructor.
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
label index() const
Return the index of this modifier.
const word & name() const
Return name of this modifier.
Direct mesh changes based on v1.3 polyTopoChange syntax.
List of mesh modifiers defining the mesh dynamics.
A class for managing temporary objects.
A class for handling words, derived from Foam::string.
List< label > labelList
A List of labels.
vectorField pointField
pointField is a vectorField.
DynamicID< faceZoneMesh > faceZoneID
Foam::faceZoneID.
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.