00001 /*---------------------------------------------------------------------------*\ 00002 ========= | 00003 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox 00004 \\ / O peration | 00005 \\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd. 00006 \\/ M anipulation | 00007 ------------------------------------------------------------------------------- 00008 License 00009 This file is part of OpenFOAM. 00010 00011 OpenFOAM is free software: you can redistribute it and/or modify it 00012 under the terms of the GNU General Public License as published by 00013 the Free Software Foundation, either version 3 of the License, or 00014 (at your option) any later version. 00015 00016 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT 00017 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 00018 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 00019 for more details. 00020 00021 You should have received a copy of the GNU General Public License 00022 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>. 00023 00024 Class 00025 Foam::cloudSet 00026 00027 Description 00028 00029 SourceFiles 00030 cloudSet.C 00031 00032 \*---------------------------------------------------------------------------*/ 00033 00034 #ifndef cloudSet_H 00035 #define cloudSet_H 00036 00037 #include <sampling/sampledSet.H> 00038 #include <OpenFOAM/DynamicList.H> 00039 00040 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00041 00042 namespace Foam 00043 { 00044 00045 // Forward declaration of classes 00046 class passiveParticle; 00047 template<class Type> class particle; 00048 00049 /*---------------------------------------------------------------------------*\ 00050 Class cloudSet Declaration 00051 \*---------------------------------------------------------------------------*/ 00052 00053 class cloudSet 00054 : 00055 public sampledSet 00056 { 00057 // Private data 00058 00059 //- Sampling points 00060 List<point> sampleCoords_; 00061 00062 00063 // Private Member Functions 00064 00065 //- Samples all points in sampleCoords. 00066 void calcSamples 00067 ( 00068 DynamicList<point>& samplingPts, 00069 DynamicList<label>& samplingCells, 00070 DynamicList<label>& samplingFaces, 00071 DynamicList<label>& samplingSegments, 00072 DynamicList<scalar>& samplingCurveDist 00073 ) const; 00074 00075 //- Uses calcSamples to obtain samples. Copies them into *this. 00076 void genSamples(); 00077 00078 public: 00079 00080 //- Runtime type information 00081 TypeName("cloud"); 00082 00083 00084 // Constructors 00085 00086 //- Construct from components 00087 cloudSet 00088 ( 00089 const word& name, 00090 const polyMesh& mesh, 00091 meshSearch& searchEngine, 00092 const word& axis, 00093 const List<point>& sampleCoords 00094 ); 00095 00096 //- Construct from dictionary 00097 cloudSet 00098 ( 00099 const word& name, 00100 const polyMesh& mesh, 00101 meshSearch& searchEngine, 00102 const dictionary& dict 00103 ); 00104 00105 00106 // Destructor 00107 00108 virtual ~cloudSet(); 00109 00110 00111 // Member Functions 00112 00113 //- Get reference point 00114 virtual point getRefPoint(const List<point>&) const; 00115 }; 00116 00117 00118 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00119 00120 } // End namespace Foam 00121 00122 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00123 00124 #endif 00125 00126 // ************************ vim: set sw=4 sts=4 et: ************************ //