All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
fluidSolutionControl.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2018 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::fluidSolutionControl
26 
27 Description
28  Fluid solution control class. Holds flags specific to the solution of
29  fluids.
30 
31 SourceFiles
32  fluidSolutionControlI.H
33  fluidSolutionControl.C
34 
35 \*---------------------------------------------------------------------------*/
36 
37 #ifndef fluidSolutionControl_H
38 #define fluidSolutionControl_H
39 
41 
42 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
43 
44 namespace Foam
45 {
46 
47 /*---------------------------------------------------------------------------*\
48  Class fluidSolutionControl Declaration
49 \*---------------------------------------------------------------------------*/
50 
52 :
54 {
55 protected:
56 
57  // Protected data
58 
59  //- Flag to indicate not to solve for the flow
60  bool frozenFlow_;
61 
62  //- Flag to indicate to solve for momentum
63  bool momentumPredictor_;
64 
65  //- Flag to indicate to solve using transonic algorithm
66  bool transonic_;
67 
68  //- Flag to indicate to relax pressure using the "consistent" approach
69  // of simplec
70  bool consistent_;
71 
72 
73 public:
74 
75  // Static Data Members
76 
77  //- Run-time type information
78  TypeName("fluidSolutionControl");
79 
80 
81  // Constructors
82 
83  //- Construct from a mesh and the name of the algorithm
85 
86 
87  //- Destructor
88  virtual ~fluidSolutionControl();
89 
90 
91  // Member Functions
92 
93  // IO
94 
95  //- Read controls
96  virtual bool read();
97 
98  // Access
99 
100  //- Flag to indicate not to solve for the flow
101  inline bool frozenFlow() const;
102 
103  //- Flag to indicate to solve for momentum
104  inline bool momentumPredictor() const;
105 
106  //- Flag to indicate to solve using transonic algorithm
107  inline bool transonic() const;
108 
109  //- Flag to indicate to relax pressure using the "consistent"
110  // approach of simplec
111  inline bool consistent() const;
112 };
113 
114 
115 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
116 
117 } // End namespace Foam
118 
119 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
120 
121 #include "fluidSolutionControlI.H"
122 
123 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
124 
125 #endif
126 
127 // ************************************************************************* //
bool consistent() const
Flag to indicate to relax pressure using the "consistent".
bool consistent_
Flag to indicate to relax pressure using the "consistent" approach.
bool transonic_
Flag to indicate to solve using transonic algorithm.
A class for handling words, derived from string.
Definition: word.H:59
bool transonic() const
Flag to indicate to solve using transonic algorithm.
const fvMesh & mesh() const
Return the mesh.
fluidSolutionControl(fvMesh &mesh, const word &algorithmName)
Construct from a mesh and the name of the algorithm.
bool frozenFlow() const
Flag to indicate not to solve for the flow.
virtual bool read()
Read controls.
virtual ~fluidSolutionControl()
Destructor.
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:78
bool momentumPredictor() const
Flag to indicate to solve for momentum.
bool momentumPredictor_
Flag to indicate to solve for momentum.
bool frozenFlow_
Flag to indicate not to solve for the flow.
Fluid solution control class. Holds flags specific to the solution of fluids.
const word & algorithmName() const
Return the name of the algorithm.
Non-orthogonal solution control class. Provides non-orthogonal-loop control methods.
TypeName("fluidSolutionControl")
Run-time type information.
Namespace for OpenFOAM.