cellShapeControl.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 | Copyright (C) 2012-2015 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
11  OpenFOAM is free software: you can redistribute it and/or modify it
12  under the terms of the GNU General Public License as published by
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
16  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19  for more details.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 Class
25  Foam::cellShapeControl
26 
27 Description
28 
29 SourceFiles
30  cellShapeControlI.H
31  cellShapeControl.C
32 
33 \*---------------------------------------------------------------------------*/
34 
35 #ifndef cellShapeControl_H
36 #define cellShapeControl_H
37 
38 #include "dictionary.H"
39 #include "autoPtr.H"
40 #include "tensor.H"
41 #include "point.H"
42 #include "primitiveFieldsFwd.H"
43 #include "pointFieldFwd.H"
44 #include "Time.H"
45 #include "searchableSurfaces.H"
46 #include "conformationSurfaces.H"
47 #include "cellAspectRatioControl.H"
49 #include "cellShapeControlMesh.H"
51 #include "cvControls.H"
52 
53 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
54 
55 namespace Foam
56 {
57 
58 
59 /*---------------------------------------------------------------------------*\
60  Class cellShapeControl Declaration
61 \*---------------------------------------------------------------------------*/
62 
63 class cellShapeControl
64 :
65  public dictionary
66 {
67  // Private data
68 
69  const Time& runTime_;
70 
72 
74 
75  const scalar defaultCellSize_;
76 
77  const scalar minimumCellSize_;
78 
80 
82 
84 
85 
86  // Private Member Functions
87 
88  //- Disallow default bitwise copy construct
90 
91  //- Disallow default bitwise assignment
92  void operator=(const cellShapeControl&);
93 
94 
95 public:
96 
97  //- Runtime type information
98  ClassName("cellShapeControl");
99 
100 
101  // Constructors
102 
103  //- Construct from dictionary and references to conformalVoronoiMesh and
104  // searchableSurfaces
106  (
107  const Time& runTime,
108  const cvControls& foamyHexMeshControls,
109  const searchableSurfaces& allGeometry,
110  const conformationSurfaces& geometryToConformTo
111  );
112 
113 
114  //- Destructor
116 
117 
118  // Member Functions
119 
120  // Access
121 
122  inline const scalar& defaultCellSize() const;
123 
125 
126  inline const cellShapeControlMesh& shapeControlMesh() const;
127 
128  inline const cellAspectRatioControl& aspectRatio() const;
129 
130  inline const cellSizeAndAlignmentControls& sizeAndAlignment() const;
131 
132  inline const scalar& minimumCellSize() const;
133 
134 
135  // Query
136 
137  //- Return the cell size at the given location
138  scalar cellSize(const point& pt) const;
139 
140  scalarField cellSize(const pointField& pts) const;
141 
142  //- Return the cell alignment at the given location
143  tensor cellAlignment(const point& pt) const;
144 
146  (
147  const point& pt,
148  scalar& size,
149  tensor& alignment
150  ) const;
151 };
152 
153 
154 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
155 
156 } // End namespace Foam
157 
158 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
159 
160 #include "cellShapeControlI.H"
161 
162 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
163 
164 #endif
165 
166 // ************************************************************************* //
cellSizeAndAlignmentControls.H
Foam::Tensor
Templated 3D tensor derived from VectorSpace adding construction from 9 components,...
Definition: complexI.H:224
primitiveFieldsFwd.H
Forward declarations of the specialisations of Field<T> for scalar, vector and tensor.
Foam::cvControls
Controls for the conformalVoronoiMesh mesh generator.
Definition: cvControls.H:53
Foam::Time
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
Definition: Time.H:68
Foam::cellShapeControl::~cellShapeControl
~cellShapeControl()
Destructor.
Foam::cellShapeControl::sizeAndAlignment
const cellSizeAndAlignmentControls & sizeAndAlignment() const
Definition: cellShapeControlI.H:56
point.H
cvControls.H
Foam::cellShapeControl::cellShapeControl
cellShapeControl(const cellShapeControl &)
Disallow default bitwise copy construct.
Foam::cellShapeControl::cellSizeAndAlignment
void cellSizeAndAlignment(const point &pt, scalar &size, tensor &alignment) const
Foam::cellShapeControl::aspectRatio
const cellAspectRatioControl & aspectRatio() const
Definition: cellShapeControlI.H:49
Foam::conformationSurfaces
Definition: conformationSurfaces.H:53
Foam::cellShapeControl::defaultCellSize
const scalar & defaultCellSize() const
Definition: cellShapeControlI.H:42
Foam::cellShapeControl::runTime_
const Time & runTime_
Definition: cellShapeControl.H:68
tensor.H
Foam::cellSizeAndAlignmentControls
Definition: cellSizeAndAlignmentControls.H:48
searchableSurfaces.H
Foam::cellShapeControl::shapeControlMesh_
cellShapeControlMesh shapeControlMesh_
Definition: cellShapeControl.H:78
backgroundMeshDecomposition.H
Foam::cellShapeControl::sizeAndAlignment_
cellSizeAndAlignmentControls sizeAndAlignment_
Definition: cellShapeControl.H:82
Foam::Field
Pre-declare SubField and related Field type.
Definition: Field.H:57
Foam::cellShapeControl::minimumCellSize_
const scalar minimumCellSize_
Definition: cellShapeControl.H:76
pointFieldFwd.H
cellAspectRatioControl.H
Foam::cellAspectRatioControl
Definition: cellAspectRatioControl.H:50
conformationSurfaces.H
Foam::cellShapeControl::geometryToConformTo_
const conformationSurfaces & geometryToConformTo_
Definition: cellShapeControl.H:72
Foam::cellShapeControl::allGeometry_
const searchableSurfaces & allGeometry_
Definition: cellShapeControl.H:70
Foam::cellShapeControl::operator=
void operator=(const cellShapeControl &)
Disallow default bitwise assignment.
Foam::cellShapeControl::aspectRatio_
cellAspectRatioControl aspectRatio_
Definition: cellShapeControl.H:80
Foam::dictionary
A list of keyword definitions, which are a keyword followed by any number of values (e....
Definition: dictionary.H:137
Foam::cellShapeControl
Definition: cellShapeControl.H:62
Foam
Namespace for OpenFOAM.
Definition: combustionModel.C:30
Foam::cellShapeControl::shapeControlMesh
cellShapeControlMesh & shapeControlMesh()
Definition: cellShapeControlI.H:29
Foam::cellShapeControl::ClassName
ClassName("cellShapeControl")
Runtime type information.
cellShapeControlMesh.H
cellShapeControlI.H
Foam::cellShapeControl::cellAlignment
tensor cellAlignment(const point &pt) const
Return the cell alignment at the given location.
Foam::Vector< scalar >
Foam::cellShapeControl::cellSize
scalar cellSize(const point &pt) const
Return the cell size at the given location.
Foam::searchableSurfaces
Container for searchableSurfaces.
Definition: searchableSurfaces.H:53
dictionary.H
Foam::cellShapeControl::minimumCellSize
const scalar & minimumCellSize() const
Definition: cellShapeControlI.H:62
Foam::cellShapeControl::defaultCellSize_
const scalar defaultCellSize_
Definition: cellShapeControl.H:74
Foam::cellShapeControlMesh
Definition: cellShapeControlMesh.H:61
autoPtr.H