OpenFOAM logo
Open Source CFD Toolkit

movingConeTopoFvMesh.H

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