1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | foam-extend: Open Source CFD
4 \\ / O peration | Version: 3.2
5 \\ / A nd | Web: http://www.foam-extend.org
6 \\/ M anipulation | For copyright notice see file Copyright
7 -------------------------------------------------------------------------------
9 This file is part of foam-extend.
11 foam-extend 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.
16 foam-extend is distributed in the hope that it will be useful, but
17 WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
28 points connected by edges.
35 \*---------------------------------------------------------------------------*/
40 #include "pointField.H"
43 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
48 /*---------------------------------------------------------------------------*\
49 Class edgeMesh Declaration
50 \*---------------------------------------------------------------------------*/
56 //- Vertices of the edges
59 //- The edges defining the boundary
62 //- From point to edges
63 mutable autoPtr<labelListList> pointEdgesPtr_;
65 // Private Member Functions
67 //- Calculate point-edge addressing (inverse of edges)
68 void calcPointEdges() const;
74 //- Construct from components
75 edgeMesh(const pointField&, const edgeList&);
77 //- Construct from file
78 edgeMesh(const fileName&);
80 //- Construct from Istream
84 edgeMesh(const edgeMesh&);
90 inline const pointField& points() const;
92 inline const edgeList& edges() const;
94 inline const labelListList& pointEdges() const;
96 //- Find connected regions. Set region number per edge.
97 // Returns number of regions.
98 label regions(labelList& edgeRegion) const;
100 //- Merge common points (points within mergeDist)
101 void mergePoints(const scalar mergeDist);
105 inline void operator=(const edgeMesh&);
109 friend Ostream& operator<<(Ostream&, const edgeMesh&);
110 friend Istream& operator>>(Istream&, edgeMesh&);
114 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
116 } // End namespace Foam
118 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
120 #include "edgeMeshI.H"
122 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
126 // ************************************************************************* //