radialActuationDiskSource.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2011-2023 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::fv::radialActuationDiskSource
26 
27 Description
28  Actuation disk source including radial thrust
29 
30  Constant values for momentum source for actuation disk
31 
32  \f[
33  T = 2 \rho A U_{o}^2 a (1-a)
34  \f]
35 
36  and
37 
38  \f[
39  U_1 = (1 - a)U_{o}
40  \f]
41 
42  where:
43  \vartable
44  A | disk area
45  U_o | upstream velocity
46  a | 1 - Cp/Ct
47  U_1 | velocity at the disk
48  \endvartable
49 
50  The thrust is distributed by a radial function:
51 
52  \f[
53  thrust(r) = T (C_0 + C_1 r^2 + C_2 r^4)
54  \f]
55 
56 Usage
57  Example usage:
58  \verbatim
59  radialActuationDiskSource1
60  {
61  type radialActuationDiskSource;
62 
63  select cellSet;
64  cellSet radialActuationDisk1;
65 
66  U U; // Name of the velocity field
67 
68  diskDir (-1 0 0); // Disk direction
69  Cp 0.1; // Power coefficient
70  Ct 0.5; // Thrust coefficient
71  diskArea 5.0; // Disk area
72  coeffs (0.1 0.5 0.01); // Radial distribution coefficients
73  upstreamPoint (0 0 0); // Upstream point
74  }
75  \endverbatim
76 
77 
78 SourceFiles
79  radialActuationDiskSource.C
80  radialActuationDiskSourceTemplates.C
81 
82 \*---------------------------------------------------------------------------*/
83 
84 #ifndef radialActuationDiskSource_H
85 #define radialActuationDiskSource_H
86 
87 #include "actuationDiskSource.H"
88 #include "FixedList.H"
89 
90 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
91 
92 namespace Foam
93 {
94 namespace fv
95 {
96 
97 /*---------------------------------------------------------------------------*\
98  Class radialActuationDiskSource Declaration
99 \*---------------------------------------------------------------------------*/
100 
101 class radialActuationDiskSource
102 :
103  public actuationDiskSource
104 {
105  // Private Data
106 
107  //- Coefficients for the radial distribution
108  FixedList<scalar, 3> radialCoeffs_;
109 
110 
111  // Private Member Functions
112 
113  //- Non-virtual read
114  void readCoeffs();
115 
116  //- Add resistance to the UEqn
117  template<class RhoFieldType>
118  void addRadialActuationDiskAxialInertialResistance
119  (
120  vectorField& Usource,
121  const labelList& cells,
122  const scalarField& V,
123  const RhoFieldType& rho,
124  const vectorField& U
125  ) const;
126 
127 
128 public:
129 
130  //- Runtime type information
131  TypeName("radialActuationDiskSource");
132 
133 
134  // Constructors
135 
136  //- Construct from components
138  (
139  const word& name,
140  const word& modelType,
141  const fvMesh& mesh,
142  const dictionary& dict
143  );
144 
145  //- Disallow default bitwise copy construction
147 
148 
149  //- Destructor
151  {}
152 
153 
154  // Member Functions
155 
156  //- Source term to momentum equation
157  virtual void addSup
158  (
159  fvMatrix<vector>& eqn,
160  const word& fieldName
161  ) const;
162 
163  //- Source term to compressible momentum equation
164  virtual void addSup
165  (
166  const volScalarField& rho,
167  fvMatrix<vector>& eqn,
168  const word& fieldName
169  ) const;
170 
171 
172  // IO
173 
174  //- Read dictionary
175  virtual bool read(const dictionary& dict);
176 
177 
178  // Member Operators
179 
180  //- Disallow default bitwise assignment
181  void operator=(const radialActuationDiskSource&) = delete;
182 };
183 
184 
185 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
186 
187 } // End namespace fv
188 } // End namespace Foam
189 
190 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
191 
192 #ifdef NoRepository
194 #endif
195 
196 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
197 
198 #endif
199 
200 // ************************************************************************* //
Generic GeometricField class.
A list of keyword definitions, which are a keyword followed by any number of values (e....
Definition: dictionary.H:160
A special matrix type and solver, designed for finite volume solutions of scalar equations....
Definition: fvMatrix.H:118
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:101
const fvMesh & mesh() const
Return const access to the mesh database.
Definition: fvModelI.H:34
const word & name() const
Return const access to the source name.
Definition: fvModelI.H:28
Actuation disk source including radial thrust.
TypeName("radialActuationDiskSource")
Runtime type information.
radialActuationDiskSource(const word &name, const word &modelType, const fvMesh &mesh, const dictionary &dict)
Construct from components.
void operator=(const radialActuationDiskSource &)=delete
Disallow default bitwise assignment.
virtual bool read(const dictionary &dict)
Read dictionary.
virtual void addSup(fvMatrix< vector > &eqn, const word &fieldName) const
Source term to momentum equation.
A class for handling words, derived from string.
Definition: word.H:62
const cellShapeList & cells
U
Definition: pEqn.H:72
Namespace for OpenFOAM.
labelList fv(nPoints)
dictionary dict