displacementInterpolationMotionSolver.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
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.
15 
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
19  for more details.
20 
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/>.
23 
24 Class
25  Foam::displacementInterpolationMotionSolver
26 
27 Description
28  Mesh motion solver for an fvMesh.
29 
30  Scales inbetween motion prescribed on faceZones. Works out per point
31  the distance between the bounding face zones (in all three directions)
32  at the start and then every time step
33  - moves the faceZones based on tables
34  - interpolates the displacement of all points based on the
35  faceZone motion.
36 
37  Tables are in the \a constant/tables directory.
38 
39 SourceFiles
40  displacementInterpolationMotionSolver.C
41 
42 \*---------------------------------------------------------------------------*/
43 
44 #ifndef displacementInterpolationMotionSolver_H
45 #define displacementInterpolationMotionSolver_H
46 
48 
49 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
50 
51 namespace Foam
52 {
53 
54 /*---------------------------------------------------------------------------*\
55  Class displacementInterpolationMotionSolver Declaration
56 \*---------------------------------------------------------------------------*/
57 
59 :
61 {
62  // Private data
63 
64  // Face zone information (note: could pack these to only contain
65  // used zones)
66 
67  //- Interpolation table. From faceZone to times.
68  List<scalarField> times_;
69 
70  //- Interpolation table. From faceZone to displacements.
71  List<vectorField> displacements_;
72 
73  // Range information.
74 
75  //- Per direction, per range the index of the lower
76  // faceZone
77  FixedList<labelList, 3> rangeToZone_;
78 
79  //- Per direction, per range the points that are in it
80  FixedList<labelListList, 3> rangeToPoints_;
81 
82  //- Per direction, per range the weight of the points relative
83  // to this and the next range.
84  FixedList<List<scalarField>, 3> rangeToWeights_;
85 
86 
87  // Private Member Functions
88 
89  //- Disallow default bitwise copy construct
91  (
93  );
94 
95  //- Disallow default bitwise assignment
96  void operator=(const displacementInterpolationMotionSolver&);
97 
98 
99 public:
100 
101  //- Runtime type information
102  TypeName("displacementInterpolation");
103 
104 
105  // Constructors
106 
107  //- Construct from polyMesh and IOdictionary
109  (
110  const polyMesh&,
111  const IOdictionary& dict
112  );
113 
114 
115  //- Destructor
117 
118 
119  // Member Functions
120 
121  //- Return point location obtained from the current motion field
122  virtual tmp<pointField> curPoints() const;
123 
124  //- Solve for motion
125  virtual void solve()
126  {}
127 };
128 
129 
130 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
131 
132 } // End namespace Foam
133 
134 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
135 
136 #endif
137 
138 // ************************************************************************* //
dictionary dict
Virtual base class for displacement motion solver.
A 1D vector of objects of type <T> with a fixed size <Size>.
Definition: FixedList.H:53
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
Definition: IOdictionary.H:53
virtual tmp< pointField > curPoints() const
Return point location obtained from the current motion field.
Mesh consisting of general polyhedral cells.
Definition: polyMesh.H:74
A class for managing temporary objects.
Definition: PtrList.H:54
TypeName("displacementInterpolation")
Runtime type information.
Namespace for OpenFOAM.