manualRenumber.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) 2011-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::manualRenumber
28 
29 Description
30  Renumber given a ordered-to-original cell association in a file
31 
32 SourceFiles
33  manualRenumber.C
34 
35 \*---------------------------------------------------------------------------*/
36 
37 #ifndef manualRenumber_H
38 #define manualRenumber_H
39 
40 #include "renumberMethod.H"
41 
42 namespace Foam
43 {
44 
45 /*---------------------------------------------------------------------------*\
46  Class manualRenumber Declaration
47 \*---------------------------------------------------------------------------*/
48 
49 class manualRenumber
50 :
51  public renumberMethod
52 {
53  // Private data
54 
55  const fileName dataFile_;
56 
57 
58  // Private Member Functions
59 
60  //- No copy construct
61  manualRenumber(const manualRenumber&) = delete;
62 
63  //- No copy assignment
64  void operator=(const manualRenumber&) = delete;
65 
66 public:
67 
68  //- Runtime type information
69  TypeName("manual");
70 
71 
72  // Constructors
73 
74  //- Construct given the renumber dictionary
75  manualRenumber(const dictionary& renumberDict);
76 
77 
78  //- Destructor
79  virtual ~manualRenumber() = default;
80 
81 
82  // Member Functions
83 
84  //- Return the order in which cells need to be visited, i.e.
85  // from ordered back to original cell label.
86  // This is only defined for geometric renumberMethods.
87  virtual labelList renumber(const pointField&) const
88  {
90  return labelList(0);
91  }
92 
93  //- Return the order in which cells need to be visited, i.e.
94  // from ordered back to original cell label.
95  // Use the mesh connectivity (if needed)
96  virtual labelList renumber
97  (
98  const polyMesh& mesh,
99  const pointField& cc
100  ) const;
101 
102  //- Return the order in which cells need to be visited, i.e.
103  // from ordered back to original cell label.
104  // The connectivity is equal to mesh.cellCells() except
105  // - the connections are across coupled patches
107  (
108  const labelListList& cellCells,
109  const pointField& cc
110  ) const
111  {
113  return labelList(0);
114  }
115 };
116 
117 
118 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
119 
120 } // End namespace Foam
121 
122 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
123 
124 #endif
125 
126 // ************************************************************************* //
Foam::labelList
List< label > labelList
A List of labels.
Definition: List.H:67
Foam::manualRenumber
Renumber given a ordered-to-original cell association in a file.
Definition: manualRenumber.H:48
Foam::fileName
A class for handling file names.
Definition: fileName.H:73
Foam::manualRenumber::~manualRenumber
virtual ~manualRenumber()=default
Destructor.
Foam::manualRenumber::renumber
virtual labelList renumber(const pointField &) const
Return the order in which cells need to be visited, i.e.
Definition: manualRenumber.H:86
Foam::polyMesh
Mesh consisting of general polyhedral cells.
Definition: polyMesh.H:77
NotImplemented
#define NotImplemented
Issue a FatalErrorIn for a function not currently implemented.
Definition: error.H:517
renumberMethod.H
Foam::Field< vector >
Foam::dictionary
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:123
mesh
dynamicFvMesh & mesh
Definition: createDynamicFvMesh.H:6
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Foam::renumberMethod
Abstract base class for renumbering.
Definition: renumberMethod.H:50
Foam::manualRenumber::TypeName
TypeName("manual")
Runtime type information.
Foam::List< label >