componentVelocityMotionSolver.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 | www.openfoam.com
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8  Copyright (C) 2012-2016 OpenFOAM Foundation
9 -------------------------------------------------------------------------------
10 License
11  This file is part of OpenFOAM.
12 
13  OpenFOAM is free software: you can redistribute it and/or modify it
14  under the terms of the GNU General Public License as published by
15  the Free Software Foundation, either version 3 of the License, or
16  (at your option) any later version.
17 
18  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21  for more details.
22 
23  You should have received a copy of the GNU General Public License
24  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25 
26 Class
27  Foam::componentVelocityMotionSolver
28 
29 Description
30  Virtual base class for velocity motion solver
31 
32  The boundary displacement is set as a boundary condition
33  on the pointMotionUX pointScalarField.
34 
35 SourceFiles
36  componentVelocityMotionSolver.C
37 
38 \*---------------------------------------------------------------------------*/
39 
40 #ifndef componentVelocityMotionSolver_H
41 #define componentVelocityMotionSolver_H
42 
43 #include "motionSolver.H"
44 #include "pointFields.H"
45 
46 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47 
48 namespace Foam
49 {
50 
51 class mapPolyMesh;
52 
53 /*---------------------------------------------------------------------------*\
54  Class componentVelocityMotionSolver Declaration
55 \*---------------------------------------------------------------------------*/
56 
58 :
59  public motionSolver
60 {
61 protected:
62 
63  // Protected data
64 
65  //- The component name to solve for
67 
68  //- The component to solve for
70 
71  //- Point motion field
73 
74 
75 private:
76 
77  // Private Member Functions
78 
79  //- Return the component corresponding to the given component name
80  direction cmpt(const word& cmptName) const;
81 
82  //- No copy construct
84  (
86  ) = delete;
87 
88  //- No copy assignment
89  void operator=(const componentVelocityMotionSolver&) = delete;
90 
91 public:
92 
93  //- Runtime type information
94  TypeName("componentVelocityMotionSolver");
95 
96 
97  // Constructors
98 
99  //- Construct from mesh and dictionary
101  (
102  const polyMesh&,
103  const IOdictionary&,
104  const word& type
105  );
106 
107 
108  //- Destructor
110 
111 
112  // Member Functions
113 
114  //- Non-const access to the pointMotionU in order to allow changes
115  // to the boundary motion
117  {
118  return pointMotionU_;
119  }
120 
121  //- Update local data for geometry changes
122  virtual void movePoints(const pointField&);
123 
124  //- Update local data for topology changes
125  virtual void updateMesh(const mapPolyMesh&);
126 };
127 
128 
129 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
130 
131 } // End namespace Foam
132 
133 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
134 
135 #endif
136 
137 // ************************************************************************* //
Foam::componentVelocityMotionSolver::updateMesh
virtual void updateMesh(const mapPolyMesh &)
Update local data for topology changes.
Definition: componentVelocityMotionSolver.C:110
Foam::IOdictionary
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
Definition: IOdictionary.H:54
Foam::componentVelocityMotionSolver::movePoints
virtual void movePoints(const pointField &)
Update local data for geometry changes.
Definition: componentVelocityMotionSolver.C:104
Foam::word
A class for handling words, derived from Foam::string.
Definition: word.H:65
Foam::componentVelocityMotionSolver::cmptName_
word cmptName_
The component name to solve for.
Definition: componentVelocityMotionSolver.H:65
Foam::componentVelocityMotionSolver::pointMotionU_
pointScalarField pointMotionU_
Point motion field.
Definition: componentVelocityMotionSolver.H:71
motionSolver.H
Foam::componentVelocityMotionSolver::cmpt_
direction cmpt_
The component to solve for.
Definition: componentVelocityMotionSolver.H:68
Foam::componentVelocityMotionSolver::TypeName
TypeName("componentVelocityMotionSolver")
Runtime type information.
Foam::polyMesh
Mesh consisting of general polyhedral cells.
Definition: polyMesh.H:77
Foam::Field< vector >
Foam::componentVelocityMotionSolver
Virtual base class for velocity motion solver.
Definition: componentVelocityMotionSolver.H:56
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Foam::motionSolver
Virtual base class for mesh motion solver.
Definition: motionSolver.H:58
Foam::type
fileName::Type type(const fileName &name, const bool followLink=true)
Return the file type: DIRECTORY or FILE, normally following symbolic links.
Definition: MSwindows.C:590
Foam::componentVelocityMotionSolver::~componentVelocityMotionSolver
virtual ~componentVelocityMotionSolver()
Destructor.
Definition: componentVelocityMotionSolver.C:98
Foam::direction
uint8_t direction
Definition: direction.H:52
Foam::mapPolyMesh
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
Definition: mapPolyMesh.H:161
Foam::GeometricField< scalar, pointPatchField, pointMesh >
pointFields.H
Foam::componentVelocityMotionSolver::pointMotionU
pointScalarField & pointMotionU()
Non-const access to the pointMotionU in order to allow changes.
Definition: componentVelocityMotionSolver.H:115