36namespace extrudeModels
51 thickness_(coeffDict_.get<scalar>(
"thickness")),
54 coeffDict_.getOrDefault<scalar>(
"firstCellThickness", 0)
56 layerPoints_(nLayers_)
61 <<
"thickness should be positive : " << thickness_
65 if (
nLayers_ > 1 && firstCellThickness_ > 0)
67 if (thickness_ <= firstCellThickness_)
70 <<
"firstCellThickness leave no room for further layers"
74 layerPoints_[0] = firstCellThickness_;
76 for (label layer = 1; layer <
nLayers_; ++layer)
79 (thickness_ - layerPoints_[0])
85 for (label layer = 0; layer <
nLayers_; ++layer)
87 layerPoints_[layer] = thickness_*
sumThickness(layer + 1);
97 const point& surfacePoint,
98 const vector& surfaceNormal,
107 return surfacePoint + layerPoints_[layer - 1]*surfaceNormal;
Macros for easy insertion into run-time selection tables.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Top level extrusion model class.
scalar sumThickness(const label layer) const
Helper: calculate cumulative relative thickness for layer.
Extrudes by transforming points normal to the surface by a given distance.
friend Ostream & operator(Ostream &, const faMatrix< Type > &)
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
errorManipArg< error, int > exit(error &err, const int errNo=1)