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-------------------------------------------------------------------------------
11License
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
27Class
28 Foam::tabulated6DoFAcceleration
29
30Description
31 Tabulated 6DoF acceleration.
32
33 Obtained by interpolating tabulated data for linear acceleration,
34 angular velocity and angular acceleration.
35
36SourceFiles
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
50namespace Foam
51{
52
53/*---------------------------------------------------------------------------*\
54 Class tabulated6DoFAcceleration Declaration
55\*---------------------------------------------------------------------------*/
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
80public:
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// ************************************************************************* //
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
Definition: Time.H:80
Templated 3D Vector derived from VectorSpace adding construction from 3 components,...
Definition: Vector.H:65
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
A class for handling file names.
Definition: fileName.H:76
tabulated6DoFAcceleration(const tabulated6DoFAcceleration &)=delete
No copy construct.
void operator=(const tabulated6DoFAcceleration &)=delete
No copy assignment.
virtual bool read(const dictionary &accelerationCoeffs)
Update properties from given dictionary.
virtual ~tabulated6DoFAcceleration()=default
Destructor.
virtual Vector< vector > acceleration() const
Return the solid-body accelerations.
TypeName("tabulated6DoFAcceleration")
Runtime type information.
engineTime & runTime
Namespace for OpenFOAM.
Specialisations of Field<T> for scalar, vector and tensor.
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73