triSurfaceCurvatureEstimator.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | cfMesh: A library for mesh generation
4  \\ / O peration |
5  \\ / A nd | Author: Franjo Juretic (franjo.juretic@c-fields.com)
6  \\/ M anipulation | Copyright (C) Creative Fields, Ltd.
7 -------------------------------------------------------------------------------
8 License
9  This file is part of cfMesh.
10 
11  cfMesh is free software; you can redistribute it and/or modify it
12  under the terms of the GNU General Public License as published by the
13  Free Software Foundation; either version 3 of the License, or (at your
14  option) any later version.
15 
16  cfMesh 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 cfMesh. If not, see <http://www.gnu.org/licenses/>.
23 
24 Class
25  triSurfaceCurvatureCalculator
26 
27 Description
28  Provides information regarding surface partitions on the surface
29  triangulation, and connectivity between various surface partitions.
30 
31 SourceFiles
32  triSurfaceCurvatureEstimator.C
33 
34 \*---------------------------------------------------------------------------*/
35 
36 #ifndef triSurfaceCurvatureEstimator_H
37 #define triSurfaceCurvatureEstimator_H
38 
39 #include "triSurf.H"
40 #include "FRWGraph.H"
41 #include "DynList.H"
42 
43 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
44 
45 namespace Foam
46 {
47 
48 /*---------------------------------------------------------------------------*\
49  Class triSurfaceCurvatureEstimator Declaration
50 \*---------------------------------------------------------------------------*/
51 
53 {
54  // Private data
55  //- reference to triSurface
56  const triSurf& surface_;
57 
58  //- curvature of points at feature edges
60 
61  //- curvatures of other points
69 
70  // Private member functions
71  //- calculate curvature of feature edges
73 
74  //- calculate curvatures of other surface points
76 
77  //- calculate Gaussian curvature
79 
80  //- calculation of mean curvature
82 
83  //- calculation of min and max curvature
85 
86  //- Disallow default bitwise copy construct
88 
89  //- Disallow default bitwise assignment
91 
92 public:
93 
94  // Constructors
95 
96  //- Construct from triSurface
98 
99  // Destructor
100 
102 
103 
104  // Member Functions
105  //- return curvature of points at feature edges
106  scalar edgePointCurvature(const label) const;
107  scalar curvatureAtEdge(const label) const;
108 
109  //- return average curvature on a surface triangle
110  scalar gaussianCurvatureAtTriangle(const label) const;
111  scalar meanCurvatureAtTriangle(const label) const;
112  scalar maxCurvatureAtTriangle(const label) const;
113  scalar minCurvatureAtTriangle(const label) const;
114 
117 };
118 
119 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
120 
121 } // End namespace Foam
122 
123 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
124 
125 #endif
126 
127 // ************************************************************************* //
Foam::triSurfaceCurvatureEstimator::minCurvatureAtTriangle
scalar minCurvatureAtTriangle(const label) const
Definition: triSurfaceCurvatureEstimator.C:132
Foam::triSurfaceCurvatureEstimator::calculateGaussianCurvature
void calculateGaussianCurvature()
calculate Gaussian curvature
Foam::triSurfaceCurvatureEstimator::edgePointCurvature
scalar edgePointCurvature(const label) const
return curvature of points at feature edges
Definition: triSurfaceCurvatureEstimator.C:71
triSurf.H
Foam::triSurfaceCurvatureEstimator::minCurvatureVectorAtTriangle
vector minCurvatureVectorAtTriangle(const label) const
Definition: triSurfaceCurvatureEstimator.C:162
Foam::triSurfaceCurvatureEstimator::gaussianCurvatureAtTriangle
scalar gaussianCurvatureAtTriangle(const label) const
return average curvature on a surface triangle
Definition: triSurfaceCurvatureEstimator.C:87
Foam::triSurfaceCurvatureEstimator::calculateMeanCurvature
void calculateMeanCurvature()
calculation of mean curvature
Foam::triSurfaceCurvatureEstimator::calculateEdgeCurvature
void calculateEdgeCurvature()
calculate curvature of feature edges
Definition: triSurfaceCurvatureEstimatorCalculate.C:208
Foam::triSurfaceCurvatureEstimator::operator=
void operator=(const triSurfaceCurvatureEstimator &)
Disallow default bitwise assignment.
Foam::triSurfaceCurvatureEstimator::maxCurvature_
List< DynList< scalar, 1 > > maxCurvature_
Definition: triSurfaceCurvatureEstimator.H:64
Foam::label
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Definition: label.H:59
Foam::triSurfaceCurvatureEstimator::maxCurvatureVector_
List< DynList< vector, 1 > > maxCurvatureVector_
Definition: triSurfaceCurvatureEstimator.H:66
Foam::Field
Pre-declare SubField and related Field type.
Definition: Field.H:57
Foam::triSurfaceCurvatureEstimator::meanCurvatureAtTriangle
scalar meanCurvatureAtTriangle(const label) const
Definition: triSurfaceCurvatureEstimator.C:102
Foam::triSurfaceCurvatureEstimator::surface_
const triSurf & surface_
reference to triSurface
Definition: triSurfaceCurvatureEstimator.H:55
FRWGraph.H
Foam::triSurfaceCurvatureEstimator::patchPositions_
FRWGraph< label, 3 > patchPositions_
curvatures of other points
Definition: triSurfaceCurvatureEstimator.H:61
Foam::triSurfaceCurvatureEstimator::~triSurfaceCurvatureEstimator
~triSurfaceCurvatureEstimator()
Definition: triSurfaceCurvatureEstimator.C:66
Foam
Namespace for OpenFOAM.
Definition: combustionModel.C:30
Foam::triSurfaceCurvatureEstimator::meanCurvature_
List< DynList< scalar, 1 > > meanCurvature_
Definition: triSurfaceCurvatureEstimator.H:63
Foam::triSurfaceCurvatureEstimator::gaussianCurvature_
List< DynList< scalar, 1 > > gaussianCurvature_
Definition: triSurfaceCurvatureEstimator.H:62
Foam::triSurfaceCurvatureEstimator::calculateSurfaceCurvatures
void calculateSurfaceCurvatures()
calculate curvatures of other surface points
Definition: triSurfaceCurvatureEstimatorCalculate.C:293
Foam::Vector< scalar >
Foam::List
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
Definition: HashTable.H:59
Foam::surface
Definition: surface.H:55
Foam::triSurfaceCurvatureEstimator::calculateMinAndMaxCurvature
void calculateMinAndMaxCurvature()
calculation of min and max curvature
Foam::triSurfaceCurvatureEstimator::curvatureAtEdge
scalar curvatureAtEdge(const label) const
Definition: triSurfaceCurvatureEstimator.C:76
Foam::triSurfaceCurvatureEstimator::triSurfaceCurvatureEstimator
triSurfaceCurvatureEstimator(const triSurfaceCurvatureEstimator &)
Disallow default bitwise copy construct.
Foam::triSurfaceCurvatureEstimator::maxCurvatureAtTriangle
scalar maxCurvatureAtTriangle(const label) const
Definition: triSurfaceCurvatureEstimator.C:117
Foam::triSurfaceCurvatureEstimator::maxCurvatureVectorAtTriangle
vector maxCurvatureVectorAtTriangle(const label) const
Definition: triSurfaceCurvatureEstimator.C:147
Foam::FRWGraph< label, 3 >
Foam::triSurf
Definition: triSurf.H:59
Foam::triSurfaceCurvatureEstimator::edgePointCurvature_
scalarField edgePointCurvature_
curvature of points at feature edges
Definition: triSurfaceCurvatureEstimator.H:58
Foam::triSurfaceCurvatureEstimator
Definition: triSurfaceCurvatureEstimator.H:51
Foam::triSurfaceCurvatureEstimator::minCurvatureVector_
List< DynList< vector, 1 > > minCurvatureVector_
Definition: triSurfaceCurvatureEstimator.H:67
DynList.H
Foam::triSurfaceCurvatureEstimator::minCurvature_
List< DynList< scalar, 1 > > minCurvature_
Definition: triSurfaceCurvatureEstimator.H:65