1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
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.
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
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/>.
28 Sample along poly line defined by a list of points (knots)
33 \*---------------------------------------------------------------------------*/
38 #include "sampledSet.H"
39 #include "DynamicList.H"
40 #include "passiveParticleCloud.H"
42 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47 /*---------------------------------------------------------------------------*\
48 Class polyLineSet Declaration
49 \*---------------------------------------------------------------------------*/
58 List<point> sampleCoords_;
61 // Private Member Functions
63 //- Sample till hits boundary. Called with singleParticle at position
64 // inbetween sampleCoords_[sampleI] and sampleCoords_[sampleI+1].
65 // Returns false if end of samples reached.
68 passiveParticle& singleParticle,
70 DynamicList<point>& samplingPts,
71 DynamicList<label>& samplingCells,
72 DynamicList<label>& samplingFaces,
73 DynamicList<scalar>& samplingCurveDist
76 //- Samples all point in sampleCoords_
77 // samplingSegments contains segmentNo for each sample.
80 DynamicList<point>& samplingPts,
81 DynamicList<label>& samplingCells,
82 DynamicList<label>& samplingFaces,
83 DynamicList<label>& samplingSegments,
84 DynamicList<scalar>& samplingCurveDist
87 //- Uses calcSamples to obtain samples. Copies them into *this.
93 //- Runtime type information
99 //- Construct from components
103 const polyMesh& mesh,
104 meshSearch& searchEngine,
106 const List<point>& samplePoints
109 //- Construct from dictionary
113 const polyMesh& mesh,
114 meshSearch& searchEngine,
115 const dictionary& dict
120 virtual ~polyLineSet();
124 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
126 } // End namespace Foam
128 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
132 // ************************************************************************* //