primalSolver.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) 2007-2019 PCOpt/NTUA
9 Copyright (C) 2013-2019 FOSS GP
10 Copyright (C) 2019 OpenCFD Ltd.
11-------------------------------------------------------------------------------
12License
13 This file is part of OpenFOAM.
14
15 OpenFOAM is free software: you can redistribute it and/or modify it
16 under the terms of the GNU General Public License as published by
17 the Free Software Foundation, either version 3 of the License, or
18 (at your option) any later version.
19
20 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
21 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
22 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
23 for more details.
24
25 You should have received a copy of the GNU General Public License
26 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
27
28
29Class
30 Foam::primalSolver
31
32Description
33 Base class for primal solvers
34
35\*---------------------------------------------------------------------------*/
36
37#ifndef primalSolver_H
38#define primalSolver_H
39
40#include "fvMesh.H"
41#include "solver.H"
43
44// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
45
46namespace Foam
47{
48
49/*---------------------------------------------------------------------------*\
50 Class primalSolver Declaration
51\*---------------------------------------------------------------------------*/
53class primalSolver
54:
55 public solver
56{
57private:
58
59 // Private Member Functions
60
61 //- No copy construct
62 primalSolver(const primalSolver&) = delete;
63
64 //- No copy assignment
65 void operator=(const primalSolver&) = delete;
66
67
68public:
69
70
71 // Static Data Members
72
73 //- Run-time type information
74 TypeName("primalSolver");
75
76
77 // Declare run-time constructor selection table
80 (
81 autoPtr,
84 (
85 fvMesh& mesh,
86 const word& managerType,
87 const dictionary& dict
88 ),
89 (mesh, managerType, dict)
90 );
91
92
93 // Constructors
94
95 //- Construct from mesh and dictionary
97 (
98 fvMesh& mesh,
99 const word& managerType,
100 const dictionary& dict
101 );
102
103
104 // Selectors
105
106 //- Return a reference to the selected primal solver
108 (
109 fvMesh& mesh,
110 const word& managerType,
111 const dictionary& dict
112 );
113
114
115 //- Destructor
116 virtual ~primalSolver() = default;
117
118
119 // Member Functions
120
121 virtual bool readDict(const dictionary& dict);
122
123
124 // Evolution
125
126 //- update boundary conditions
127 virtual void correctBoundaryConditions();
128};
129
130
131// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
132
133} // End namespace Foam
134
135// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
136
137#endif
138
139// ************************************************************************* //
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: autoPtr.H:66
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:91
Base class for primal solvers.
Definition: primalSolver.H:55
virtual bool readDict(const dictionary &dict)
Definition: primalSolver.C:86
TypeName("primalSolver")
Run-time type information.
virtual ~primalSolver()=default
Destructor.
declareRunTimeNewSelectionTable(autoPtr, primalSolver, primalSolver,(fvMesh &mesh, const word &managerType, const dictionary &dict),(mesh, managerType, dict))
virtual void correctBoundaryConditions()
update boundary conditions
Definition: primalSolver.C:97
static autoPtr< primalSolver > New(fvMesh &mesh, const word &managerType, const dictionary &dict)
Return a reference to the selected primal solver.
Definition: primalSolver.C:59
Base class for solution control classes.
Definition: solver.H:54
virtual const dictionary & dict() const
Return the solver dictionary.
Definition: solver.C:113
const fvMesh & mesh() const
Return the solver mesh.
Definition: solver.C:96
A class for handling words, derived from Foam::string.
Definition: word.H:68
Namespace for OpenFOAM.
Macros to ease declaration of run-time selection tables.
#define declareRunTimeNewSelectionTable(ptrWrapper, baseType, argNames, argList, parList)
Declare a run-time selection for derived classes.
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73