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

app-cwinkelm/dgNorm2d.hh
Go to the documentation of this file.
00001 #ifndef dgNorm2d_hh
00002 #define dgNorm2d_hh
00003 
00004 #include "basics/typedefs.hh"
00005 #include "basics/vectorsMatrices.hh"
00006 #include "operator/compositions.hh"
00007 #include "function/vector.hh"
00008 #include "vectorial/vectorial.hh"
00009 #include "linDG2D/space.hh"
00010 
00011 using concepts::Real;
00012 
00013 namespace concepts {
00014   template<typename F>
00015   class Formula;
00016 }
00017 
00018 namespace vectorial {
00019   template<typename F>
00020   class Element;
00021 }
00022 
00023 // **************************************************************** DGNorm2d **
00024 
00028 class DGNorm2d
00029 {
00030  public:
00035   static Real matrix(const concepts::Vector<Real>& coeffs,
00036                      concepts::Operator<Real>& matrix) {
00037     concepts::Vector<Real> temp(coeffs);
00038     matrix(coeffs, temp);
00039     return std::sqrt(coeffs*temp);    
00040   }
00049   static Real l2(const linDG2D::SpaceP1& spc,
00050                  const concepts::Vector<Real>& coeffs,
00051                  concepts::Formula<Real>& exactFrm, uint nQuadPts,
00052                  Real time = 0);
00067   static Real energyTW(vectorial::Space<Real>& spc,
00068                        const concepts::Vector<Real>& coeffs,
00069                        concepts::Formula<Real>& exactFrmX,
00070                        concepts::Formula<Real>& exactFrmY,
00071                        concepts::Formula<Real>& exactFrmXderX,
00072                        concepts::Formula<Real>& exactFrmXderY,
00073                        concepts::Formula<Real>& exactFrmYderX,
00074                        concepts::Formula<Real>& exactFrmYderY,
00075                        uint nQuadPts, Real time = 0);
00085   static Real l2(vectorial::Space<Real>& spc,
00086                  const concepts::Vector<Real>& coeffs,
00087                  concepts::Formula<Real>& exactFrmX,
00088                  concepts::Formula<Real>& exactFrmY,
00089                  uint nQuadPts, Real time = 0);
00090   // Calculate symmetric gradient of solution on vectorial element
00091   static concepts::Mapping<Real, 2> elmSymmGrad
00092   (vectorial::Element<Real>& vElm, const concepts::Vector<Real>& coeffs);
00093   private:
00095   DGNorm2d() {};
00097   static concepts::Real2d elmSol(vectorial::Element<Real>& vElm,
00098                                  const concepts::Vector<Real>& coeffs,
00099                                  Real xi1, Real xi2);
00101   template <uint dim>
00102   static Real mappingNorm(concepts::Mapping<Real, dim>& map);
00103 };
00104 
00105 #endif // dgNorm2d_hh

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