1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright held by original author
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 the
13 Free Software Foundation; either version 2 of the License, or (at your
14 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, write to the Free Software Foundation,
23 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
29 Automatic motion of the mesh around a moving body. A direction,
30 amplitude and frequency of translational motion and origin, axis,
31 amplitude and frequency of rotational motion must be specified.
37 Hrvoje Jasak, Wikki Ltd. All rights reserved
39 \*---------------------------------------------------------------------------*/
41 #ifndef dynamicBodyFvMesh_H
42 #define dynamicBodyFvMesh_H
44 #include "dynamicFvMesh.H"
45 #include "dimensionedTypes.H"
47 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
54 /*---------------------------------------------------------------------------*\
55 Class dynamicBodyFvMesh Declaration
56 \*---------------------------------------------------------------------------*/
58 class dynamicBodyFvMesh
64 //- Moving mesh dictionary
65 dictionary dynamicMeshCoeffs_;
67 //- Moving mesh solver
68 autoPtr<motionSolver> motionPtr_;
70 //- Name of the patch which encloses the body
76 //- Translational motion direction
77 vector translationDirection_;
79 //- Translational motion amplitude
80 scalar translationAmplitude_;
82 //- Translational motion frequency
83 scalar translationFrequency_;
85 //- Initial rotational motion origin
86 vector initialRotationOrigin_;
88 //- Rotational motion axis
91 //- Rotational motion amplitude
92 scalar rotationAmplitude_;
94 //- Rotational motion frequency
95 scalar rotationFrequency_;
98 // Private Member Functions
100 //- Disallow default bitwise copy construct
101 dynamicBodyFvMesh(const dynamicBodyFvMesh&);
103 //- Disallow default bitwise assignment
104 void operator=(const dynamicBodyFvMesh&);
109 //- Runtime type information
110 TypeName("dynamicBodyFvMesh");
115 //- Construct from IOobject
116 dynamicBodyFvMesh(const IOobject& io);
121 virtual ~dynamicBodyFvMesh();
126 //- Update the mesh for both mesh motion and topology change
127 virtual bool update();
131 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
133 } // End namespace Foam
135 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
139 // ************************************************************************* //