rayShooting.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 | Copyright (C) 2013-2015 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::rayShooting
26 
27 Description
28 
29 SourceFiles
30  rayShooting.C
31 
32 \*---------------------------------------------------------------------------*/
33 
34 #ifndef rayShooting_H
35 #define rayShooting_H
36 
37 #include "initialPointsMethod.H"
38 
39 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
40 
41 namespace Foam
42 {
43 
44 /*---------------------------------------------------------------------------*\
45  Class rayShooting Declaration
46 \*---------------------------------------------------------------------------*/
47 
48 class rayShooting
49 :
50  public initialPointsMethod
51 {
52 
53 private:
54 
55  // Private data
56 
57  //- Should the initial positions be randomised
59 
60  //- Randomise the initial positions by fraction of the initialCellSize_
62 
63 
64  // Private Member Functions
65 
66  void splitLine
67  (
68  const line<point, point>& l,
69  const scalar& pert,
71  ) const;
72 
73 
74 public:
75 
76  //- Runtime type information
77  TypeName("rayShooting");
78 
79  // Constructors
80 
81  //- Construct from components
83  (
84  const dictionary& initialPointsDict,
85  const Time& runTime,
86  Random& rndGen,
90  );
91 
92 
93  //- Destructor
94  virtual ~rayShooting()
95  {}
96 
97 
98  // Member Functions
99 
100  //- Return the initial points for the conformalVoronoiMesh
101  virtual List<Vb::Point> initialPoints() const;
102 };
103 
104 
105 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
106 
107 } // End namespace Foam
108 
109 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
110 
111 #endif
112 
113 // ************************************************************************* //
Foam::Random
Simple random number generator.
Definition: Random.H:49
Foam::Switch
A simple wrapper around bool so that it can be read as a word: true/false, on/off,...
Definition: Switch.H:60
Foam::initialPointsMethod::cellShapeControls
const cellShapeControl & cellShapeControls() const
Definition: initialPointsMethod.H:180
Foam::Time
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
Definition: Time.H:68
Foam::initialPointsMethod::decomposition
const backgroundMeshDecomposition & decomposition() const
Definition: initialPointsMethod.H:185
Foam::DynamicList
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects.
Definition: DynamicList.H:56
Foam::rayShooting::splitLine
void splitLine(const line< point, point > &l, const scalar &pert, DynamicList< Vb::Point > &initialPoints) const
Foam::rayShooting::TypeName
TypeName("rayShooting")
Runtime type information.
Foam::conformationSurfaces
Definition: conformationSurfaces.H:53
Foam::rayShooting::randomiseInitialGrid_
Switch randomiseInitialGrid_
Should the initial positions be randomised.
Definition: rayShooting.H:57
Foam::rayShooting::initialPoints
virtual List< Vb::Point > initialPoints() const
Return the initial points for the conformalVoronoiMesh.
Foam::initialPointsMethod::geometryToConformTo
const conformationSurfaces & geometryToConformTo() const
Definition: initialPointsMethod.H:175
Foam::dictionary
A list of keyword definitions, which are a keyword followed by any number of values (e....
Definition: dictionary.H:137
Foam::cellShapeControl
Definition: cellShapeControl.H:62
Foam
Namespace for OpenFOAM.
Definition: combustionModel.C:30
Foam::initialPointsMethod
Abstract base class for generating initial points for a conformalVoronoiMesh.
Definition: initialPointsMethod.H:55
Foam::rayShooting::~rayShooting
virtual ~rayShooting()
Destructor.
Definition: rayShooting.H:93
Foam::rayShooting::rayShooting
rayShooting(const dictionary &initialPointsDict, const Time &runTime, Random &rndGen, const conformationSurfaces &geometryToConformTo, const cellShapeControl &cellShapeControls, const autoPtr< backgroundMeshDecomposition > &decomposition)
Construct from components.
Foam::autoPtr
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:117
initialPointsMethod.H
Foam::initialPointsMethod::rndGen
Random & rndGen() const
Definition: initialPointsMethod.H:170
Foam::List
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
Definition: HashTable.H:59
Foam::line
A line primitive.
Definition: line.H:56
Foam::rayShooting::randomPerturbationCoeff_
scalar randomPerturbationCoeff_
Randomise the initial positions by fraction of the initialCellSize_.
Definition: rayShooting.H:60
Foam::rayShooting
Definition: rayShooting.H:47