]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
base elements also in FiniteElement<>
authorguido <guido@0785d39b-7218-0410-832d-ea1e28bc413d>
Thu, 4 Mar 1999 16:29:17 +0000 (16:29 +0000)
committerguido <guido@0785d39b-7218-0410-832d-ea1e28bc413d>
Thu, 4 Mar 1999 16:29:17 +0000 (16:29 +0000)
git-svn-id: https://svn.dealii.org/trunk@949 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/include/fe/fe.h
deal.II/deal.II/include/fe/fe_system.h

index 188b11f66a19dc0d461bf00a98f0100aaab5a958..bc8c05745a03291285bbcc8fef845b1ad3c89b5f 100644 (file)
@@ -98,8 +98,7 @@ class FiniteElementData
                                      * Default constructor. Constructs an element
                                      * which is not so useful. Checking
                                      * #total_dofs# is therefore a good way to
-                                     * check if something went wrong.
-                                     */
+                                     * check if something went wrong.  */
     FiniteElementData ();
 
                                     /**
@@ -732,7 +731,8 @@ class FiniteElementBase :
  * @author Wolfgang Bangerth, 1998
  */
 template <int dim>
-class FiniteElement : public FiniteElementBase<dim> {
+class FiniteElement : public FiniteElementBase<dim>
+{
   public:
                                     /**
                                      * Constructor
@@ -1316,6 +1316,25 @@ class FiniteElement : public FiniteElementBase<dim> {
                                        const Boundary<dim>           &boundary, 
                                        FullMatrix<double>            &local_mass_matrix) const =0;
 
+                                    /**
+                                     * Number of base elements in a mixed
+                                     * discretization. This function returns
+                                     * 1 for simple elements.
+                                     */
+    virtual unsigned int n_base_elements() const;
+    
+                                    /**
+                                     * Access to base element
+                                     * objects.  By default,
+                                     * #base_element(0)# is #this#.
+                                     * This function is overloaded by
+                                     * system elements to allow
+                                     * access to the different
+                                     * components of mixed
+                                     * discretizations.
+                                     */
+    virtual const FiniteElement<dim>& base_element(unsigned index) const;
+    
                                     /**
                                      * Exception
                                      */
@@ -1338,7 +1357,7 @@ class FiniteElement : public FiniteElementBase<dim> {
     DeclException1 (ExcComputationNotUseful,
                    int,
                    << "The computation you required from this function is not "
-                   << "feasable or not probable in the present dimension ("
+                   << "feasible or not probable in the present dimension ("
                    << arg1 << ") because it would be prohibitively expensive.");
 };
 
index 1dca911bb1bcd6513ec32b6d20bfd6ad89201002..19e51b3aaad5d38e12a96de5d15cb3d44157021a 100644 (file)
@@ -68,7 +68,8 @@
  * @author Wolfgang Bangerth, Guido Kanschat, 1999
  */
 template <int dim>
-class FESystem : public FiniteElement<dim>
+class FESystem //<dim>
+  : public FiniteElement<dim>
 {
                                     /**
                                      * Copy constructor prohibited.
@@ -346,7 +347,7 @@ class FESystem : public FiniteElement<dim>
                                      * of finite elements composed
                                      * into this structure.
                                      */
-    unsigned n_base_elements() const;
+    virtual unsigned n_base_elements() const;
 
                                     /**
                                      * How often is a composing element used.
@@ -369,7 +370,7 @@ class FESystem : public FiniteElement<dim>
                                      * by index.
                                      *
                                      */
-    const FiniteElement<dim>& base_element(unsigned index) const;
+    virtual const FiniteElement<dim>& base_element(unsigned index) const;
 
   private:
 

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.