]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Export dimension and integral_dimension to make the life of some hp code
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Wed, 22 Feb 2006 06:41:51 +0000 (06:41 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Wed, 22 Feb 2006 06:41:51 +0000 (06:41 +0000)
easier (requires less template arguments)

git-svn-id: https://svn.dealii.org/trunk@12454 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/include/fe/fe_values.h
deal.II/deal.II/source/fe/fe_values.cc

index e4326a91e23c28db2221ea204ab936300a0f4d5a..8205671d63c5a89b6a1a275886a25cf343f41f23 100644 (file)
@@ -356,7 +356,8 @@ class FEValuesData
  * @author Wolfgang Bangerth, 1998, 2003, Guido Kanschat, 2001
  */
 template <int dim>
-class FEValuesBase : protected FEValuesData<dim>, public Subscriptor
+class FEValuesBase : protected FEValuesData<dim>,
+                     public Subscriptor
 {
   public:
                                     /**
@@ -1628,6 +1629,20 @@ template <int dim>
 class FEValues : public FEValuesBase<dim>
 {
   public:
+                                     /**
+                                      * Dimension in which this object
+                                      * operates.
+                                      */
+    static const unsigned int dimension = dim;
+
+                                     /**
+                                      * Dimension of the object over
+                                      * which we integrate. For the
+                                      * present class, this is equal
+                                      * to <code>dim</code>.
+                                      */
+    static const unsigned int integral_dimension = dim;
+    
                                     /**
                                      * Constructor. Gets cell
                                      * independent data from mapping
@@ -1921,7 +1936,21 @@ template <int dim>
 class FEFaceValues : public FEFaceValuesBase<dim>
 {
   public:
-                                    /**
+                                     /**
+                                      * Dimension in which this object
+                                      * operates.
+                                      */
+    static const unsigned int dimension = dim;
+
+                                     /**
+                                      * Dimension of the object over
+                                      * which we integrate. For the
+                                      * present class, this is equal
+                                      * to <code>dim-1</code>.
+                                      */
+    static const unsigned int integral_dimension = dim-1;
+
+                                    /**
                                      * Constructor. Gets cell
                                      * independent data from mapping
                                      * and finite element objects,
@@ -2080,6 +2109,20 @@ template <int dim>
 class FESubfaceValues : public FEFaceValuesBase<dim>
 {
   public:
+                                     /**
+                                      * Dimension in which this object
+                                      * operates.
+                                      */
+    static const unsigned int dimension = dim;
+
+                                     /**
+                                      * Dimension of the object over
+                                      * which we integrate. For the
+                                      * present class, this is equal
+                                      * to <code>dim-1</code>.
+                                      */
+    static const unsigned int integral_dimension = dim-1;
+
                                     /**
                                      * Constructor. Gets cell
                                      * independent data from mapping
index 76700988cd08aa4d5d57ab7d168cdb1d628ad117..39a09ab5b4765ad76273308fef0e5302ff17c2a4 100644 (file)
@@ -1050,6 +1050,13 @@ FEValuesBase<dim>::compute_update_flags (const UpdateFlags update_flags) const
 /*------------------------------- FEValues -------------------------------*/
 
 
+template <int dim>
+const unsigned int FEValues<dim>::dimension;
+
+template <int dim>
+const unsigned int FEValues<dim>::integral_dimension;
+
+
 
 template <int dim>
 FEValues<dim>::FEValues (const Mapping<dim>       &mapping,
@@ -1315,6 +1322,12 @@ FEFaceValuesBase<dim>::memory_consumption () const
 
 /*------------------------------- FEFaceValues -------------------------------*/
 
+template <int dim>
+const unsigned int FEFaceValues<dim>::dimension;
+
+template <int dim>
+const unsigned int FEFaceValues<dim>::integral_dimension;
+
 
 template <int dim>
 FEFaceValues<dim>::FEFaceValues (const Mapping<dim>       &mapping,
@@ -1524,6 +1537,14 @@ void FEFaceValues<dim>::do_reinit (const unsigned int face_no)
 /*------------------------------- FESubFaceValues -------------------------------*/
 
 
+template <int dim>
+const unsigned int FESubfaceValues<dim>::dimension;
+
+template <int dim>
+const unsigned int FESubfaceValues<dim>::integral_dimension;
+
+
+
 template <int dim>
 FESubfaceValues<dim>::FESubfaceValues (const Mapping<dim>       &mapping,
                                       const FiniteElement<dim> &fe,

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.