All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
layerParameters Class Reference

Simple container to keep together layer specific information. More...

Public Types

enum  layerSpecification {
  ILLEGAL, FIRST_AND_TOTAL, FIRST_AND_EXPANSION, FINAL_AND_TOTAL,
  FINAL_AND_EXPANSION, TOTAL_AND_EXPANSION
}
 Enumeration defining the layer specification: More...
 
enum  mergeFace { no, ifOnMeshedPatch, yes }
 Enumeration defining whether to merge faces on a given patch. Read. More...
 

Public Member Functions

 layerParameters (const dictionary &dict, const polyBoundaryMesh &)
 Construct from dictionary. More...
 
 layerParameters (const layerParameters &)=delete
 Disallow default bitwise copy construction. More...
 
const dictionarydict () const
 
const labelListnumLayers () const
 How many layers to add: More...
 
bool relativeSizes () const
 Are size parameters relative to inner cell size or. More...
 
const scalarFieldexpansionRatio () const
 
const scalarFieldfinalLayerThickness () const
 Wanted thickness of the layer furthest away. More...
 
const scalarFieldfirstLayerThickness () const
 Wanted thickness of the layer nearest to the wall. More...
 
const scalarFieldthickness () const
 Wanted overall thickness of all layers. More...
 
const scalarFieldminThickness () const
 Minimum overall thickness of cell layer. If for any reason layer. More...
 
const List< mergeFace > & mergeFaces () const
 Whether to merge boundary faces of the same layer cell. More...
 
label nLayerIter () const
 Number of overall layer addition iterations. More...
 
label nRelaxedIter () const
 Number of iterations after which relaxed motion rules. More...
 
scalar featureAngle () const
 
scalar concaveAngle () const
 
label nGrow () const
 If points get not extruded do nGrow layers of connected faces. More...
 
scalar maxFaceThicknessRatio () const
 Stop layer growth on highly warped cells. More...
 
label nBufferCellsNoExtrude () const
 Create buffer region for new layer terminations. More...
 
const SwitchadditionalReporting () const
 
const wordmeshShrinker () const
 Type of mesh shrinker. More...
 
scalar layerThickness (const label nLayers, const scalar firstLayerThickess, const scalar finalLayerThickess, const scalar totalThickness, const scalar expansionRatio) const
 Determine overall thickness. Uses two of the four parameters. More...
 
scalar layerExpansionRatio (const label nLayers, const scalar firstLayerThickess, const scalar finalLayerThickess, const scalar totalThickness, const scalar expansionRatio) const
 Determine expansion ratio. Uses two of the four parameters. More...
 
scalar firstLayerThickness (const label nLayers, const scalar firstLayerThickess, const scalar finalLayerThickess, const scalar totalThickness, const scalar expansionRatio) const
 Determine first layer (near-wall) thickness. Uses two of the. More...
 
scalar finalLayerThicknessRatio (const label nLayers, const scalar expansionRatio) const
 Determine ratio of final layer thickness to. More...
 
void operator= (const layerParameters &)=delete
 Disallow default bitwise assignment. More...
 

Detailed Description

Simple container to keep together layer specific information.

Source files

Definition at line 55 of file layerParameters.H.

Member Enumeration Documentation

◆ layerSpecification

Enumeration defining the layer specification:

  • first and total thickness specified
  • first and expansion ratio specified
  • final and total thickness specified
  • final and expansion ratio specified
  • total thickness and expansion ratio specified
Enumerator
ILLEGAL 
FIRST_AND_TOTAL 
FIRST_AND_EXPANSION 
FINAL_AND_TOTAL 
FINAL_AND_EXPANSION 
TOTAL_AND_EXPANSION 

Definition at line 68 of file layerParameters.H.

◆ mergeFace

enum mergeFace
strong

Enumeration defining whether to merge faces on a given patch. Read.

as a boolean (no/yes). Defaults to merging only on patches which were meshed/snapped to (ifOnMeshedPatch).

Enumerator
no 
ifOnMeshedPatch 
yes 

Definition at line 81 of file layerParameters.H.

Constructor & Destructor Documentation

◆ layerParameters() [1/2]

◆ layerParameters() [2/2]

layerParameters ( const layerParameters )
delete

Disallow default bitwise copy construction.

Member Function Documentation

◆ dict()

const dictionary& dict ( ) const
inline

Definition at line 171 of file layerParameters.H.

References layerParameters::numLayers(), and layerParameters::relativeSizes().

Referenced by snappyLayerDriver::addLayers().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ numLayers()

const labelList& numLayers ( ) const
inline

How many layers to add:

  • -1 : no specification. Assume 0 layers but allow sliding to make layers
  • 0 : specified to have 0 layers. No sliding allowed.
  • >0 : number of layers

Definition at line 185 of file layerParameters.H.

Referenced by snappyLayerDriver::addLayers(), layerParameters::dict(), and snappyLayerDriver::doLayers().

Here is the caller graph for this function:

◆ relativeSizes()

bool relativeSizes ( ) const
inline

Are size parameters relative to inner cell size or.

absolute distances.

Definition at line 192 of file layerParameters.H.

Referenced by snappyLayerDriver::addLayers(), and layerParameters::dict().

Here is the caller graph for this function:

◆ expansionRatio()

◆ finalLayerThickness()

const scalarField& finalLayerThickness ( ) const
inline

Wanted thickness of the layer furthest away.

from the wall (i.e. nearest the original mesh). If relativeSize() this number is relative to undistorted size of the cell outside layer.

Definition at line 207 of file layerParameters.H.

Referenced by layerParameters::expansionRatio().

Here is the caller graph for this function:

◆ firstLayerThickness() [1/2]

const scalarField& firstLayerThickness ( ) const
inline

Wanted thickness of the layer nearest to the wall.

If relativeSize() this number is relative to undistorted size of the cell outside layer.

Definition at line 215 of file layerParameters.H.

Referenced by layerParameters::expansionRatio(), layerParameters::firstLayerThickness(), layerParameters::layerExpansionRatio(), and layerParameters::meshShrinker().

Here is the caller graph for this function:

◆ thickness()

const scalarField& thickness ( ) const
inline

Wanted overall thickness of all layers.

If relativeSize() this number is relative to undistorted size of the cell outside layer.

Definition at line 223 of file layerParameters.H.

Referenced by layerParameters::expansionRatio().

Here is the caller graph for this function:

◆ minThickness()

const scalarField& minThickness ( ) const
inline

Minimum overall thickness of cell layer. If for any reason layer.

cannot be above minThickness do not add layer. If relativeSize() this number is relative to undistorted size of the cell outside layer.

Definition at line 232 of file layerParameters.H.

Referenced by layerParameters::expansionRatio().

Here is the caller graph for this function:

◆ mergeFaces()

const List<mergeFace>& mergeFaces ( ) const
inline

Whether to merge boundary faces of the same layer cell.

Definition at line 238 of file layerParameters.H.

Referenced by snappyLayerDriver::mergePatchFacesUndo().

Here is the caller graph for this function:

◆ nLayerIter()

label nLayerIter ( ) const
inline

Number of overall layer addition iterations.

Definition at line 247 of file layerParameters.H.

References layerParameters::nRelaxedIter().

Referenced by snappyLayerDriver::addLayers().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ nRelaxedIter()

label nRelaxedIter ( ) const
inline

Number of iterations after which relaxed motion rules.

are to be used.

Definition at line 254 of file layerParameters.H.

Referenced by snappyLayerDriver::addLayers(), and layerParameters::nLayerIter().

Here is the caller graph for this function:

◆ featureAngle()

scalar featureAngle ( ) const
inline

Definition at line 262 of file layerParameters.H.

Referenced by snappyLayerDriver::addLayers(), and snappyLayerDriver::mergePatchFacesUndo().

Here is the caller graph for this function:

◆ concaveAngle()

scalar concaveAngle ( ) const
inline

Definition at line 267 of file layerParameters.H.

References layerParameters::nGrow().

Referenced by snappyLayerDriver::mergePatchFacesUndo().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ nGrow()

label nGrow ( ) const
inline

If points get not extruded do nGrow layers of connected faces.

that are not grown. Is used to not do layers at all close to features.

Definition at line 275 of file layerParameters.H.

Referenced by snappyLayerDriver::addLayers(), and layerParameters::concaveAngle().

Here is the caller graph for this function:

◆ maxFaceThicknessRatio()

scalar maxFaceThicknessRatio ( ) const
inline

Stop layer growth on highly warped cells.

Definition at line 281 of file layerParameters.H.

Referenced by snappyLayerDriver::addLayers().

Here is the caller graph for this function:

◆ nBufferCellsNoExtrude()

label nBufferCellsNoExtrude ( ) const
inline

Create buffer region for new layer terminations.

Definition at line 287 of file layerParameters.H.

Referenced by snappyLayerDriver::addLayers().

Here is the caller graph for this function:

◆ additionalReporting()

const Switch& additionalReporting ( ) const
inline

Definition at line 292 of file layerParameters.H.

Referenced by snappyLayerDriver::addLayers().

Here is the caller graph for this function:

◆ meshShrinker()

const word& meshShrinker ( ) const
inline

Type of mesh shrinker.

Definition at line 298 of file layerParameters.H.

References layerParameters::expansionRatio(), layerParameters::finalLayerThicknessRatio(), layerParameters::firstLayerThickness(), layerParameters::layerThickness(), and layerParameters::operator=().

Referenced by snappyLayerDriver::addLayers().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ layerThickness()

Foam::scalar layerThickness ( const label  nLayers,
const scalar  firstLayerThickess,
const scalar  finalLayerThickess,
const scalar  totalThickness,
const scalar  expansionRatio 
) const

Determine overall thickness. Uses two of the four parameters.

according to the layerSpecification

Definition at line 393 of file layerParameters.C.

References Foam::exit(), layerParameters::expansionRatio(), Foam::FatalError, FatalErrorInFunction, layerParameters::FINAL_AND_EXPANSION, layerParameters::FINAL_AND_TOTAL, layerParameters::FIRST_AND_EXPANSION, layerParameters::FIRST_AND_TOTAL, Foam::mag(), Foam::pow(), and layerParameters::TOTAL_AND_EXPANSION.

Referenced by layerParameters::layerParameters(), and layerParameters::meshShrinker().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ layerExpansionRatio()

Foam::scalar layerExpansionRatio ( const label  nLayers,
const scalar  firstLayerThickess,
const scalar  finalLayerThickess,
const scalar  totalThickness,
const scalar  expansionRatio 
) const

◆ firstLayerThickness() [2/2]

Foam::scalar firstLayerThickness ( const label  nLayers,
const scalar  firstLayerThickess,
const scalar  finalLayerThickess,
const scalar  totalThickness,
const scalar  expansionRatio 
) const

Determine first layer (near-wall) thickness. Uses two of the.

four parameters according to the layerSpecification

Definition at line 505 of file layerParameters.C.

References Foam::exit(), Foam::FatalError, FatalErrorInFunction, layerParameters::FINAL_AND_EXPANSION, layerParameters::FINAL_AND_TOTAL, layerParameters::finalLayerThicknessRatio(), layerParameters::FIRST_AND_EXPANSION, layerParameters::FIRST_AND_TOTAL, layerParameters::firstLayerThickness(), Foam::pow(), and layerParameters::TOTAL_AND_EXPANSION.

Here is the call graph for this function:

◆ finalLayerThicknessRatio()

Foam::scalar finalLayerThicknessRatio ( const label  nLayers,
const scalar  expansionRatio 
) const

Determine ratio of final layer thickness to.

overall layer thickness

Definition at line 567 of file layerParameters.C.

References layerParameters::expansionRatio(), Foam::mag(), and Foam::pow().

Referenced by snappyLayerDriver::addLayers(), layerParameters::firstLayerThickness(), and layerParameters::meshShrinker().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ operator=()

void operator= ( const layerParameters )
delete

Disallow default bitwise assignment.

Referenced by layerParameters::meshShrinker().

Here is the caller graph for this function:

The documentation for this class was generated from the following files: