pairGAMGAgglomeration.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-2013 OpenFOAM Foundation
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::pairGAMGAgglomeration
28
29Description
30 Agglomerate using the pair algorithm.
31
32SourceFiles
33 pairGAMGAgglomeration.C
34 pairGAMGAgglomerate.C
35
36\*---------------------------------------------------------------------------*/
37
38#ifndef pairGAMGAgglomeration_H
39#define pairGAMGAgglomeration_H
40
41#include "GAMGAgglomeration.H"
42
43// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
44
45namespace Foam
46{
47
48/*---------------------------------------------------------------------------*\
49 Class pairGAMGAgglomeration Declaration
50\*---------------------------------------------------------------------------*/
53:
55{
56 // Private data
57
58 //- Number of levels to merge, 1 = don't merge, 2 = merge pairs etc.
59 label mergeLevels_;
60
61 //- Direction of cell loop for the current level
62 static bool forward_;
63
64
65protected:
66
67 // Protected Member Functions
68
69 //- Agglomerate all levels starting from the given face weights
70 void agglomerate
71 (
72 const lduMesh& mesh,
73 const scalarField& faceWeights
74 );
75
76 //- No copy construct
78
79 //- No copy assignment
80 void operator=(const pairGAMGAgglomeration&) = delete;
81
82
83public:
84
85 //- Runtime type information
86 TypeName("pair");
87
88
89 // Constructors
90
91 //- Construct given mesh and controls
93 (
94 const lduMesh& mesh,
96 );
97
98 //- Calculate and return agglomeration
100 (
101 label& nCoarseCells,
102 const lduAddressing& fineMatrixAddressing,
103 const scalarField& faceWeights
104 );
105};
106
107
108// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
109
110} // End namespace Foam
111
112// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
113
114#endif
115
116// ************************************************************************* //
Geometric agglomerated algebraic multigrid agglomeration class.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
The class contains the addressing required by the lduMatrix: upper, lower and losort.
Abstract base class for meshes which provide LDU addressing for the construction of lduMatrix and LDU...
Definition: lduMesh.H:63
Agglomerate using the pair algorithm.
void agglomerate(const lduMesh &mesh, const scalarField &faceWeights)
Agglomerate all levels starting from the given face weights.
TypeName("pair")
Runtime type information.
void operator=(const pairGAMGAgglomeration &)=delete
No copy assignment.
pairGAMGAgglomeration(const pairGAMGAgglomeration &)=delete
No copy construct.
A class for managing temporary objects.
Definition: tmp.H:65
runTime controlDict().readEntry("adjustTimeStep"
Namespace for OpenFOAM.
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73