viewFactor2LI.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) 2023-2024 OpenCFD Ltd.
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::VF::viewFactor2LI
28 
29 Description
30  Computes view factors according to the double line integral (2LI) method.
31 
32 Usage
33  Minimal example in \c <constant>/viewFactorsDict:
34  \verbatim
35  // Optional entries
36  alpha <scalar>;
37 
38  // Inherited entries
39  ...
40  \endverbatim
41 
42  where the entries mean:
43  \table
44  Property | Description | Type | Reqd | Deflt
45  alpha | Perturbation for common edges | scalar | no | 0.21
46  \endtable
47 
48  The inherited entries are elaborated in:
49  - \link viewFactorModel.H \endlink
50 
51 SourceFiles
52  viewFactorModel.C
53 
54 \*---------------------------------------------------------------------------*/
55 
56 #ifndef Foam_vf_viewFactor2LI_H
57 #define Foam_vf_viewFactor2LI_H
58 
59 #include "viewFactorModel.H"
60 
61 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
62 
63 namespace Foam
64 {
65 
66 namespace VF
67 {
68 
69 /*---------------------------------------------------------------------------*\
70  Class viewFactor2LI Declaration
71 \*---------------------------------------------------------------------------*/
72 
73 class viewFactor2LI
74 :
75  public viewFactorModel
76 {
77 protected:
78 
79  // Protected Data
80 
81  //- Perturbation for common edges; default = 0.21
82  const scalar alpha_;
83 
84 
85  // Protected Member Functions
86 
87  //- Calculate view factor using the double-area integral
88  static scalar calculateFij
89  (
90  const List<point>& lPoints,
91  const List<point>& rPoints,
92  const scalar alpha
93  );
94 
95  //- Calculate
97  (
98  const labelListList& visibleFaceFaces,
99  const pointField& compactCf,
100  const vectorField& compactSf,
101  const List<List<vector>>& compactFineSf,
102  const List<List<point>>& compactFineCf,
103  const DynamicList<List<point>>& compactPoints,
104  const DynamicList<label>& compactPatchId
105  ) const;
106 
107 
108 public:
109 
110  //- Runtime type information
111  TypeName("viewFactor2LI");
112 
113  //- Constructor
114  viewFactor2LI(const fvMesh& mesh, const dictionary& dict);
115 
116  //- Destructor
117  virtual ~viewFactor2LI() = default;
118 };
119 
120 
121 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
122 
123 } // End namespace VF
124 } // End namespace Foam
125 
126 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
127 
128 #endif
129 
130 // ************************************************************************* //
const scalar alpha_
Perturbation for common edges; default = 0.21.
Definition: viewFactor2LI.H:91
dictionary dict
A list of keyword definitions, which are a keyword followed by a number of values (eg...
Definition: dictionary.H:129
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
Definition: BitOps.H:56
TypeName("viewFactor2LI")
Runtime type information.
dynamicFvMesh & mesh
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects...
Definition: DynamicList.H:51
virtual void calculate()
Calculate the view factors.
viewFactor2LI(const fvMesh &mesh, const dictionary &dict)
Constructor.
virtual ~viewFactor2LI()=default
Destructor.
static scalar calculateFij(const List< point > &lPoints, const List< point > &rPoints, const scalar alpha)
Calculate view factor using the double-area integral.
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:78
const dimensionedScalar alpha
Fine-structure constant: default SI units: [].
Namespace for OpenFOAM.