Go to the documentation of this file.
44 const dictionary& cellSizeFunctionDict,
45 const searchableSurface& surface,
46 const scalar& defaultCellSize,
50 dictionary(cellSizeFunctionDict),
52 surfaceCellSizeFunction_
54 surfaceCellSizeFunction::
New
61 coeffsDict_(subDict(
type +
"Coeffs")),
62 defaultCellSize_(defaultCellSize),
63 regionIndices_(regionIndices),
67 word
mode = cellSizeFunctionDict.lookup(
"mode",
true);
69 if (surface_.hasVolumeType())
75 else if (
mode ==
"outside")
77 sideMode_ = smOutside;
79 else if (
mode ==
"bothSides")
81 sideMode_ = rmBothsides;
86 <<
"Unknown mode, expected: inside, outside or bothSides" <<
nl
92 if (
mode !=
"bothSides")
95 <<
"surface does not support volumeType, defaulting mode to "
100 sideMode_ = rmBothsides;
106 <<
"Cell size function for surface " << surface.name()
108 <<
", priority = " << priority_
109 <<
", regions = " << regionIndices_
119 const dictionary& cellSizeFunctionDict,
120 const searchableSurface& surface,
121 const scalar& defaultCellSize,
125 word cellSizeFunctionTypeName
127 cellSizeFunctionDict.lookup(
"cellSizeFunction")
130 Info<<
indent <<
"Selecting cellSizeFunction " << cellSizeFunctionTypeName
133 dictionaryConstructorTable::iterator cstrIter =
134 dictionaryConstructorTablePtr_->find(cellSizeFunctionTypeName);
136 if (cstrIter == dictionaryConstructorTablePtr_->end())
139 <<
"Unknown cellSizeFunction type "
140 << cellSizeFunctionTypeName
142 <<
"Valid cellSizeFunction types are :" <<
endl
143 << dictionaryConstructorTablePtr_->toc()
147 return autoPtr<cellSizeFunction>
151 cellSizeFunctionDict,
autoPtr< BasicCompressibleTurbulenceModel > New(const volScalarField &rho, const volVectorField &U, const surfaceScalarField &phi, const typename BasicCompressibleTurbulenceModel::transportModel &transport, const word &propertiesName)
List< label > labelList
A List of labels.
defineRunTimeSelectionTable(reactionRateFlameArea, dictionary)
Ostream & endl(Ostream &os)
Add newline and flush stream.
mode_t mode(const fileName &)
Return the file mode.
static scalar snapToSurfaceTol_
Point closeness tolerance to a surface where the function "snaps" to.
Macros for easy insertion into run-time selection tables.
virtual ~cellSizeFunction()
Destructor.
const double e
Elementary charge.
static autoPtr< cellSizeFunction > New(const dictionary &cellSizeFunctionDict, const searchableSurface &surface, const scalar &defaultCellSize, const labelList regionIndices)
Return a reference to the selected cellSizeFunction.
Ostream & indent(Ostream &os)
Indent stream.
errorManipArg< error, int > exit(error &err, const int errNo=1)
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
label readLabel(Istream &is)
cellSizeFunction(const cellSizeFunction &)
Disallow default bitwise copy construct.
fileName::Type type(const fileName &)
Return the file type: DIRECTORY or FILE.
defineTypeNameAndDebug(combustionModel, 0)
#define WarningInFunction
Report a warning using Foam::Warning.
stressControl lookup("compactNormalStress") >> compactNormalStress