pk3d.hh
Go to the documentation of this file.00001
00002
00003 #ifndef DUNE_Pk3DLOCALFINITEELEMENT_HH
00004 #define DUNE_Pk3DLOCALFINITEELEMENT_HH
00005
00006 #include <dune/common/geometrytype.hh>
00007
00008 #include <dune/localfunctions/common/localfiniteelementtraits.hh>
00009 #include "pk3d/pk3dlocalbasis.hh"
00010 #include "pk3d/pk3dlocalcoefficients.hh"
00011 #include "pk3d/pk3dlocalinterpolation.hh"
00012
00013 namespace Dune
00014 {
00015
00018 template<class D, class R, unsigned int k>
00019 class Pk3DLocalFiniteElement
00020 {
00021 public:
00024 typedef LocalFiniteElementTraits<Pk3DLocalBasis<D,R,k>,
00025 Pk3DLocalCoefficients<k>,
00026 Pk3DLocalInterpolation<Pk3DLocalBasis<D,R,k> > > Traits;
00027
00030 Pk3DLocalFiniteElement ()
00031 {
00032 gt.makeTetrahedron();
00033 }
00034
00041 Pk3DLocalFiniteElement (const unsigned int vertexmap[4]) : coefficients(vertexmap)
00042 {
00043 gt.makeTetrahedron();
00044 }
00045
00048 const typename Traits::LocalBasisType& localBasis () const
00049 {
00050 return basis;
00051 }
00052
00055 const typename Traits::LocalCoefficientsType& localCoefficients () const
00056 {
00057 return coefficients;
00058 }
00059
00062 const typename Traits::LocalInterpolationType& localInterpolation () const
00063 {
00064 return interpolation;
00065 }
00066
00069 GeometryType type () const
00070 {
00071 return gt;
00072 }
00073
00074 Pk3DLocalFiniteElement* clone () const
00075 {
00076 return new Pk3DLocalFiniteElement(*this);
00077 }
00078
00079 private:
00080 Pk3DLocalBasis<D,R,k> basis;
00081 Pk3DLocalCoefficients<k> coefficients;
00082 Pk3DLocalInterpolation<Pk3DLocalBasis<D,R,k> > interpolation;
00083 GeometryType gt;
00084 };
00085
00086 }
00087
00088 #endif