// ---------------------------------------------------------------------
//
// Copyright (C) 2010 - 2020 by the deal.II authors
//
// This file is part of the deal.II library.
//
// The deal.II library is free software; you can use it, redistribute
// it, and/or modify it under the terms of the GNU Lesser General
// Public License as published by the Free Software Foundation; either
// version 2.1 of the License, or (at your option) any later version.
// The full text of the license can be found in the file LICENSE.md at
// the top level directory of deal.II.
//
// ---------------------------------------------------------------------


for (deal_II_dimension : DIMENSIONS; VEC : REAL_VECTOR_TYPES)
  {
    namespace DerivativeApproximation
    \{
      template void
      approximate_gradient<deal_II_dimension>(
        const Mapping<deal_II_dimension> &   mapping,
        const DoFHandler<deal_II_dimension> &dof_handler,
        const VEC &                          solution,
        Vector<float> &                      derivative_norm,
        const unsigned int                   component);

      template void
      approximate_gradient<deal_II_dimension>(
        const DoFHandler<deal_II_dimension> &dof_handler,
        const VEC &                          solution,
        Vector<float> &                      derivative_norm,
        const unsigned int                   component);

      template void
      approximate_second_derivative<deal_II_dimension>(
        const Mapping<deal_II_dimension> &   mapping,
        const DoFHandler<deal_II_dimension> &dof_handler,
        const VEC &                          solution,
        Vector<float> &                      derivative_norm,
        const unsigned int                   component);

      template void
      approximate_second_derivative<deal_II_dimension>(
        const DoFHandler<deal_II_dimension> &dof_handler,
        const VEC &                          solution,
        Vector<float> &                      derivative_norm,
        const unsigned int                   component);

      template void
      approximate_derivative_tensor<deal_II_dimension,
                                    deal_II_dimension,
                                    VEC,
                                    1>(
        const Mapping<deal_II_dimension> &                         mapping,
        const DoFHandler<deal_II_dimension> &                      dof_handler,
        const VEC &                                                solution,
        const DoFHandler<deal_II_dimension>::active_cell_iterator &cell,
        Tensor<1, deal_II_dimension> &                             derivative,
        const unsigned int                                         component);

      template void
      approximate_derivative_tensor<deal_II_dimension,
                                    deal_II_dimension,
                                    VEC,
                                    2>(
        const Mapping<deal_II_dimension> &                         mapping,
        const DoFHandler<deal_II_dimension> &                      dof_handler,
        const VEC &                                                solution,
        const DoFHandler<deal_II_dimension>::active_cell_iterator &cell,
        Tensor<2, deal_II_dimension> &                             derivative,
        const unsigned int                                         component);

      template void
      approximate_derivative_tensor<deal_II_dimension,
                                    deal_II_dimension,
                                    VEC,
                                    3>(
        const Mapping<deal_II_dimension> &                         mapping,
        const DoFHandler<deal_II_dimension> &                      dof_handler,
        const VEC &                                                solution,
        const DoFHandler<deal_II_dimension>::active_cell_iterator &cell,
        Tensor<3, deal_II_dimension> &                             derivative,
        const unsigned int                                         component);


      template void
      approximate_derivative_tensor<deal_II_dimension,
                                    deal_II_dimension,
                                    VEC,
                                    1>(
        const DoFHandler<deal_II_dimension> &                      dof_handler,
        const VEC &                                                solution,
        const DoFHandler<deal_II_dimension>::active_cell_iterator &cell,
        Tensor<1, deal_II_dimension> &                             derivative,
        const unsigned int                                         component);

      template void
      approximate_derivative_tensor<deal_II_dimension,
                                    deal_II_dimension,
                                    VEC,
                                    2>(
        const DoFHandler<deal_II_dimension> &                      dof_handler,
        const VEC &                                                solution,
        const DoFHandler<deal_II_dimension>::active_cell_iterator &cell,
        Tensor<2, deal_II_dimension> &                             derivative,
        const unsigned int                                         component);

      template void
      approximate_derivative_tensor<deal_II_dimension,
                                    deal_II_dimension,
                                    VEC,
                                    3>(
        const DoFHandler<deal_II_dimension> &                      dof_handler,
        const VEC &                                                solution,
        const DoFHandler<deal_II_dimension>::active_cell_iterator &cell,
        Tensor<3, deal_II_dimension> &                             derivative,
        const unsigned int                                         component);

    \}
  }


for (deal_II_dimension : DIMENSIONS)
  {
    namespace DerivativeApproximation
    \{
      template double
      derivative_norm(const Tensor<1, deal_II_dimension> &derivative);

      template double
      derivative_norm(const Tensor<2, deal_II_dimension> &derivative);

      template double
      derivative_norm(const Tensor<3, deal_II_dimension> &derivative);
    \}
  }
