Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

mesh.h

Go to the documentation of this file.
00001 /*
00002  * Copyright (c) 2001 The AUTHORS 
00003  *   Romeu Andre' Pieritz, Ph.D.        - romeu_pieritz@hotmail.com
00004  *   Rafael Mendes, Eng.                – mendes_rafael@yahoo.com
00005  *   Rodrigo Ferraz de Andrade, Eng.    – rferraz@iname.com 
00006  * All rights reserved.
00007  *
00008  * Permission to use, copy and distribute this software and its
00009  * documentation for educational and personal use, without fee is hereby granted, 
00010  * provided that the above copyright notice and the following
00011  * two paragraphs appear in all copies of this software.
00012  *
00013  * IN NO EVENT SHALL THE AUTHORS BE LIABLE TO ANY PARTY FOR
00014  * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT
00015  * OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE AUTHORS
00016  * HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00017  *
00018  * THE AUTHORS SPECIFICALLY DISCLAIMS ANY WARRANTIES,
00019  * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
00020  * AND FITNESS FOR A PARTICULAR PURPOSE.  THE SOFTWARE PROVIDED HERE UNDER IS
00021  * ON AN "AS IS" BASIS, AND THE AUTHORS HAVE NO OBLIGATION TO
00022  * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
00023  *
00024  * SINMEC Lab. - CFD Sinflow Project - http://www.sinmec.ufsc.br/cfd
00025  */
00026 
00027 
00028 // File Define
00029 #ifndef __CSFL_MATH_EQUATION_MESH_H__
00030 #define __CSFL_MATH_EQUATION_MESH_H__
00031 
00032 
00033 // Include
00034 #include <csfl/math/equation/equation.h>
00035 #include <csfl/math/equation/eqparam/fixednode.h>
00036 #include <csfl/geom/grid/mesh.h>
00037 
00038 
00039 // Namespace
00040 namespace csfl {
00041 
00042 //==============================================================================
00043 //              Class IEquationMesh
00044 //              Description: Class for Sinflow's Mesh Generation Equation
00045 //==============================================================================
00046 
00047 class IEquationMesh : 
00048                 public IEquation
00052 {       
00053 public:
00059         IEquationMesh( const IString & _name,
00060                 const ISize & _size,
00061                 IContainerBCond *_contBcond, 
00062                 IContainerParameter * _contParam,
00063                 TEquationType = etNULL );
00064                 
00070         IEquationMesh( const IString & _name,
00071                 IMesh * _mesh,
00072                 IContainerParameter * _contParam,
00073                 TEquationType = etNULL );
00074                 
00082         IEquationMesh( const IString & _name,
00083                 IDPolygon * _polygon,
00084                 const int & _ni,
00085                 const int & _nj,
00086                 IContainerParameter * _contParam,
00087                 TEquationType = etNULL );
00088 
00089 
00090         IEquationMesh( IEquationMesh * _mesh ); 
00091         ~IEquationMesh();
00092                 
00097         IMesh * Mesh() { return mesh; }   
00098 
00102         virtual void SetMesh( IMesh * _mesh);
00103 
00108         ILinearSystem9D * LinearSystem() { return lsys; }
00109     
00113         inline void  SetLinearSystem( ILinearSystem9D * _lsys ); 
00114 
00118         void SetCoefficients();
00119 
00123         void SetInitialMesh( IMesh *_mesh );
00124 
00125                 
00129         virtual void SetupFixedPoints() = 0;
00130                 
00135         void SetIsAtracted( const bool &_b ){ isatracted = _b; }
00136         
00137 
00138 protected:
00139     IMesh       *mesh;
00140         ILinearSystem9D  *lsys; 
00141         IFixedNodes *fn;
00142         bool isatracted;
00143 
00144         //virtual void SetAtraction( const int & , const int & ) = 0;
00145 
00146         virtual void SetBoundaryConditions();
00147         virtual void SetBoundaryConditions( IMesh * ) = 0 ;
00148         
00149         virtual void SetBCondNorth() = 0 ;
00150         virtual void SetBCondSouth() = 0 ;
00151         virtual void SetBCondEast() = 0 ;
00152         virtual void SetBCondWest() = 0 ;
00153   
00154 };
00155 
00156 
00157 // =============================================================================
00158 // Inline functions
00159 // =============================================================================
00160 
00161 inline void  IEquationMesh::SetLinearSystem( ILinearSystem9D * _lsys )
00162 {
00163     if (lsys) 
00164         delete lsys; 
00165     lsys = new ILinearSystem9D( _lsys ); 
00166 }
00167     
00168 } // csfl namespace
00169 
00170 #endif// __CSFL_MATH_EQUATION_MESH_H__
00171 

 

CFD Project | Documents | Downloads | Contact us | Use Terms

 

© SINMEC/EMC/UFSC, 2001.

All rights reserved.

Last Update: Jan. 18, 2002

 Webmaster