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

DOFMapBase.h

Go to the documentation of this file.
00001 #ifndef DOFMAPBASE_H
00002 #define DOFMAPBASE_H
00003 
00004 #include "SundanceDefs.h"
00005 
00006 #include "TSFArray.h"
00007 #include "TSFNonDupArray.h"
00008 #include "Cell.h"
00009 #include "BasisFamily.h"
00010 #include "Mesh.h"
00011 #include "CellSet.h"
00012 #include "TSFTimeMonitor.h"
00013 
00014 
00015 
00016 namespace Sundance
00017 {
00018 
00019   using namespace TSF;
00020   using std::string;
00021 
00022   using std::ostream;
00023 
00024   /** \ingroup LowLevelFE
00025    * Map from (cell, function) to global DOF index
00026    */
00027 
00028   class DOFMapBase
00029     {
00030     public:
00031       /** */
00032       DOFMapBase();
00033       /** */
00034       virtual ~DOFMapBase() {;}
00035 
00036       /** */
00037       virtual const TSFArray<int>& lookup(int cellDim, int cellIndex,
00038                                           int funcID) const = 0 ;
00039       /** */
00040       virtual int guaranteedPointLookup(int cellIndex, int funcID) const = 0 ;
00041 
00042       /** */
00043       virtual void guaranteedLookup(int cellDim, int cellIndex,
00044                                     int funcID, const BasisFamily& basis,
00045                                     TSFArray<int>& indices) const ;
00046 
00047       /** */
00048       int numberOfGlobalDOFs() const {return nGlobalDOFs_;}
00049       /** */
00050       int numberOfLocalDOFs() const {return nLocalDOFs_;}
00051       /** */
00052       int numberOfRemoteDOFs() const {return nRemoteDOFs_;}
00053       /** */
00054       int highestLocalDOF() const {return highestLocalDOF_;}
00055       /** */
00056       int lowestLocalDOF() const {return lowestLocalDOF_;}
00057 
00058       /** */
00059       const TSFSmartPtr<TSFArray<int> >& remoteDOFList() const {return remoteDOFList_;}
00060       /** */
00061       const TSFSmartPtr<TSFArray<int> >& updateList() const {return updateList_;}
00062 
00063       /** */
00064       const Mesh& mesh() const {return mesh_;}
00065 
00066       /** */
00067       virtual void getCellTypes(TSFNonDupArray<CellTopologyCode>& cellTypes) const = 0 ;
00068 
00069       /** */
00070       virtual void print() const = 0 ;
00071 
00072       virtual int maxCellDimension() const = 0 ;
00073 
00074 
00075     protected:
00076 
00077       int nLocalDOFs_;
00078       int nRemoteDOFs_;
00079       int nGlobalDOFs_;
00080       int lowestLocalDOF_;
00081       int highestLocalDOF_;
00082 
00083       Mesh mesh_;
00084 
00085       TSFSmartPtr<TSFArray<int> > remoteDOFList_;
00086       TSFSmartPtr<TSFArray<int> > updateList_;
00087     };
00088 
00089 
00090 }
00091 
00092 namespace TSF
00093 {
00094   inline string toString(const Sundance::DOFMapBase& map)
00095     {
00096       return "DOFMap";
00097     }
00098 }
00099 #endif

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


Documentation generated by