]> https://gitweb.dealii.org/ - dealii.git/commitdiff
compute additional restriction matrices
authorGuido Kanschat <dr.guido.kanschat@gmail.com>
Mon, 18 Jul 2005 16:16:41 +0000 (16:16 +0000)
committerGuido Kanschat <dr.guido.kanschat@gmail.com>
Mon, 18 Jul 2005 16:16:41 +0000 (16:16 +0000)
git-svn-id: https://svn.dealii.org/trunk@11160 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/source/fe/fe_dgp.cc
deal.II/deal.II/source/fe/fe_dgp_monomial.cc
deal.II/deal.II/source/fe/fe_dgq.cc

index 70d5ec43563000f1987ec7fb9ba04b055bf56569..4f90ec8920c9f3cc28ff52503d9277e46d3f473b 100644 (file)
@@ -35,20 +35,11 @@ FE_DGP<dim>::FE_DGP (const unsigned int degree)
     this->prolongation[i].reinit (this->dofs_per_cell,
                                  this->dofs_per_cell);
   FETools::compute_embedding_matrices (*this, &this->prolongation[0]);
-
-                                   // restriction can be defined
-                                   // through projection for
-                                   // discontinuous elements, but is
-                                   // presently not implemented for DGP
-                                   // elements.
-
-//TODO: Do the restriction  
-                                   // if it were, then the following
-                                   // snippet would be the right code
-                                   // note further, that these
-                                   // elements have neither support
-                                   // nor face-support points, so
-                                   // leave these fields empty
+                                  // Fill restriction matrices with L2-projection
+  for (unsigned int i=0; i<GeometryInfo<dim>::children_per_cell; ++i)
+    this->restriction[i].reinit (this->dofs_per_cell,
+                                 this->dofs_per_cell);
+  FETools::compute_projection_matrices (*this, &this->restriction[0]);
 }
 
 
index d5ed0b1ff7cec1b4888a8e8981dfd42510098326..32f0ea11c14b798ff3dc3454303f1692a686af60 100644 (file)
@@ -130,12 +130,11 @@ FE_DGPMonomial<dim>::FE_DGPMonomial (const unsigned int degree)
     this->prolongation[i].reinit (this->dofs_per_cell,
                                  this->dofs_per_cell);
   FETools::compute_embedding_matrices (*this, &this->prolongation[0]);
-//  initialize_restriction ();
-
-                                   // note, that these elements have
-                                   // neither support nor face-support
-                                   // points, so leave these fields
-                                   // empty
+                                  // Fill restriction matrices with L2-projection
+  for (unsigned int i=0; i<GeometryInfo<dim>::children_per_cell; ++i)
+    this->restriction[i].reinit (this->dofs_per_cell,
+                                 this->dofs_per_cell);
+  FETools::compute_projection_matrices (*this, &this->restriction[0]);
 }
 
 
@@ -176,6 +175,7 @@ FE_DGPMonomial<dim>::clone() const
 
 
 
+//TODO: Remove this function and use the one in FETools, if needed
 template <int dim>
 void
 FE_DGPMonomial<dim>::
index aa398c3398ffdf4e3bb1ed8ede8368547a113005..81dfb6658a6ba0fef5557f7a4fea707f2fe024d9 100644 (file)
@@ -214,6 +214,11 @@ FE_DGQ<dim>::FE_DGQ (const Quadrature<1>& points)
     this->prolongation[i].reinit (this->dofs_per_cell,
                                  this->dofs_per_cell);
   FETools::compute_embedding_matrices (*this, &this->prolongation[0]);
+                                  // Fill restriction matrices with L2-projection
+  for (unsigned int i=0; i<GeometryInfo<dim>::children_per_cell; ++i)
+    this->restriction[i].reinit (this->dofs_per_cell,
+                                 this->dofs_per_cell);
+  FETools::compute_projection_matrices (*this, &this->restriction[0]);
   
                                   // Compute support points, whivh
                                   // are the tensor product of the

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.