|
|
|
shapeToCell.HGo to the documentation of this file.00001 /*---------------------------------------------------------------------------*\ 00002 ========= | 00003 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox 00004 \\ / O peration | 00005 \\ / A nd | Copyright (C) 1991-2009 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 the 00013 Free Software Foundation; either version 2 of the License, or (at your 00014 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, write to the Free Software Foundation, 00023 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00024 00025 Class 00026 Foam::shapeToCell 00027 00028 Description 00029 A topoSetSource to select cells based on cell shape. 00030 00031 Handles all ones from cellModeller and splitHex with 10 degrees 00032 feature angle. 00033 00034 SourceFiles 00035 shapeToCell.C 00036 00037 \*---------------------------------------------------------------------------*/ 00038 00039 #ifndef shapeToCell_H 00040 #define shapeToCell_H 00041 00042 #include "topoSetSource.H" 00043 00044 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00045 00046 namespace Foam 00047 { 00048 00049 /*---------------------------------------------------------------------------*\ 00050 Class shapeToCell Declaration 00051 \*---------------------------------------------------------------------------*/ 00052 00053 class shapeToCell 00054 : 00055 public topoSetSource 00056 { 00057 00058 // Private data 00059 00060 //- Add usage string 00061 static addToUsageTable usage_; 00062 00063 //- Name of cell type 00064 word type_; 00065 00066 // Private Member Functions 00067 00068 //- Depending on cell type add to or delete from cellSet. 00069 void combine(topoSet& set, const bool add) const; 00070 00071 00072 public: 00073 00074 //- Runtime type information 00075 TypeName("shapeToCell"); 00076 00077 00078 // Static data 00079 00080 //- cos of feature angle for polyHedral to be splitHex 00081 static scalar featureCos; 00082 00083 // Constructors 00084 00085 //- Construct from components 00086 shapeToCell 00087 ( 00088 const polyMesh& mesh, 00089 const word& type 00090 ); 00091 00092 //- Construct from dictionary 00093 shapeToCell 00094 ( 00095 const polyMesh& mesh, 00096 const dictionary& dict 00097 ); 00098 00099 //- Construct from Istream 00100 shapeToCell 00101 ( 00102 const polyMesh& mesh, 00103 Istream& 00104 ); 00105 00106 00107 // Destructor 00108 00109 virtual ~shapeToCell(); 00110 00111 00112 // Member Functions 00113 00114 virtual void applyToSet 00115 ( 00116 const topoSetSource::setAction action, 00117 topoSet& 00118 ) const; 00119 00120 }; 00121 00122 00123 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00124 00125 } // End namespace Foam 00126 00127 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00128 00129 #endif 00130 00131 // ************************************************************************* // |