designVariablesI.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 PCOpt/NTUA
9  Copyright (C) 2021 FOSS GP
10 -------------------------------------------------------------------------------
11 License
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 * * * * * * * * * * * * * //
30 
31 inline const Foam::labelList&
33 {
35 }
36 
37 
39 {
40  return maxInitChange_.valid();
41 }
42 
43 
45 {
46  return maxInitChange_;
47 }
48 
49 
50 void Foam::designVariables::setMaxInitChange(const scalar maxInitChange)
51 {
52  maxInitChange_.reset(new scalar(maxInitChange));
53 }
54 
55 
57 {
58  return false;
59 }
60 
61 
64 {
65  return lowerBounds_;
66 }
67 
68 
71 {
72  return upperBounds_;
73 }
74 
75 
77 {
78  return lowerBounds_.ref();
79 }
80 
81 
83 {
84  return upperBounds_.ref();
85 }
86 
87 
88 // ************************************************************************* //
labelList activeDesignVariables_
Which of the design variables will be updated.
scalarField & upperBoundsRef()
Get max bounds for the design variables.
const autoPtr< scalar > & getMaxInitChange()
Get maxInitChange.
const autoPtr< scalarField > & lowerBounds() const
Get min bounds for the design variables.
bool isMaxInitChangeSet() const
Check whether the max. initial change of the design variables has been set.
const labelList & activeDesignVariables() const
Return list of active design variables.
void setMaxInitChange(const scalar maxInitChange)
Set maxInitChange.
scalarField & lowerBoundsRef()
Get min bounds for the design variables.
Pointer management similar to std::unique_ptr, with some additional methods and type checking...
Definition: HashPtrTable.H:48
virtual bool resetEta() const
Trigger the recomputation of eta by updateMethod.
const autoPtr< scalarField > & upperBounds() const
Get max bounds for the design variables.