Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

defquad2d.hpp

Go to the documentation of this file.
00001 //************************************************************************************//
00002 // Module       : defquad2d.hpp
00003 // Date         : 9/14/01 (DLR)
00004 // Copyright    : 2001-2006 Copyright University Corporation for Atmospheric
00005 //                Research
00006 // Description  : Encapsulates the methods and data associated with
00007 //                a single deformed quadrilateral Cartesian 2D spectral 
00008 //                element comprised only of straight-line segments.
00009 //                The following is the ordering for the vertices (Vi)
00010 //                and segment midpoints (Mi):
00011 //
00012 //          V7 ________________ V6
00013 //            /|     M6       /|
00014 //       M7  / |             / |
00015 //          /  |        M5  /  |
00016 //         /M11|  M4       /   |
00017 //     V4 /____|___ ______/    | M10
00018 //        |    |         | V5  |
00019 //        |    |     M2  |     |
00020 //        | V3 |_________|_____| V2
00021 //    M8  |    /         |    /
00022 //        |   /       M9 |   /
00023 //        |  / M3        |  / M1
00024 //        | /            | /
00025 //        |______________|/
00026 //       V0       M0     V1
00027 //
00028 // [Note that in 2d, we use just the bottom plane.]
00029 
00030 // Derived From : none.
00031 // Modifications:
00032 //************************************************************************************//
00033 #if !defined(DEFQUAD2D_HPP)
00034 #define DEFQUAD2D_HPP
00035 #include "elem2d.hpp"
00036 
00037 class DefQuad2D : public Elem2D
00038 {
00039 public:
00040                  DefQuad2D(GSHORT ntmp=2);
00041                  DefQuad2D(GINT  n1, GINT  n2, GSHORT ntmp=2 );
00042                  DefQuad2D(GNBasis *b1, GNBasis *b2, GSHORT ntmp=2 );
00043                  ~DefQuad2D();
00044 void             operator=(const DefQuad2D &);
00045                    
00046 //GINT             GetOrder(const GINT  idir);
00047 GDOUBLE            Integrate(GVector *v, GDOUBLE *multiplicity=NULL);
00048 GDOUBLE            PIntegrate(GVector *v, GDOUBLE *multiplicity=NULL);
00049 GBOOL            Differentiate(GVector *dv, GVector *v, GINT  idir);
00050 GBOOL            DifferentiateWithMass(GVector *dv, GVector *v, GVector* tmp, GINT  idir);
00051 GBOOL            DifferentiateWeak(GVector *dv, GVector *v,GVector* tmp, GINT  idir);
00052 GBOOL            Assemble();
00053 GNBasis         *GetBasisObj(GINT  idir);
00054 GVector         *GetXiNodes(GINT  idir); 
00055 GVector         *Get1DWeights(GINT  idir);
00056 GMatrix         *Get1DDerivMatrix(GINT  idir, GBOOL bTranspose);  
00057 GMatrix         *Get1DStiffMatrix(GINT  idir, GBOOL bTranspose);             
00058 GMatrix         *Get1DDerivMatrixWithMass(GINT  idir, GBOOL bTranspose);  
00059 GMatrix         *Get1DDerivMatrixWeak(GINT  idir, GBOOL bTranspose);  
00060 GVector         *Get2DWeights();                              
00061 GVector         *GetJacobian();                              
00062 GVector         *GetMassMatrix();                           
00063 GVector         *GetiMass();                           
00064 GVector         *GetgMass();                           
00065 #if 0
00066 GDOUBLE           &TensorD1(GINT  i, GINT  j);                           
00067 GDOUBLE           &TensorD2(GINT  i, GINT  j);                           
00068 #endif
00069 GVector         *GetSpNodes(GINT  idir);                  
00070 GVector         *GetdXidX(GVector **, GINT  );          
00071 GVector         *GetdXidX   (const GINT  i, const GINT  j ); 
00072 GVector         *GetMetric  (const GINT  i, const GINT  j ); 
00073 GVector         *GetWJMetric(const GINT  i, const GINT  j ); 
00074 GMatrix         *GetInterpOp(GINT  idir, GBOOL Transpose);
00075 GMatrix         *GetInterpDeriv(GINT  idir, GBOOL Transpose);
00076 
00077 
00078 GBOOL             XToXi(Point3D pX[], Point3D pXi[], const GINT  n);
00079 //GMatrix        *GetBasisAtXi(GINT  i, GINT  j, GMatrix *B); 
00080 
00081 
00082 GBOOL             ComputeSpNodes();
00083 GBOOL             ComputeLaplacian();
00084 GBOOL             SetVertices(Point3D P[], GINT  num);
00085 //void              SetBasis(GNBasis *b1, GNBasis *b2);
00086 //void              SetBasis(GNBasis *b, GINT  idir);
00087 //void              SetOrder(GINT  iorder1, GINT  iorder2);
00088 void              SetInterpBasis(GNBasis *b1, GNBasis *b2);
00089 GBOOL             Resize(GINT  order1, GINT  order2);
00090 GINT              SolveFE();
00091 
00092 
00093 protected:
00094 
00095 GDOUBLE          fRet;
00096 GVector        *xiNodes1;
00097 GVector        *xiNodes2;
00098 GVector        *Weights1;
00099 GVector        *Weights2;
00100 GVector        *Weights2D;
00101 GVector        *MassMatrix;
00102 GVector        *gMassMatrix;
00103 GVector        *iMassMatrix;
00104 GMatrix        *StiffMat1;
00105 GMatrix        *StiffMat2;
00106 GMatrix        *StiffMat1T;
00107 GMatrix        *StiffMat2T;
00108 GMatrix        *D1;
00109 GMatrix        *D2;
00110 GMatrix        *D1T;
00111 GMatrix        *D2T;
00112 GMatrix        *opInterp1;
00113 GMatrix        *opInterp2;
00114 GMatrix        *opInterpT1;
00115 GMatrix        *opInterpT2;
00116 GMatrix        *dInterp1;
00117 GMatrix        *dInterp2;
00118 GMatrix        *dInterpT1;
00119 GMatrix        *dInterpT2;
00120 GVector        *Jac;
00121 GVector        *d11;
00122 GVector        *d12;
00123 GVector        *d21;
00124 GVector        *d22;
00125 GVector        *g11;
00126 GVector        *g12;
00127 GVector        *g22;
00128 GVector        *gWJ11;
00129 GVector        *gWJ12;
00130 GVector        *gWJ22;
00131 GDOUBLE          *xi1p;
00132 GDOUBLE          *xi1m;
00133 GDOUBLE          *xi2p;
00134 GDOUBLE          *xi2m;
00135 
00136 private:
00137 
00138 // Private methods:
00139 GBOOL             Initialize(GINT  order1, GINT  order2);
00140 void              DeleteDynamic();
00141 GBOOL             ComputeGeo();
00142 
00143 // Private data:
00144 
00145 
00146 };
00147 
00148 
00149 #endif

Generated on Wed Dec 21 16:00:48 2005 for Geophysics & Astrophysics Spectral Element Adaptive Refinement (GASpAR) 2D Code by  doxygen 1.4.4