00001 #ifndef DUNE_RAVIARTTHOMAS02DLOCALFINITEELEMENT_HH 00002 #define DUNE_RAVIARTTHOMAS02DLOCALFINITEELEMENT_HH 00003 00004 #include <dune/common/geometrytype.hh> 00005 00006 #include <dune/localfunctions/common/localfiniteelementtraits.hh> 00007 #include "raviartthomas02d/raviartthomas02dlocalbasis.hh" 00008 #include "raviartthomas02d/raviartthomas02dlocalcoefficients.hh" 00009 #include "raviartthomas02d/raviartthomas02dlocalinterpolation.hh" 00010 00011 namespace Dune 00012 { 00013 00014 template<class D, class R> 00015 class RT02DLocalFiniteElement 00016 { 00017 public: 00018 typedef LocalFiniteElementTraits<RT02DLocalBasis<D,R>,RT02DLocalCoefficients, 00019 RT02DLocalInterpolation<RT02DLocalBasis<D,R> > > Traits; 00020 00021 RT02DLocalFiniteElement () 00022 { 00023 gt.makeTriangle(); 00024 } 00025 00026 RT02DLocalFiniteElement (int s) : basis(s), interpolation(s) 00027 { 00028 gt.makeTriangle(); 00029 } 00030 00031 const typename Traits::LocalBasisType& localBasis () const 00032 { 00033 return basis; 00034 } 00035 00036 const typename Traits::LocalCoefficientsType& localCoefficients () const 00037 { 00038 return coefficients; 00039 } 00040 00041 const typename Traits::LocalInterpolationType& localInterpolation () const 00042 { 00043 return interpolation; 00044 } 00045 00046 GeometryType type () const 00047 { 00048 return gt; 00049 } 00050 00051 private: 00052 RT02DLocalBasis<D,R> basis; 00053 RT02DLocalCoefficients coefficients; 00054 RT02DLocalInterpolation<RT02DLocalBasis<D,R> > interpolation; 00055 GeometryType gt; 00056 }; 00057 00058 } 00059 00060 #endif