00001 #ifndef _MY_LaxFriedrichsMethodMPI_ 00002 #define _MY_LaxFriedrichsMethodMPI_ 00003 #include "laxfriedrichsmethod.h" 00004 #include "netmpi.h" 00005 00006 00007 00008 00009 00025 class LaxFriedrichsMethodMPI : public LaxFriedrichsMethod 00026 { 00027 private: 00028 VecIndex cLDeadZoneRcvMap; 00029 VecDouble cLDeadZoneRcv; 00030 VecIndex cLDeadZoneSndMap; 00031 VecDouble cLDeadZoneSnd; 00032 VecIndex LGhostCellRcvMap; 00033 VecDouble LGhostCellRcv; 00034 VecIndex LGhostCellSndMap; 00035 VecDouble LGhostCellSnd; 00036 00037 VecIndex cRDeadZoneRcvMap; 00038 VecDouble cRDeadZoneRcv; 00039 VecIndex cRDeadZoneSndMap; 00040 VecDouble cRDeadZoneSnd; 00041 VecIndex RGhostCellRcvMap; 00042 VecDouble RGhostCellRcv; 00043 VecIndex RGhostCellSndMap; 00044 VecDouble RGhostCellSnd; 00045 int mesh_overlap; 00046 protected: 00047 VecTag fDeadZone; 00048 void setCommunicationBuffers(OrthoMesh &mesh,int mesh_overlap); 00049 void setCommunicationBuffersWithNoOverlap(OrthoMesh &mesh); 00050 enum FACES_ZONE {ACTIVE_ZONE=0,LEFT_DEAD_ZONE=1,RIGHT_DEAD_ZONE=2}; 00051 00052 00053 public: 00054 LaxFriedrichsMethodMPI(OrthoMesh &mesh,Function3D &fInitU,const VecDouble &cPor,Function3D &fPrescribedU,FaceFluxFunction &flux, double CFL,int mesh_overlap); 00055 virtual ~LaxFriedrichsMethodMPI(); 00056 virtual void iterate(double t, double tEnd); 00057 void updateGhostCells(); 00058 void updateDeadZone(); 00059 void unitTest(); 00060 double negotiateTimeStep(double dt); 00061 }; 00062 00063 #endif