DAFoam
v3.0.6
Discrete Adjoint with OpenFOAM
dafoam
src
adjoint
DARegDb
DARegDbNearWallDist.H
Go to the documentation of this file.
1
/*---------------------------------------------------------------------------*\
2
3
DAFoam : Discrete Adjoint with OpenFOAM
4
Version : v3
5
6
Description:
7
Register wall distance to Foam::fvMesh
8
9
Example:
10
11
To register a nearWallDist object to fvMesh:
12
13
nearWallDist& d = const_cast<nearWallDist&>(turbulence->y());
14
DARegDbNearWallDist daD(mesh,d);
15
16
Then, to get the registered nearWallDist object from fvMesh:
17
18
const DARegDbNearWallDist& daD1=
19
mesh.thisDb().lookupObject<DARegDbNearWallDist>("DARegDbNearWallDist");
20
const nearWallDist& d1 = daD1.getObject();
21
22
\*---------------------------------------------------------------------------*/
23
24
#ifndef DARegDbNearWallDist_H
25
#define DARegDbNearWallDist_H
26
27
#include "fvOptions.H"
28
#include "nearWallDist.H"
29
30
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
31
32
namespace
Foam
33
{
34
35
/*---------------------------------------------------------------------------*\
36
Class DARegDbNearWallDist Declaration
37
\*---------------------------------------------------------------------------*/
38
39
class
DARegDbNearWallDist
40
:
public
regIOobject
41
{
42
43
private
:
45
DARegDbNearWallDist
(
const
DARegDbNearWallDist
&);
46
48
void
operator=(
const
DARegDbNearWallDist
&);
49
51
const
fvMesh& mesh_;
52
54
const
nearWallDist& nearWallDist_;
55
56
public
:
58
DARegDbNearWallDist
(
59
const
fvMesh&
mesh
,
60
const
nearWallDist& nearWallDist);
61
63
virtual
~DARegDbNearWallDist
();
64
66
const
nearWallDist&
getObject
()
const
67
{
68
return
nearWallDist_;
69
}
70
72
bool
writeData
(Ostream& os)
const
;
73
};
74
75
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
76
77
}
// End namespace Foam
78
79
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
80
81
#endif
82
83
// ************************************************************************* //
Foam::DARegDbNearWallDist
Definition:
DARegDbNearWallDist.H:39
mesh
fvMesh & mesh
Definition:
createRefsHeatTransfer.H:4
Foam::DARegDbNearWallDist::~DARegDbNearWallDist
virtual ~DARegDbNearWallDist()
Destructor.
Definition:
DARegDbNearWallDist.C:33
Foam::DARegDbNearWallDist::writeData
bool writeData(Ostream &os) const
this is a virtual function for regIOobject
Definition:
DARegDbNearWallDist.C:38
Foam
Definition:
multiFreqScalarFvPatchField.C:144
Foam::DARegDbNearWallDist::getObject
const nearWallDist & getObject() const
return nearWallDist_
Definition:
DARegDbNearWallDist.H:66
Generated by
1.8.17