Loading...
Searching...
No Matches
cellPointConnectivity.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) 2024-2025 OpenCFD Ltd.
9-------------------------------------------------------------------------------
10License
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
26Class
27 Foam::cellPointConnectivity
28
29Description
30 This class provides ordered connectivity for each point of each cell. Lists
31 are available of the points and faces surrounding each point of a cell. The
32 lists are ordered so that the connected points describe a polygonal cone.
33 For a convex cell, any three sequantial cone edges form a positive basis.
34
35SourceFiles
36 cellPointConnectivity.C
37
38\*---------------------------------------------------------------------------*/
39
40#ifndef Foam_cellPointConnectivity_H
41#define Foam_cellPointConnectivity_H
42
43#include "polyMesh.H"
44#include "MeshObject.H"
45
46// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47
48namespace Foam
49{
51/*---------------------------------------------------------------------------*\
52 Class cellPointConnectivity Declaration
53\*---------------------------------------------------------------------------*/
54
55class cellPointConnectivity
56:
57 public MoveableMeshObject<polyMesh>
58{
59 // Private Data
60
61 //- Reference to the polyMesh
62 const polyMesh& mesh_;
63
64 //- Lists of point-point connections
65 labelListListList cellPointPoints_;
66
67 //- Lists of point-face connections
68 labelListListList cellPointFaces_;
69
70
71 // Private Member Functions
72
73 //- No copy construct
74 cellPointConnectivity(const cellPointConnectivity&) = delete;
75
76 //- No copy assignment
77 void operator=(const cellPointConnectivity&) = delete;
78
79 //- Generate the connectivity
80 void generateCellPointConnectivity(label cellI);
81
82
83public:
84
85 // Run-time type information
86 TypeName("cellPointConnectivity");
87
88
89 // Constructors
90
91 //- Construct an IOobject and a polymesh
92 explicit cellPointConnectivity(const polyMesh&);
94
95 //- Destructor
96 ~cellPointConnectivity() = default;
97
98
99 // Member Functions
100
101 // Access
102
103 //- Access the point-point connections
105 {
106 return cellPointPoints_;
108
109 //- Access the point-face connections
110 const labelListListList& cellPointFaces() const
111 {
112 return cellPointFaces_;
113 }
114
115 // Edit
116
117 //- No action required on move points
118 virtual bool movePoints()
119 {
120 return true;
121 }
122
123 //- Dummy write for regIOobject
124 virtual bool writeData(Ostream&) const
126 return true;
127 }
128};
129
130
131// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
132
133} // End namespace Foam
134
135// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
136
137#endif
138
139// ************************************************************************* //
MoveableMeshObject(const word &objName, const objectRegistry &obr)
Definition MeshObject.H:328
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Definition Ostream.H:59
virtual bool movePoints()
No action required on move points.
~cellPointConnectivity()=default
Destructor.
TypeName("cellPointConnectivity")
const labelListListList & cellPointFaces() const
Access the point-face connections.
virtual bool writeData(Ostream &) const
Dummy write for regIOobject.
const labelListListList & cellPointPoints() const
Access the point-point connections.
Mesh consisting of general polyhedral cells.
Definition polyMesh.H:79
Namespace for OpenFOAM.
List< labelListList > labelListListList
List of labelListList.
Definition labelList.H:41
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition typeInfo.H:68