1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
11 OpenFOAM is free software: you can redistribute it and/or modify it
12 under the terms of the GNU General Public License as published by
13 the Free Software Foundation, either version 3 of the License, or
14 (at your option) any later version.
16 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21 You should have received a copy of the GNU General Public License
22 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25 Foam::displacementSBRStressFvMotionSolver
28 Mesh motion solver for an fvMesh. Based on solving the cell-centre
29 solid-body rotation stress equations for the motion displacement.
32 displacementSBRStressFvMotionSolver.C
34 \*---------------------------------------------------------------------------*/
36 #ifndef displacementSBRStressFvMotionSolver_H
37 #define displacementSBRStressFvMotionSolver_H
39 #include "displacementFvMotionSolver.H"
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46 // Forward class declarations
47 class motionDiffusivity;
49 /*---------------------------------------------------------------------------*\
50 Class displacementSBRStressFvMotionSolver Declaration
51 \*---------------------------------------------------------------------------*/
53 class displacementSBRStressFvMotionSolver
55 public displacementFvMotionSolver
59 //- Point motion field
60 mutable pointVectorField pointDisplacement_;
62 //- Cell-centre motion field
63 mutable volVectorField cellDisplacement_;
65 //- Diffusivity used to control the motion
66 autoPtr<motionDiffusivity> diffusivityPtr_;
69 // Private Member Functions
71 //- Disallow default bitwise copy construct
72 displacementSBRStressFvMotionSolver
74 const displacementSBRStressFvMotionSolver&
77 //- Disallow default bitwise assignment
78 void operator=(const displacementSBRStressFvMotionSolver&);
83 //- Runtime type information
84 TypeName("displacementSBRStress");
89 //- Construct from polyMesh and data stream
90 displacementSBRStressFvMotionSolver
98 ~displacementSBRStressFvMotionSolver();
103 //- Return reference to the point motion displacement field
104 pointVectorField& pointDisplacement()
106 return pointDisplacement_;
109 //- Return const reference to the point motion displacement field
110 const pointVectorField& pointDisplacement() const
112 return pointDisplacement_;
115 //- Return reference to the cell motion displacement field
116 volVectorField& cellDisplacement()
118 return cellDisplacement_;
121 //- Return const reference to the cell motion displacement field
122 const volVectorField& cellDisplacement() const
124 return cellDisplacement_;
127 //- Return point location obtained from the current motion field
128 virtual tmp<pointField> curPoints() const;
131 virtual void solve();
134 virtual void updateMesh(const mapPolyMesh&);
138 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
140 } // End namespace Foam
142 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
146 // ************************************************************************* //