SundanceSurfQuadrature.hpp
Go to the documentation of this file.
00001 /* @HEADER@ */
00002 // ************************************************************************
00003 //
00004 //                              Sundance
00005 //                 Copyright (2005) Sandia Corporation
00006 //
00007 // Copyright (year first published) Sandia Corporation.  Under the terms
00008 // of Contract DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government
00009 // retains certain rights in this software.
00010 //
00011 // This library is free software; you can redistribute it and/or modify
00012 // it under the terms of the GNU Lesser General Public License as
00013 // published by the Free Software Foundation; either version 2.1 of the
00014 // License, or (at your option) any later version.
00015 //
00016 // This library is distributed in the hope that it will be useful, but
00017 // WITHOUT ANY WARRANTY; without even the implied warranty of
00018 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00019 // Lesser General Public License for more details.
00020 //
00021 // You should have received a copy of the GNU Lesser General Public
00022 // License along with this library; if not, write to the Free Software
00023 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
00024 // USA
00025 // Questions? Contact Kevin Long (krlong@sandia.gov),
00026 // Sandia National Laboratories, Livermore, California, USA
00027 //
00028 // ************************************************************************
00029 /* @HEADER@ */
00030 /*
00031  * SundanceSurfQuadrature.hpp
00032  *
00033  *  Created on: Oct 24, 2011
00034  *      Author: benk
00035  */
00036 
00037 #ifndef SUNDANCE_SURFQUADRATURE_H
00038 #define SUNDANCE_SURFQUADRATURE_H
00039 
00040 #include "SundanceDefs.hpp"
00041 #include "Teuchos_RefCountPtr.hpp"
00042 #include "SundanceQuadratureFamilyBase.hpp"
00043 #include "SundanceQuadratureFamily.hpp"
00044 
00045 namespace Sundance
00046 {
00047 using namespace Teuchos;
00048 
00049 
00050 /**
00051  * The surface integral class. The surface integral is build from triangles.
00052  * The maximum number of triangles is 4. <br>
00053  * IMPORTANT: this quadrature class should only be used for Surface Integrals in 3D with Brick cells
00054  */
00055 class SurfQuadrature : public QuadratureFamilyBase
00056 {
00057 public:
00058   /** */
00059   SurfQuadrature( const QuadratureFamily& quad );
00060 
00061   /** */
00062   virtual ~SurfQuadrature(){;}
00063 
00064 
00065   /** */
00066   virtual XMLObject toXML() const ;
00067 
00068   /** Describable interface */
00069   virtual std::string description() const
00070     {return "SurfQuadrature[order=" + Teuchos::toString(order())
00071         +  "]";}
00072 
00073   /* handleable boilerplate */
00074   GET_RCP(QuadratureFamilyStub);
00075 
00076   /** return the maximal number of line segments inside one cell */
00077   static int getNrMaxTrianglePerCell() { return 4; }
00078 
00079 protected:
00080 
00081   /** for surface integral integrals only this method should be used */
00082   virtual void getQuadRule(Array<Point>& quadPoints,
00083     Array<double>& quadWeights) const ;
00084 
00085 
00086   /** for surface integral integrals only this method should be used */
00087   virtual void getTriangleRule(Array<Point>& quadPoints,
00088     Array<double>& quadWeights) const ;
00089 
00090 private:
00091 
00092   /** The quadrature which will be used for the surface integration */
00093   const QuadratureFamily& quad_;
00094 
00095 };
00096 }
00097 
00098 
00099 #endif

Site Contact