]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Use the copy constructors to make copies of finite elements, rather than creating...
authorbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 6 Mar 2007 21:50:56 +0000 (21:50 +0000)
committerbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 6 Mar 2007 21:50:56 +0000 (21:50 +0000)
git-svn-id: https://svn.dealii.org/trunk@14540 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_dgp_nonparametric.cc
deal.II/deal.II/source/fe/fe_dgq.cc
deal.II/deal.II/source/fe/fe_nedelec.cc
deal.II/deal.II/source/fe/fe_q_hierarchical.cc
deal.II/deal.II/source/fe/fe_raviart_thomas.cc
deal.II/deal.II/source/fe/fe_raviart_thomas_nodal.cc

index ffd381a2a4639d51ff55cee0184f7882c6f2bc58..d7c119fbc36cbd9da6a2193d8c9941784805eb1a 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2002, 2003, 2004, 2005, 2006 by the deal.II authors
+//    Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -64,7 +64,7 @@ template <int dim>
 FiniteElement<dim> *
 FE_DGP<dim>::clone() const
 {
-  return new FE_DGP<dim>(this->degree);
+  return new FE_DGP<dim>(*this);
 }
 
 
index 3321f574df0cb0c43459c7234832cd7f034a9349..0a3fcd2f12471136217222154df73fa33f1164d2 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2004, 2005, 2006 by the deal.II authors
+//    Copyright (C) 2004, 2005, 2006, 2007 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -167,7 +167,7 @@ template <int dim>
 FiniteElement<dim> *
 FE_DGPMonomial<dim>::clone() const
 {
-  return new FE_DGPMonomial<dim>(this->degree);
+  return new FE_DGPMonomial<dim>(*this);
 }
 
 
index 618aea00fd1453d8600364879be3f084a89361a4..f3bc12df5305aa1429cbb1a786c8d7e81a5f6017 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2002, 2003, 2004, 2005, 2006 by the deal.II authors
+//    Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -98,7 +98,7 @@ template <int dim>
 FiniteElement<dim> *
 FE_DGPNonparametric<dim>::clone() const
 {
-  return new FE_DGPNonparametric<dim>(degree);
+  return new FE_DGPNonparametric<dim>(*this);
 }
 
 
index 47d6365c0969b96bdddc78c2b0500d2360cdd032..7ffdc580851c9ae58100922923bd581f3ac96b64 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006 by the deal.II authors
+//    Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -219,6 +219,8 @@ FE_DGQ<dim>::FE_DGQ (const Quadrature<1>& points)
   this->unit_support_points = support_quadrature.get_points();
 }
 
+
+
 template <int dim>
 std::string
 FE_DGQ<dim>::get_name () const
@@ -242,7 +244,7 @@ template <int dim>
 FiniteElement<dim> *
 FE_DGQ<dim>::clone() const
 {
-  return new FE_DGQ<dim>(this->degree);
+  return new FE_DGQ<dim>(*this);
 }
 
 
index 355942b21e5152374b3e635d11f1098146fb9bde..81f08ceeeaaf435a6c9ee6f62c68a323e0ef31ac 100644 (file)
@@ -103,7 +103,7 @@ template <int dim>
 FiniteElement<dim> *
 FE_Nedelec<dim>::clone() const
 {
-  return new FE_Nedelec<dim>(degree);
+  return new FE_Nedelec<dim>(*this);
 }
 
 
index 0ebed3355eba384c4fb96762ff4b0f73819422c5..7a4810a9d96ae85d7e52dbbf31b558666627d517 100644 (file)
@@ -116,7 +116,7 @@ template <int dim>
 FiniteElement<dim> *
 FE_Q_Hierarchical<dim>::clone() const
 {
-  return new FE_Q_Hierarchical<dim>(this->degree);
+  return new FE_Q_Hierarchical<dim>(*this);
 }
 
 
index 7b89c2ac5d9598b80cf2b703405f6f1a9b77be17..5dba3929a835839de20c7c463f872a72c11b4706 100644 (file)
@@ -119,7 +119,7 @@ template <int dim>
 FiniteElement<dim> *
 FE_RaviartThomas<dim>::clone() const
 {
-  return new FE_RaviartThomas<dim>(rt_order);
+  return new FE_RaviartThomas<dim>(*this);
 }
 
 
index 084ae9b768c58bd0b3dc6aaeeaf6cbf3b7f52964..6d3c488574da743c50f4866f57fa9255cb99e0fa 100644 (file)
@@ -118,7 +118,7 @@ template <int dim>
 FiniteElement<dim> *
 FE_RaviartThomasNodal<dim>::clone() const
 {
-  return new FE_RaviartThomasNodal<dim>(this->degree-1);
+  return new FE_RaviartThomasNodal<dim>(*this);
 }
 
 

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.