00001 //************************************************************************************// 00002 // Module : pcblockjac_helm.hpp 00003 // Date : 7/17/02 (DLR) 00004 // Copyright : 2002-2006 Copyright University Corporation for Atmospheric 00005 // Research 00006 // Description : Encapsulates the methods and data associated with 00007 // a block Jacobi preconditioner object to be used 00008 // for preconditioning the Helmholtz operator 00009 // Derived From : LinOp. 00010 // Modifications: 00011 //************************************************************************************// 00012 #if !defined(PCBLOCKJAC_HELM_HPP) 00013 #define PCBLOCKJAC_HELM_HPP 00014 #include "linop.hpp" 00015 #include "helmholtzop.hpp" 00016 #include "defquad2d.hpp" 00017 #include "rectquad2d.hpp" 00018 #include "diagop.hpp" 00019 00020 class PCBlockJac_Helm: public LinOp 00021 { 00022 public: 00023 PCBlockJac_Helm(); 00024 PCBlockJac_Helm(LinOp *A); 00025 PCBlockJac_Helm(Elem2D *e, HelmholtzOp *Hin=NULL); 00026 // PCBlockJac_Helm(const PCBlockJac_Helm &); 00027 ~PCBlockJac_Helm(); 00028 00029 GVector operator*(GVector) ; // Multiply precond by right-vector 00030 void OpVec_prod(GVector &q, GVector &ret); 00031 void SetConst(GDOUBLE clc, GDOUBLE cmc); 00032 void SetConst(GDOUBLE clc1, GDOUBLE clc2, GDOUBLE cmc); 00033 void SetElem(Elem2D *e); 00034 void SetHelm(HelmholtzOp *Hin); 00035 void SetMask(GVector *m); 00036 00037 00038 private: 00039 GBOOL DefmQuadH(); 00040 GBOOL RectQuadH(); 00041 GBOOL TriangleH(); 00042 GBOOL ComputeOp(); 00043 00044 GINT N_[GDIM];// 1, 2, 3--size 00045 GINT NN_; // 1 X 2 X 3 - size 00046 GBOOL bDeletedHere_; 00047 GDOUBLE lc1_; // Laplacian-multiplicative constant 00048 GDOUBLE lc2_; // Laplacian-multiplicative constant 00049 GDOUBLE mc_; // Mass matrix-multiplicative constant 00050 Elem2D *elem_; 00051 GVector *mask_; 00052 GVector icol_; 00053 GVector rcol_; 00054 GMatrix H_; 00055 GMatrix iH_; 00056 HelmholtzOp *Hop_; 00057 00058 00059 }; 00060 00061 #endif