Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Examples  

AffineTetReferenceCell.h

Go to the documentation of this file.
00001 #ifndef AFFINETETREFERENCECELL_H
00002 #define AFFINETETREFERENCECELL_H
00003 
00004 #include "SundanceDefs.h"
00005 
00006 #include "AffineReferenceCell.h"
00007 #include "ReferenceCell.h"
00008 #include "TetFacetSet.h"
00009 
00010 
00011 namespace Sundance
00012 {
00013 
00014   using namespace TSF;
00015   using std::string;
00016 
00017   using std::ostream;
00018 
00019   /** \ingroup LowLevelGeometry
00020    * Reference cell for affine-mapped tetrahedra.
00021    */
00022 
00023   class AffineTetReferenceCell : public AffineReferenceCell
00024     {
00025     public:
00026       /** empty ctor */
00027       AffineTetReferenceCell();
00028       /** dtor */
00029       virtual ~AffineTetReferenceCell(){;}
00030 
00031       /** typeid */
00032       virtual const string& typeName() const {return typeName_;}
00033       /** return topology code (TetCell) */
00034       virtual CellTopologyCode topologyCode() const {return TetCell;}
00035 
00036 
00037       /** return cell dimension (3) */
00038       virtual int dim() const {return 3;}
00039 
00040       /** return number of nodes (4) */
00041       virtual int numNodes() const {return 4;}
00042 
00043       /** return number of vertices (4) */
00044       virtual int numVertices() const {return 4;}
00045 
00046       /** return number of d-facets */
00047       virtual int numFacets(int d) const ;
00048 
00049       /** return the nodes for the given facet */
00050       virtual const TSFArray<TSFArray<int> >& facetNodePtrs(int facetDim) const ;
00051       /** return the reference cell used by the given facet */
00052       virtual const ReferenceCell& facetReferenceCell(int facetDim,
00053                                                       int facetNumber) const ;
00054       /** */
00055       virtual const TSFArray<TSFArray<int> >& facetFacetPtrs(int d,
00056                                                              int facetNum) const ;
00057       /** create a new facet set */
00058       virtual FacetSetBase* newFacetSet() const {return new TetFacetSet();}
00059 
00060       /** compute the jacobian for this cell */
00061       virtual void constantJacobian(const Cell& cell,
00062                                     CellJacobian& J) const ;
00063 
00064       /** compute determinant of the jacobian for this cell */
00065       virtual void constantDetJacobian(const Cell& cell,
00066                                        double& detJ) const ;
00067 
00068       /** do push-forward map (reference to physical coordinates) */
00069       virtual void pushFwd(const Cell& cell,
00070                            const TSFArray<Point>& ref,
00071                            TSFArray<Point>& phys) const ;
00072 
00073 
00074 
00075       /** compute diameter of cell */
00076       virtual double diameter(const Cell& cell) const ;
00077     private:
00078       /** */
00079       void initFacets();
00080 
00081       static string typeName_;
00082       static ReferenceCell pointFacetReferenceCell_;
00083       static ReferenceCell lineFacetReferenceCell_;
00084       static ReferenceCell triangleFacetReferenceCell_;
00085       static TSFArray<TSFArray<TSFArray<int> > > facetNodePtrs_;
00086       static TSFArray<TSFArray<TSFArray<TSFArray<int> > > > facetFacetPtrs_;
00087     };
00088 
00089 }
00090 #endif
00091 
00092 
00093 
00094 

Contact:
Kevin Long (krlong@ca.sandia.gov)


Documentation generated by