Reference documentation for deal.II version 9.1.1
\(\newcommand{\dealcoloneq}{\mathrel{\vcenter{:}}=}\)
mapping_q_eulerian.h
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 2001 - 2018 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.md at
12 // the top level directory of deal.II.
13 //
14 // ---------------------------------------------------------------------
15 
16 
17 #ifndef dealii_mapping_q_eulerian_h
18 #define dealii_mapping_q_eulerian_h
19 
20 #include <deal.II/base/config.h>
21 
22 #include <deal.II/base/smartpointer.h>
23 #include <deal.II/base/thread_management.h>
24 
25 #include <deal.II/dofs/dof_accessor.h>
26 #include <deal.II/dofs/dof_handler.h>
27 
28 #include <deal.II/fe/fe_values.h>
29 #include <deal.II/fe/mapping_q.h>
30 
31 #include <deal.II/grid/tria_iterator.h>
32 
33 
34 DEAL_II_NAMESPACE_OPEN
35 
36 template <typename>
37 class Vector;
38 
39 
42 
94 template <int dim, typename VectorType = Vector<double>, int spacedim = dim>
95 class MappingQEulerian : public MappingQ<dim, spacedim>
96 {
97 public:
114  MappingQEulerian(const unsigned int degree,
116  const VectorType & euler_vector,
117  const unsigned int level = numbers::invalid_unsigned_int);
118 
125  virtual std::array<Point<spacedim>, GeometryInfo<dim>::vertices_per_cell>
127  const override;
128 
133  virtual std::unique_ptr<Mapping<dim, spacedim>>
134  clone() const override;
135 
141  virtual bool
142  preserves_vertex_locations() const override;
143 
149 
150 protected:
161  const typename Triangulation<dim, spacedim>::cell_iterator &cell,
162  const CellSimilarity::Similarity cell_similarity,
163  const Quadrature<dim> & quadrature,
164  const typename Mapping<dim, spacedim>::InternalDataBase & internal_data,
166  &output_data) const override;
167 
173 
180 
181 
182 private:
186  const unsigned int level;
187 
193  class MappingQEulerianGeneric : public MappingQGeneric<dim, spacedim>
194  {
195  public:
200  const unsigned int degree,
202 
209  virtual std::array<Point<spacedim>, GeometryInfo<dim>::vertices_per_cell>
211  &cell) const override;
212 
218  virtual std::vector<Point<spacedim>>
220  const typename Triangulation<dim, spacedim>::cell_iterator &cell)
221  const override;
222 
228  virtual bool
229  preserves_vertex_locations() const override;
230 
231  private:
236 
237 
242  class SupportQuadrature : public Quadrature<dim>
243  {
244  public:
248  SupportQuadrature(const unsigned int map_degree);
249  };
250 
255 
265 
270  };
271 };
272 
276 /*----------------------------------------------------------------------*/
277 
278 #ifndef DOXYGEN
279 
280 template <int dim, typename VectorType, int spacedim>
281 inline bool
283 {
284  return false;
285 }
286 
287 #endif // DOXYGEN
288 
289 
290 DEAL_II_NAMESPACE_CLOSE
291 
292 
293 #endif // dealii_mapping_q_eulerian_h
static const unsigned int invalid_unsigned_int
Definition: types.h:173
SmartPointer< const DoFHandler< dim, spacedim >, MappingQEulerian< dim, VectorType, spacedim > > euler_dof_handler
const unsigned int level
static ::ExceptionBase & ExcInactiveCell()
LinearAlgebra::distributed::Vector< Number > Vector
virtual CellSimilarity::Similarity fill_fe_values(const typename Triangulation< dim, spacedim >::cell_iterator &cell, const CellSimilarity::Similarity cell_similarity, const Quadrature< dim > &quadrature, const typename Mapping< dim, spacedim >::InternalDataBase &internal_data, internal::FEValuesImplementation::MappingRelatedData< dim, spacedim > &output_data) const override
MappingQEulerianGeneric(const unsigned int degree, const MappingQEulerian< dim, VectorType, spacedim > &mapping_q_eulerian)
virtual std::array< Point< spacedim >, GeometryInfo< dim >::vertices_per_cell > get_vertices(const typename Triangulation< dim, spacedim >::cell_iterator &cell) const override
virtual std::vector< Point< spacedim > > compute_mapping_support_points(const typename Triangulation< dim, spacedim >::cell_iterator &cell) const override
#define DeclException0(Exception0)
Definition: exceptions.h:473
MappingQEulerian(const unsigned int degree, const DoFHandler< dim, spacedim > &euler_dof_handler, const VectorType &euler_vector, const unsigned int level=numbers::invalid_unsigned_int)
virtual std::array< Point< spacedim >, GeometryInfo< dim >::vertices_per_cell > get_vertices(const typename Triangulation< dim, spacedim >::cell_iterator &cell) const override
virtual bool preserves_vertex_locations() const override
virtual std::unique_ptr< Mapping< dim, spacedim > > clone() const override
const MappingQEulerian< dim, VectorType, spacedim > & mapping_q_eulerian
Definition: fe.h:38
virtual bool preserves_vertex_locations() const override
SmartPointer< const VectorType, MappingQEulerian< dim, VectorType, spacedim > > euler_vector