gascoignemultigridmesh.h

Go to the documentation of this file.
00001 #ifndef  __GascoigneMultiGridMesh_h
00002 #define  __GascoigneMultiGridMesh_h
00003 
00004 #include  <vector>
00005 #include  "gascoignemesh.h"
00006 #include  "gascoignemeshtransfer.h"
00007 
00008 /*-----------------------------------------*/
00009 
00010 namespace Gascoigne
00011 {
00012 class GascoigneMultiGridMesh
00013 {
00014 protected:
00015 
00016   std::vector<GascoigneMesh*>          M;
00017   std::vector<GascoigneMeshTransfer*>  T;
00018 
00019   virtual GascoigneMesh* NewMesh(int dim);
00020   virtual GascoigneMeshTransfer* NewTransfer(int dim);
00021 
00022 public:
00023   
00024   virtual void ReInit(int dim, int nlevels);
00025 
00026   GascoigneMultiGridMesh();
00027   virtual ~GascoigneMultiGridMesh();
00028 
00029   int nlevels() const {return M.size();}
00030 
00031   const MeshInterface& operator()(int l) const {
00032     assert((l>=0)&&(l<M.size()));
00033     return *M[l];}
00034 
00035   const GascoigneMesh* GetGascoigneMesh(int l) const {
00036     assert((l>=0)&&(l<M.size()));
00037     return M[l];}
00038   GascoigneMesh*       GetGascoigneMesh(int l) {
00039     assert((l>=0)&&(l<M.size()));
00040     return M[l];}
00041 
00042   GascoigneMeshTransfer* GetTransfer(int l) {
00043     assert((l>=0)&&(l<T.size()));
00044     return T[l];}
00045   const GascoigneMeshTransfer* GetTransfer(int l) const {
00046     assert((l>=0)&&(l<T.size()));
00047     return T[l];}
00048 };
00049 }
00050 
00051 #endif

Generated on Thu Sep 14 10:34:37 2006 for Gascoigne by  doxygen 1.4.7