randomRenumber.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) 2011-2012 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::randomRenumber
26 
27 Description
28  Random renumber. Just to see effect of renumbering.
29 
30 SourceFiles
31  randomRenumber.C
32 
33 \*---------------------------------------------------------------------------*/
34 
35 #ifndef randomRenumber_H
36 #define randomRenumber_H
37 
38 #include "renumberMethod.H"
39 
40 namespace Foam
41 {
42 
43 /*---------------------------------------------------------------------------*\
44  Class randomRenumber Declaration
45 \*---------------------------------------------------------------------------*/
46 
47 class randomRenumber
48 :
49  public renumberMethod
50 {
51  // Private Member Functions
52 
53  //- Disallow default bitwise copy construct and assignment
54  void operator=(const randomRenumber&);
56 
57 
58 public:
59 
60  //- Runtime type information
61  TypeName("random");
62 
63 
64  // Constructors
65 
66  //- Construct given the renumber dictionary
67  randomRenumber(const dictionary& renumberDict);
68 
69 
70  //- Destructor
71  virtual ~randomRenumber()
72  {}
73 
74 
75  // Member Functions
76 
77  //- Return the order in which cells need to be visited, i.e.
78  // from ordered back to original cell label.
79  // This is only defined for geometric renumberMethods.
80  virtual labelList renumber(const pointField&) const;
81 
82  //- Return the order in which cells need to be visited, i.e.
83  // from ordered back to original cell label.
84  // Use the mesh connectivity (if needed)
85  virtual labelList renumber
86  (
87  const polyMesh& mesh,
88  const pointField& cc
89  ) const;
90 
91  //- Return the order in which cells need to be visited, i.e.
92  // from ordered back to original cell label.
93  // The connectivity is equal to mesh.cellCells() except
94  // - the connections are across coupled patches
95  virtual labelList renumber
96  (
97  const labelListList& cellCells,
98  const pointField& cc
99  ) const;
100 };
101 
102 
103 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
104 
105 } // End namespace Foam
106 
107 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
108 
109 #endif
110 
111 // ************************************************************************* //
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:137
virtual ~randomRenumber()
Destructor.
Abstract base class for renumbering.
dynamicFvMesh & mesh
virtual labelList renumber(const pointField &) const
Return the order in which cells need to be visited, i.e.
TypeName("random")
Runtime type information.
Mesh consisting of general polyhedral cells.
Definition: polyMesh.H:74
Random renumber. Just to see effect of renumbering.
Namespace for OpenFOAM.