]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Patch by Lukas Korous: Make namespace DerivativeApproximation work with MS Visual...
authorLukas Korous <lukas.korous@gmail.com>
Wed, 3 Dec 2014 23:34:38 +0000 (00:34 +0100)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Thu, 4 Dec 2014 16:38:39 +0000 (10:38 -0600)
include/deal.II/numerics/derivative_approximation.h
source/numerics/derivative_approximation.cc
source/numerics/derivative_approximation.inst.in

index 7bfa45666c3553c21b66d4148df570f4bda60621..1d48ba1e869a780d90c46bca94040910ba7ed4c2 100644 (file)
@@ -269,25 +269,25 @@ namespace DerivativeApproximation
    * In a parallel computation the @p solution vector needs to contain the
    * locally relevant unknowns.
    */
-  template <class DH, class InputVector, int order>
+  template <class DH, int dim, int spacedim, class InputVector, int order>
   void
-  approximate_derivative_tensor (const Mapping<DH::dimension,DH::space_dimension> &mapping,
-                                 const DH                                     &dof,
-                                 const InputVector                            &solution,
-                                 const typename DH::active_cell_iterator      &cell,
-                                 Tensor<order,DH::dimension>                  &derivative,
-                                 const unsigned int                            component = 0);
+  approximate_derivative_tensor(const Mapping<dim, spacedim> &mapping,
+                                const DH                      &dof,
+                                const InputVector                            &solution,
+                                const TriaActiveIterator < dealii::DoFCellAccessor < DH, false > >      &cell,
+                                Tensor<order, dim>  &derivative,
+                                const unsigned int                            component = 0);
 
   /**
    * Same as above, with <tt>mapping=MappingQ1@<dim@>()</tt>.
    */
-  template <class DH, class InputVector, int order>
+  template <class DH, int dim, int spacedim, class InputVector, int order>
   void
-  approximate_derivative_tensor (const DH                                     &dof,
-                                 const InputVector                            &solution,
-                                 const typename DH::active_cell_iterator      &cell,
-                                 Tensor<order,DH::dimension>                  &derivative,
-                                 const unsigned int                            component = 0);
+  approximate_derivative_tensor(const DH                    &dof,
+                                const InputVector                            &solution,
+                                const TriaActiveIterator < dealii::DoFCellAccessor < DH, false > >      &cell,
+                                Tensor<order, dim>                  &derivative,
+                                const unsigned int                            component = 0);
 
   /**
    * Return the norm of the derivative.
index 2518037bc93aa25efcba6953915294c03d9fa2f1..daecca9c040c9926430c0958ba5adb15694fdff0 100644 (file)
@@ -1070,14 +1070,14 @@ namespace DerivativeApproximation
   }
 
 
-  template <class DH, class InputVector, int order>
+  template <class DH, int dim, int spacedim, class InputVector, int order>
   void
-  approximate_derivative_tensor (const Mapping<DH::dimension,DH::space_dimension> &mapping,
-                                 const DH                                     &dof,
-                                 const InputVector                            &solution,
-                                 const typename DH::active_cell_iterator      &cell,
-                                 Tensor<order,DH::dimension>                  &derivative,
-                                 const unsigned int                            component)
+  approximate_derivative_tensor(const Mapping<dim, spacedim> &mapping,
+                                const DH                    &dof,
+                                const InputVector                            &solution,
+                                const TriaActiveIterator < dealii::DoFCellAccessor < DH, false > >      &cell,
+                                Tensor<order, dim>  &derivative,
+                                const unsigned int                            component)
   {
     internal::approximate_cell<typename internal::DerivativeSelector<order,DH::dimension>::DerivDescr>
     (mapping,
@@ -1090,17 +1090,17 @@ namespace DerivativeApproximation
 
 
 
-  template <class DH, class InputVector, int order>
+  template <class DH, int dim, int spacedim, class InputVector, int order>
   void
-  approximate_derivative_tensor (const DH                                     &dof,
-                                 const InputVector                            &solution,
-                                 const typename DH::active_cell_iterator      &cell,
-                                 Tensor<order,DH::dimension>                  &derivative,
-                                 const unsigned int                            component)
+  approximate_derivative_tensor(const DH                     &dof,
+                                const InputVector                            &solution,
+                                const TriaActiveIterator < dealii::DoFCellAccessor < DH, false > >      &cell,
+                                Tensor<order, dim>                  &derivative,
+                                const unsigned int                            component)
   {
     // just call the respective function with Q1 mapping
-    approximate_derivative_tensor<DH,InputVector,order>
-    (StaticMappingQ1<DH::dimension,DH::space_dimension>::mapping,
+    approximate_derivative_tensor<DH, dim, spacedim, InputVector, order>
+    (StaticMappingQ1<dim, spacedim>::mapping,
      dof,
      solution,
      cell,
index 76ced0f6d5de92c155d263c0159078bcfd3ecf58..044f75fa2179c308952a54f6ea820a136ef6be2b 100644 (file)
@@ -54,60 +54,60 @@ approximate_second_derivative<deal_II_dimension>
 
 template
 void
-approximate_derivative_tensor
-(const Mapping<DH<deal_II_dimension>::dimension,DH<deal_II_dimension>::space_dimension> &mapping,
- const DH<deal_II_dimension> &dof_handler,
+approximate_derivative_tensor < DH <deal_II_dimension>, deal_II_dimension, deal_II_dimension, VEC, 1 >
+(const Mapping<deal_II_dimension> &mapping,
+ const DH <deal_II_dimension> &dof_handler,
  const VEC &solution,
- const DH<deal_II_dimension>::active_cell_iterator &cell,
- Tensor<1,DH<deal_II_dimension>::dimension> &derivative,
+ const DH <deal_II_dimension>::active_cell_iterator &cell,
+ Tensor<1,deal_II_dimension> &derivative,
  const unsigned int     component);
 
 template
 void
-approximate_derivative_tensor
-(const Mapping<DH<deal_II_dimension>::dimension,DH<deal_II_dimension>::space_dimension> &mapping,
- const DH<deal_II_dimension> &dof_handler,
+approximate_derivative_tensor < DH <deal_II_dimension>, deal_II_dimension, deal_II_dimension, VEC, 2 >
+(const Mapping <deal_II_dimension> &mapping,
+ const DH <deal_II_dimension> &dof_handler,
  const VEC &solution,
- const DH<deal_II_dimension>::active_cell_iterator &cell,
- Tensor<2,DH<deal_II_dimension>::dimension> &derivative,
+ const DH <deal_II_dimension>::active_cell_iterator &cell,
+ Tensor<2,deal_II_dimension> &derivative,
  const unsigned int     component);
 
 template
 void
-approximate_derivative_tensor
-(const Mapping<DH<deal_II_dimension>::dimension,DH<deal_II_dimension>::space_dimension> &mapping,
- const DH<deal_II_dimension> &dof_handler,
+approximate_derivative_tensor < DH <deal_II_dimension>, deal_II_dimension, deal_II_dimension, VEC, 3 >
+(const Mapping <deal_II_dimension> &mapping,
+ const DH <deal_II_dimension> &dof_handler,
  const VEC &solution,
- const DH<deal_II_dimension>::active_cell_iterator &cell,
- Tensor<3,DH<deal_II_dimension>::dimension> &derivative,
+ const DH <deal_II_dimension>::active_cell_iterator &cell,
+ Tensor<3,deal_II_dimension> &derivative,
  const unsigned int     component);
 
 
 template
 void
-approximate_derivative_tensor
-(const DH<deal_II_dimension> &dof_handler,
+approximate_derivative_tensor < DH <deal_II_dimension>, deal_II_dimension, deal_II_dimension, VEC, 1 >
+(const DH <deal_II_dimension> &dof_handler,
  const VEC &solution,
- const DH<deal_II_dimension>::active_cell_iterator &cell,
- Tensor<1,DH<deal_II_dimension>::dimension> &derivative,
+ const DH <deal_II_dimension>::active_cell_iterator &cell,
+ Tensor<1,deal_II_dimension> &derivative,
  const unsigned int     component);
 
 template
 void
-approximate_derivative_tensor
-(const DH<deal_II_dimension> &dof_handler,
+approximate_derivative_tensor < DH <deal_II_dimension>, deal_II_dimension, deal_II_dimension, VEC, 2 >
+(const DH <deal_II_dimension> &dof_handler,
  const VEC &solution,
- const DH<deal_II_dimension>::active_cell_iterator &cell,
- Tensor<2,DH<deal_II_dimension>::dimension> &derivative,
+ const DH <deal_II_dimension>::active_cell_iterator &cell,
+ Tensor<2,deal_II_dimension> &derivative,
  const unsigned int     component);
 
 template
 void
-approximate_derivative_tensor
-(const DH<deal_II_dimension> &dof_handler,
+approximate_derivative_tensor < DH <deal_II_dimension>, deal_II_dimension, deal_II_dimension, VEC, 3 >
+(const DH <deal_II_dimension> &dof_handler,
  const VEC &solution,
- const DH<deal_II_dimension>::active_cell_iterator &cell,
- Tensor<3,DH<deal_II_dimension>::dimension> &derivative,
+ const DH <deal_II_dimension>::active_cell_iterator &cell,
+ Tensor<3,deal_II_dimension> &derivative,
  const unsigned int     component);
 
   \}

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.