Reference documentation for deal.II version 8.5.1
derivative_approximation.h
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 2000 - 2017 by the deal.II authors
4 //
5 // This file is part of the deal.II library.
6 //
7 // The deal.II library is free software; you can use it, redistribute
8 // it, and/or modify it under the terms of the GNU Lesser General
9 // Public License as published by the Free Software Foundation; either
10 // version 2.1 of the License, or (at your option) any later version.
11 // The full text of the license can be found in the file LICENSE at
12 // the top level of the deal.II distribution.
13 //
14 // ---------------------------------------------------------------------
15 
16 #ifndef dealii__derivative_approximation_h
17 #define dealii__derivative_approximation_h
18 
19 #include <deal.II/base/config.h>
20 #include <deal.II/base/exceptions.h>
21 #include <deal.II/base/std_cxx11/tuple.h>
22 #include <deal.II/base/synchronous_iterator.h>
23 #include <deal.II/fe/fe_update_flags.h>
24 #include <deal.II/fe/mapping.h>
25 #include <deal.II/lac/vector.h>
26 #include <deal.II/grid/filtered_iterator.h>
27 #ifdef _MSC_VER
28 # include <deal.II/dofs/dof_accessor.h>
29 #endif
30 #include <utility>
31 
32 DEAL_II_NAMESPACE_OPEN
33 
157 {
173  template <int dim, template <int, int> class DoFHandlerType, class InputVector, int spacedim>
174  void
176  const DoFHandlerType<dim,spacedim> &dof,
177  const InputVector &solution,
179  const unsigned int component = 0);
180 
185  template <int dim, template <int, int> class DoFHandlerType, class InputVector, int spacedim>
186  void
187  approximate_gradient (const DoFHandlerType<dim,spacedim> &dof,
188  const InputVector &solution,
190  const unsigned int component = 0);
191 
209  template <int dim, template <int, int> class DoFHandlerType, class InputVector, int spacedim>
210  void
212  const DoFHandlerType<dim,spacedim> &dof,
213  const InputVector &solution,
215  const unsigned int component = 0);
216 
221  template <int dim, template <int, int> class DoFHandlerType, class InputVector, int spacedim>
222  void
223  approximate_second_derivative (const DoFHandlerType<dim,spacedim> &dof,
224  const InputVector &solution,
226  const unsigned int component = 0);
227 
241  template <typename DoFHandlerType, class InputVector, int order>
242  void
245  const DoFHandlerType &dof,
246  const InputVector &solution,
247 #ifndef _MSC_VER
248  const typename DoFHandlerType::active_cell_iterator &cell,
249 #else
251 #endif
253  const unsigned int component = 0);
254 
258  template <typename DoFHandlerType, class InputVector, int order>
259  void
261  (const DoFHandlerType &dof,
262  const InputVector &solution,
263 #ifndef _MSC_VER
264  const typename DoFHandlerType::active_cell_iterator &cell,
265 #else
267 #endif
269  const unsigned int component = 0);
270 
274  template <int dim, int order>
275  double
276  derivative_norm (const Tensor<order,dim> &derivative);
277 
282  int, int,
283  << "The output vector needs to have a size equal "
284  "to the number of active cells of your triangulation "
285  "but has length " << arg1 << "There are "
286  << arg2 << " active cells in your triangulation.");
291  "We have encountered a cell on which the number of linearly "
292  "independent directions that span the matrix Y (discussed "
293  "in the documentation of the DerivativeApproximation "
294  "class) is not equal to dim. The matrix Y then is "
295  "rank deficient and can not be inverted.");
296 }
297 
298 
299 
300 DEAL_II_NAMESPACE_CLOSE
301 
302 #endif
static ::ExceptionBase & ExcInsufficientDirections()
#define DeclException2(Exception2, type1, type2, outsequence)
Definition: exceptions.h:576
Abstract base class for mapping classes.
Definition: dof_tools.h:46
#define DeclExceptionMsg(Exception, defaulttext)
Definition: exceptions.h:553
double derivative_norm(const Tensor< order, dim > &derivative)
void approximate_derivative_tensor(const Mapping< DoFHandlerType::dimension, DoFHandlerType::space_dimension > &mapping, const DoFHandlerType &dof, const InputVector &solution, const typename DoFHandlerType::active_cell_iterator &cell, Tensor< order, DoFHandlerType::dimension > &derivative, const unsigned int component=0)
Definition: mpi.h:41
void approximate_second_derivative(const Mapping< dim, spacedim > &mapping, const DoFHandlerType< dim, spacedim > &dof, const InputVector &solution, Vector< float > &derivative_norm, const unsigned int component=0)
void approximate_gradient(const Mapping< dim, spacedim > &mapping, const DoFHandlerType< dim, spacedim > &dof, const InputVector &solution, Vector< float > &derivative_norm, const unsigned int component=0)
static ::ExceptionBase & ExcVectorLengthVsNActiveCells(int arg1, int arg2)