DAFunctionMoment.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2 
3  DAFoam : Discrete Adjoint with OpenFOAM
4  Version : v4
5 
6  Description:
7  Child class for moment
8 
9 \*---------------------------------------------------------------------------*/
10 
11 #ifndef DAFunctionMoment_H
12 #define DAFunctionMoment_H
13 
14 #include "DAFunction.H"
15 #include "addToRunTimeSelectionTable.H"
16 
17 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
18 
19 namespace Foam
20 {
21 
22 /*---------------------------------------------------------------------------*\
23  Class DAFunctionMoment Declaration
24 \*---------------------------------------------------------------------------*/
25 
27  : public DAFunction
28 {
29 
30 protected:
32  vector momentDir_;
33 
35  vector momentCenter_;
36 
39 
40 public:
41  TypeName("moment");
42  // Constructors
43 
44  //- Construct from components
46  const fvMesh& mesh,
47  const DAOption& daOption,
48  const DAModel& daModel,
49  const DAIndex& daIndex,
50  const word functionName);
51 
52  //- Destructor
54  {
55  }
56 
58  virtual scalar calcFunction();
59 };
60 
61 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
62 
63 } // End namespace Foam
64 
65 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
66 
67 #endif
68 
69 // ************************************************************************* //
Foam::DAFunctionMoment::calcFunction
virtual scalar calcFunction()
calculate the value of objective function
Definition: DAFunctionMoment.C:58
Foam::DAFunctionMoment::momentCenter_
vector momentCenter_
the center of rotation for moment
Definition: DAFunctionMoment.H:35
Foam::DAOption
Definition: DAOption.H:29
DAFunction.H
Foam::DAFunctionMoment
Definition: DAFunctionMoment.H:26
Foam::DAFunctionMoment::~DAFunctionMoment
virtual ~DAFunctionMoment()
Definition: DAFunctionMoment.H:53
mesh
fvMesh & mesh
Definition: createRefsHeatTransfer.H:4
Foam::DAIndex
Definition: DAIndex.H:32
Foam::DAModel
Definition: DAModel.H:57
Foam::DAFunction
Definition: DAFunction.H:31
Foam
Definition: checkGeometry.C:32
Foam::DATurbulenceModel
Definition: DATurbulenceModel.H:52
Foam::DAFunctionMoment::momentDir_
vector momentDir_
the direction of the moment
Definition: DAFunctionMoment.H:32
Foam::DAFunctionMoment::TypeName
TypeName("moment")
Foam::DAFunctionMoment::daTurb_
const DATurbulenceModel & daTurb_
DATurbulenceModel object.
Definition: DAFunctionMoment.H:38
Foam::DAFunctionMoment::DAFunctionMoment
DAFunctionMoment(const fvMesh &mesh, const DAOption &daOption, const DAModel &daModel, const DAIndex &daIndex, const word functionName)
Definition: DAFunctionMoment.C:19