DASolidDisplacementFoam.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2 
3  DAFoam : Discrete Adjoint with OpenFOAM
4  Version : v3
5 
6  Description:
7  Child class for DASolidDisplacementFoam
8 
9  This class is modified from OpenFOAM's source code
10  applications/solvers/stressAnalysis/solidDisplacementFoam
11 
12  OpenFOAM: The Open Source CFD Toolbox
13 
14  Copyright (C): 2011-2016 OpenFOAM Foundation
15 
16  OpenFOAM License:
17 
18  OpenFOAM is free software: you can redistribute it and/or modify it
19  under the terms of the GNU General Public License as published by
20  the Free Software Foundation, either version 3 of the License, or
21  (at your option) any later version.
22 
23  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
24  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
25  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
26  for more details.
27 
28  You should have received a copy of the GNU General Public License
29  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
30 
31 \*---------------------------------------------------------------------------*/
32 
33 #ifndef DASolidDisplacementFoam_H
34 #define DASolidDisplacementFoam_H
35 
36 #include "Switch.H"
37 #include "DASolver.H"
38 #include "addToRunTimeSelectionTable.H"
39 
40 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
41 
42 namespace Foam
43 {
44 
45 /*---------------------------------------------------------------------------*\
46  Class DASolidDisplacementFoam Declaration
47 \*---------------------------------------------------------------------------*/
48 
50  : public DASolver
51 {
52 
53 protected:
54 
57 
59  label nCorr_;
60 
63 
65  autoPtr<IOdictionary> mechanicalPropertiesPtr_;
66 
68  autoPtr<volScalarField> rhoPtr_;
69 
71  autoPtr<volScalarField> muPtr_;
72 
74  autoPtr<volScalarField> lambdaPtr_;
75 
77  autoPtr<volScalarField> EPtr_;
78 
80  autoPtr<volScalarField> nuPtr_;
81 
83  autoPtr<volVectorField> DPtr_;
84 
86  autoPtr<volSymmTensorField> sigmaDPtr_;
87 
89  autoPtr<volTensorField> gradDPtr_;
90 
92  autoPtr<volVectorField> divSigmaExpPtr_;
93 
94 
95 public:
96  TypeName("DASolidDisplacementFoam");
97  // Constructors
98 
99  //- Construct from components
101  char* argsAll,
102  PyObject* pyOptions);
103 
104  //- Destructor
106  {
107  }
108 
110  virtual void initSolver();
111 
113  virtual label solvePrimal(
114  const Vec xvVec,
115  Vec wVec);
116 
117 };
118 
119 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
120 
121 } // End namespace Foam
122 
123 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
124 
125 #endif
126 
127 // ************************************************************************* //
Foam::DASolidDisplacementFoam::EPtr_
autoPtr< volScalarField > EPtr_
E field pointer.
Definition: DASolidDisplacementFoam.H:77
Foam::DASolidDisplacementFoam::muPtr_
autoPtr< volScalarField > muPtr_
mu field pointer
Definition: DASolidDisplacementFoam.H:71
Foam::DASolidDisplacementFoam
Definition: DASolidDisplacementFoam.H:49
Foam::DASolidDisplacementFoam::DPtr_
autoPtr< volVectorField > DPtr_
displacement field pointer
Definition: DASolidDisplacementFoam.H:83
Foam::DASolidDisplacementFoam::~DASolidDisplacementFoam
virtual ~DASolidDisplacementFoam()
Definition: DASolidDisplacementFoam.H:105
Foam::DASolver
Definition: DASolver.H:49
Foam::DASolidDisplacementFoam::nuPtr_
autoPtr< volScalarField > nuPtr_
nu field pointer
Definition: DASolidDisplacementFoam.H:80
Foam::DASolidDisplacementFoam::gradDPtr_
autoPtr< volTensorField > gradDPtr_
displacement gradient pointer
Definition: DASolidDisplacementFoam.H:89
Foam::DASolidDisplacementFoam::lambdaPtr_
autoPtr< volScalarField > lambdaPtr_
lambda field pointer
Definition: DASolidDisplacementFoam.H:74
Foam::DASolidDisplacementFoam::mechanicalPropertiesPtr_
autoPtr< IOdictionary > mechanicalPropertiesPtr_
mechanicalProperties pointer
Definition: DASolidDisplacementFoam.H:65
Foam::DASolidDisplacementFoam::sigmaDPtr_
autoPtr< volSymmTensorField > sigmaDPtr_
stress field pointer
Definition: DASolidDisplacementFoam.H:86
Foam::DASolidDisplacementFoam::TypeName
TypeName("DASolidDisplacementFoam")
Foam::DASolidDisplacementFoam::divSigmaExpPtr_
autoPtr< volVectorField > divSigmaExpPtr_
explicit part of div(sigma) pointer
Definition: DASolidDisplacementFoam.H:92
Foam::DASolidDisplacementFoam::solvePrimal
virtual label solvePrimal(const Vec xvVec, Vec wVec)
solve the primal equations
Definition: DASolidDisplacementFoam.C:80
Foam
Definition: multiFreqScalarFvPatchField.C:144
Foam::DASolidDisplacementFoam::convergenceTolerance_
scalar convergenceTolerance_
convergence tolerance for D
Definition: DASolidDisplacementFoam.H:62
Foam::DASolidDisplacementFoam::rhoPtr_
autoPtr< volScalarField > rhoPtr_
density field pointer
Definition: DASolidDisplacementFoam.H:68
Foam::DASolidDisplacementFoam::DASolidDisplacementFoam
DASolidDisplacementFoam(char *argsAll, PyObject *pyOptions)
Definition: DASolidDisplacementFoam.C:41
Foam::DASolidDisplacementFoam::initSolver
virtual void initSolver()
initialize fields and variables
Definition: DASolidDisplacementFoam.C:59
DASolver.H
Foam::DASolidDisplacementFoam::nCorr_
label nCorr_
number of correctors
Definition: DASolidDisplacementFoam.H:59
Foam::DASolidDisplacementFoam::compactNormalStress_
Switch compactNormalStress_
whether to use compact normal stress
Definition: DASolidDisplacementFoam.H:56