tabulated6DoFAcceleration.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) 2015 OpenFOAM Foundation
9  Copyright (C) 2020 OpenCFD Ltd.
10 -------------------------------------------------------------------------------
11 License
12  This file is part of OpenFOAM.
13 
14  OpenFOAM is free software: you can redistribute it and/or modify it
15  under the terms of the GNU General Public License as published by
16  the Free Software Foundation, either version 3 of the License, or
17  (at your option) any later version.
18 
19  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22  for more details.
23 
24  You should have received a copy of the GNU General Public License
25  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26 
27 Class
28  Foam::tabulated6DoFAcceleration
29 
30 Description
31  Tabulated 6DoF acceleration.
32 
33  Obtained by interpolating tabulated data for linear acceleration,
34  angular velocity and angular acceleration.
35 
36 SourceFiles
37  tabulated6DoFAcceleration.C
38 
39 \*---------------------------------------------------------------------------*/
40 
41 #ifndef tabulated6DoFAcceleration_H
42 #define tabulated6DoFAcceleration_H
43 
44 #include "primitiveFields.H"
45 #include "Vector2D.H"
46 #include "Time.H"
47 
48 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
49 
50 namespace Foam
51 {
52 
53 /*---------------------------------------------------------------------------*\
54  Class tabulated6DoFAcceleration Declaration
55 \*---------------------------------------------------------------------------*/
56 
58 {
59  // Private Data
60 
61  //- Reference to Time
62  const Time& time_;
63 
64  //- Dictionary
65  dictionary accelerationCoeffs_;
66 
67  //- Time data file name read from dictionary
68  fileName timeDataFileName_;
69 
70  //- Type used to read in the acceleration "vectors"
72 
73  //- Field of times
74  scalarField times_;
75 
76  //- Field of acceleration "vectors"
78 
79 
80 public:
81 
82  //- Runtime type information
83  TypeName("tabulated6DoFAcceleration");
84 
85 
86  // Constructors
87 
88  //- Construct from components
90  (
91  const dictionary& accelerationCoeffs,
92  const Time& runTime
93  );
94 
95  //- No copy construct
97 
98  //- No copy assignment
99  void operator=(const tabulated6DoFAcceleration&) = delete;
100 
101 
102  //- Destructor
103  virtual ~tabulated6DoFAcceleration() = default;
104 
105 
106  // Member Functions
107 
108  //- Return the solid-body accelerations
109  virtual Vector<vector> acceleration() const;
110 
111  //- Update properties from given dictionary
112  virtual bool read(const dictionary& accelerationCoeffs);
113 };
114 
115 
116 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
117 
118 } // End namespace Foam
119 
120 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
121 
122 #endif
123 
124 // ************************************************************************* //
runTime
engineTime & runTime
Definition: createEngineTime.H:13
Foam::Time
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
Definition: Time.H:73
Foam::tabulated6DoFAcceleration::acceleration
virtual Vector< vector > acceleration() const
Return the solid-body accelerations.
Definition: tabulated6DoFAcceleration.C:60
Foam::tabulated6DoFAcceleration::operator=
void operator=(const tabulated6DoFAcceleration &)=delete
No copy assignment.
Foam::fileName
A class for handling file names.
Definition: fileName.H:73
primitiveFields.H
Specialisations of Field<T> for scalar, vector and tensor.
Foam::tabulated6DoFAcceleration
Tabulated 6DoF acceleration.
Definition: tabulated6DoFAcceleration.H:56
Vector2D.H
Foam::Field< scalar >
Foam::tabulated6DoFAcceleration::~tabulated6DoFAcceleration
virtual ~tabulated6DoFAcceleration()=default
Destructor.
Foam::tabulated6DoFAcceleration::read
virtual bool read(const dictionary &accelerationCoeffs)
Update properties from given dictionary.
Definition: tabulated6DoFAcceleration.C:96
Foam::dictionary
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:123
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Time.H
Foam::Vector< vector >
Foam::tabulated6DoFAcceleration::TypeName
TypeName("tabulated6DoFAcceleration")
Runtime type information.
Foam::tabulated6DoFAcceleration::tabulated6DoFAcceleration
tabulated6DoFAcceleration(const dictionary &accelerationCoeffs, const Time &runTime)
Construct from components.
Definition: tabulated6DoFAcceleration.C:45