cellSizeAndAlignmentControls.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | www.openfoam.com
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8  Copyright (C) 2012-2015 OpenFOAM Foundation
9 -------------------------------------------------------------------------------
10 License
11  This file is part of OpenFOAM.
12 
13  OpenFOAM is free software: you can redistribute it and/or modify it
14  under the terms of the GNU General Public License as published by
15  the Free Software Foundation, either version 3 of the License, or
16  (at your option) any later version.
17 
18  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21  for more details.
22 
23  You should have received a copy of the GNU General Public License
24  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25 
26 Class
27  Foam::cellSizeAndAlignmentControls
28 
29 Description
30 
31 SourceFiles
32  cellSizeAndAlignmentControls.C
33 
34 \*---------------------------------------------------------------------------*/
35 
36 #ifndef cellSizeAndAlignmentControls_H
37 #define cellSizeAndAlignmentControls_H
38 
39 #include "dictionary.H"
41 
42 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
43 
44 namespace Foam
45 {
46 
47 /*---------------------------------------------------------------------------*\
48  Class cellSizeAndAlignmentControls Declaration
49 \*---------------------------------------------------------------------------*/
50 
52 {
53  // Private data
54 
55  const dictionary& shapeControlDict_;
56 
57  const conformationSurfaces& geometryToConformTo_;
58 
59  PtrList<cellSizeAndAlignmentControl> controlFunctions_;
60 
61  const scalar defaultCellSize_;
62 
63 
64  // Private Member Functions
65 
66  bool evalCellSizeFunctions
67  (
68  const point& pt,
69  scalar& minSize,
70  label& maxPriority
71  ) const;
72 
73  //- No copy construct
75  (
77  ) = delete;
78 
79  //- No copy assignment
80  void operator=(const cellSizeAndAlignmentControls&) = delete;
81 
82 
83 public:
84 
85  //- Runtime type information
86  ClassName("cellSizeAndAlignmentControls");
87 
88 
89  // Constructors
90 
91  //- Construct from dictionary
93  (
94  const Time& runTime,
95  const dictionary& shapeControlDict,
97  const scalar& defaultCellSize
98  );
99 
100 
101  //- Destructor
103 
104 
105  // Member Functions
106 
107  // Access
108 
110  controlFunctions() const
111  {
112  return controlFunctions_;
113  }
114 
115  inline const conformationSurfaces& geometryToConformTo() const
116  {
117  return geometryToConformTo_;
118  }
119 
120 
121  // Query
122 
123  scalar cellSize(const point& pt) const;
124 
125  scalar cellSize(const point& pt, label& maxPriority) const;
126 };
127 
128 
129 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
130 
131 } // End namespace Foam
132 
133 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
134 
135 #endif
136 
137 // ************************************************************************* //
runTime
engineTime & runTime
Definition: createEngineTime.H:13
Foam::Time
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
Definition: Time.H:73
Foam::cellSizeAndAlignmentControls::controlFunctions
const PtrList< cellSizeAndAlignmentControl > & controlFunctions() const
Definition: cellSizeAndAlignmentControls.H:109
Foam::cellSizeAndAlignmentControls::geometryToConformTo
const conformationSurfaces & geometryToConformTo() const
Definition: cellSizeAndAlignmentControls.H:114
Foam::conformationSurfaces
Definition: conformationSurfaces.H:55
Foam::cellSizeAndAlignmentControls::ClassName
ClassName("cellSizeAndAlignmentControls")
Runtime type information.
Foam::cellSizeAndAlignmentControls
Definition: cellSizeAndAlignmentControls.H:50
Foam::PtrList
A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers....
Definition: List.H:59
cellSizeAndAlignmentControl.H
Foam::dictionary
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:123
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Foam::cellSizeAndAlignmentControls::~cellSizeAndAlignmentControls
virtual ~cellSizeAndAlignmentControls()
Destructor.
Foam::Vector< scalar >
dictionary.H
Foam::cellSizeAndAlignmentControls::cellSize
scalar cellSize(const point &pt) const