Loading...
Searching...
No Matches
solverI.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) 2021-2023 PCOpt/NTUA
9 Copyright (C) 2021-2023 FOSS GP
10-------------------------------------------------------------------------------
11License
12 This file is part of OpenFOAM.
13
14 OpenFOAM is free software: you can redistribute it and/or modify it
15 under the terms of the GNU General Public License as published by
16 the Free Software Foundation, either version 3 of the License, or
17 (at your option) any later version.
18
19 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22 for more details.
23
24 You should have received a copy of the GNU General Public License
25 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26
27\*---------------------------------------------------------------------------*/
28
29// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
32{
33 return mesh_;
34}
35
38{
39 return solverName_;
40}
41
46}
47
50{
51 return (useSolverNameForFields_ ? word(varName + solverName_) : varName);
52}
53
56{
57 return active_;
58}
59
62{
63 return dict_;
64}
65
68{
69 return vars_();
70}
71
76}
77
80{
81 return managerType_;
82}
83
84
85bool Foam::solver::isMaster() const
86{
87 return isMaster_;
88}
89
90
91// ************************************************************************* //
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition dictionary.H:133
Mesh data needed to do the Finite Volume discretisation.
Definition fvMesh.H:85
autoPtr< variablesSet > vars_
Base variableSet pointer.
Definition solver.H:95
const word & managerType() const
Return the manager type.
Definition solverI.H:72
bool active()
Return state of solver.
Definition solverI.H:48
bool active_
Solve equations?
Definition solver.H:76
bool useSolverNameForFields_
Append the variables related to the solver with it name.
Definition solver.H:88
bool isMaster_
Is the solver the master one.
Definition solver.H:83
const word managerType_
The optimisation type.
Definition solver.H:61
dictionary dict_
Dictionary holding the solver info.
Definition solver.H:66
bool isMaster() const
Whether the solver is the master one, in case of coupled solvers.
Definition solverI.H:78
word extendedVariableName(const word &varName) const
Given a variable name, return a name that is possibly appended by the solverName, depending on useSol...
Definition solverI.H:42
bool useSolverNameForFields() const
Use solver name as a suffix to the involved fields.
Definition solverI.H:36
const variablesSet & getVariablesSet() const
Return constant reference to variableSet used by the solver.
Definition solverI.H:60
const dictionary & dict() const
Return the solver dictionary.
Definition solverI.H:54
const word solverName_
Solver name.
Definition solver.H:71
const fvMesh & mesh() const
Return the solver mesh.
Definition solverI.H:24
const word & solverName() const
Return the solver name.
Definition solverI.H:30
fvMesh & mesh_
Reference to the mesh database.
Definition solver.H:56
Base class for creating a set of variables.
A class for handling words, derived from Foam::string.
Definition word.H:66