]> https://gitweb.dealii.org/ - dealii.git/commitdiff
interpolation tested for FE_Q, FE_DGQ, FESystem
authorGuido Kanschat <dr.guido.kanschat@gmail.com>
Sat, 17 Sep 2005 09:19:19 +0000 (09:19 +0000)
committerGuido Kanschat <dr.guido.kanschat@gmail.com>
Sat, 17 Sep 2005 09:19:19 +0000 (09:19 +0000)
git-svn-id: https://svn.dealii.org/trunk@11473 0785d39b-7218-0410-832d-ea1e28bc413d

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

index 7501ada21a46cb31e888ec9e77fe72a42e432b36..817f1f9178b860178ee58296f6b81ae854738577 100644 (file)
@@ -1128,12 +1128,6 @@ class FiniteElement : public Subscriptor,
                                      * just the values in the suport
                                      * points. All other elements
                                      * must reimplement it.
-                                     *
-                                     * @warning This function will
-                                     * only be available in future
-                                     * versions. Right now, is
-                                     * implemented for a few elements
-                                     * and not tested.
                                      */
     virtual void interpolate(std::vector<double>&       local_dofs,
                             const std::vector<double>& values) const;
@@ -1151,12 +1145,6 @@ class FiniteElement : public Subscriptor,
                                      * interpolated. Maybe consider
                                      * changing your data structures
                                      * to use the next function.
-                                     *
-                                     * @warning This function will
-                                     * only be available in future
-                                     * versions. Right now, is
-                                     * implemented for a few elements
-                                     * and not tested.
                                      */
     virtual void interpolate(std::vector<double>&                local_dofs,
                             const std::vector<Vector<double> >& values,
@@ -1166,12 +1154,6 @@ class FiniteElement : public Subscriptor,
                                      * Interpolate a set of vector
                                      * values, computed in the
                                      * generalized support points.
-                                     *
-                                     * @warning This function will
-                                     * only be available in future
-                                     * versions. Right now, is
-                                     * implemented for a few elements
-                                     * and not tested.
                                      */
     virtual void interpolate(
       std::vector<double>& local_dofs,
index 81eaf2ff584dfd7c41d9dc324790c23cf16ef195..e67accdf77c151d6c386c279c9f70602f46e8fd0 100644 (file)
@@ -574,10 +574,8 @@ FiniteElement<dim>::interpolate(
          ExcDimensionMismatch(local_dofs.size(),this->dofs_per_cell));
   Assert (this->n_components() == 1,
          ExcDimensionMismatch(this->n_components(), 1));
-
-  Assert(false, ExcNotImplemented());
   
-//  std::fill(values.begin(), values.end(), local_dofs.begin());
+  std::copy(values.begin(), values.end(), local_dofs.begin());
 }
 
 
@@ -602,7 +600,7 @@ FiniteElement<dim>::interpolate(
     {
       const std::pair<unsigned int, unsigned int> index
        = this->system_to_component_index(i);
-      local_dofs[i] = values[index.second](offset+index.first);
+      local_dofs[i] = values[i](offset+index.first);
     }
 }
 
@@ -627,7 +625,7 @@ FiniteElement<dim>::interpolate(
     {
       const std::pair<unsigned int, unsigned int> index
        = this->system_to_component_index(i);
-      local_dofs[i] = values[index.first][index.second];
+      local_dofs[i] = values[index.first][i];
     }
 }
 

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.