Home | Doxygen Documentation | Tutorials | Developer Tools (restricted)

linearFEM/linearForm2D.hh
Go to the documentation of this file.
00001 // linear form for 2D linear FEM (quads and triangles)
00002 
00003 #ifndef linearForm2D_hh
00004 #define linearForm2D_hh
00005 
00006 #include "basics/typedefs.hh"
00007 #include "basics/vectorsMatrices.hh"
00008 #include "toolbox/array.hh"
00009 #include "formula/formula.hh"
00010 #include "function/linearForm.hh"
00011 
00012 namespace linearFEM {
00013 
00014   using concepts::Real;
00015 
00016   class Quad;
00017   class Triangle;
00018 
00019   // *************************************************************** Riesz2d **
00020 
00026   class Riesz2d : public concepts::LinearForm<Real> {
00027   public:
00031     Riesz2d(const concepts::Formula<Real>& frm) :
00032       frm_(frm.clone()), shpfct_(0) {}
00033     virtual void operator()(const concepts::Element<Real>& elm,
00034           concepts::ElementMatrix<Real>& em);
00036     void operator()(const linearFEM::Quad& elm,
00037         concepts::ElementMatrix<Real>& em);
00039     void operator()(const linearFEM::Triangle& elm,
00040         concepts::ElementMatrix<Real>& em);
00041   private:
00043     std::auto_ptr<const concepts::Formula<Real> > frm_;
00044     concepts::Array<concepts::Real> shpfct_;
00046     static const Real weights_[4];
00048     static const concepts::Real2d coord_[4];
00049   };
00050 
00051 } // namespace linearFEM
00052 
00053 #endif // linearForm2D_hh
00054 

Home | Doxygen Documentation | Tutorials | Developer Tools (restricted)