|
|
|
movingConeTopoFvMesh.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::movingConeTopoFvMesh 00027 00028 Description 00029 Sample topoChangerFvMesh that moves an object in x direction 00030 and introduces/removes layers. 00031 00032 SourceFiles 00033 movingConeTopoFvMesh.C 00034 00035 \*---------------------------------------------------------------------------*/ 00036 00037 #ifndef movingConeTopoFvMesh_H 00038 #define movingConeTopoFvMesh_H 00039 00040 #include "topoChangerFvMesh.H" 00041 #include "motionSolver.H" 00042 00043 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00044 00045 namespace Foam 00046 { 00047 00048 // Forward declaration of classes 00049 00050 /*---------------------------------------------------------------------------*\ 00051 Class movingConeTopoFvMesh Declaration 00052 \*---------------------------------------------------------------------------*/ 00053 00054 class movingConeTopoFvMesh 00055 : 00056 public topoChangerFvMesh 00057 { 00058 // Private data 00059 00060 //- Motion dictionary 00061 dictionary motionDict_; 00062 00063 //- Motion velocity amplitude 00064 vector motionVelAmplitude_; 00065 00066 //- Motion velocity period 00067 scalar motionVelPeriod_; 00068 00069 //- Motion velocity period 00070 vector curMotionVel_; 00071 00072 //- Left edge 00073 scalar leftEdge_; 00074 00075 //- Current left obstacle position 00076 scalar curLeft_; 00077 00078 //- Current right obstacle position 00079 scalar curRight_; 00080 00081 //- Vertex motion mask 00082 scalarField motionMask_; 00083 00084 00085 // Private Member Functions 00086 00087 //- Disallow default bitwise copy construct 00088 movingConeTopoFvMesh(const movingConeTopoFvMesh&); 00089 00090 //- Disallow default bitwise assignment 00091 void operator=(const movingConeTopoFvMesh&); 00092 00093 00094 //- Add mixer zones and modifiers 00095 void addZonesAndModifiers(); 00096 00097 //- Markup motion vertices 00098 tmp<scalarField> vertexMarkup 00099 ( 00100 const pointField& p, 00101 const scalar& curLeft, 00102 const scalar& curRight 00103 ) const; 00104 00105 00106 public: 00107 00108 //- Runtime type information 00109 TypeName("movingConeTopoFvMesh"); 00110 00111 00112 // Constructors 00113 00114 //- Construct from database 00115 explicit movingConeTopoFvMesh(const IOobject& io); 00116 00117 00118 // Destructor 00119 00120 virtual ~movingConeTopoFvMesh(); 00121 00122 00123 // Member Functions 00124 00125 //- Update the mesh for both mesh motion and topology change 00126 virtual bool update(); 00127 }; 00128 00129 00130 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00131 00132 } // End namespace Foam 00133 00134 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 00135 00136 #endif 00137 00138 // ************************************************************************* // |