Reference documentation for deal.II version 9.5.0
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
Loading...
Searching...
No Matches
fe_field_function.h
Go to the documentation of this file.
1// ---------------------------------------------------------------------
2//
3// Copyright (C) 2007 - 2022 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#ifndef dealii_fe_function_h
17#define dealii_fe_function_h
18
19#include <deal.II/base/config.h>
20
22#include <deal.II/base/point.h>
24#include <deal.II/base/tensor.h>
26
29
31
33
34#include <deal.II/lac/vector.h>
35
36
38
39// Forward declaration
40#ifndef DOXYGEN
41namespace VectorTools
42{
44}
45#endif
46
47namespace Functions
48{
166 template <int dim, typename VectorType = Vector<double>, int spacedim = dim>
167 class FEFieldFunction : public Function<dim, typename VectorType::value_type>
168 {
169 public:
180 const VectorType & data_vector,
182
188 void
191
207 virtual void
209 const Point<dim> & p,
210 Vector<typename VectorType::value_type> &values) const override;
211
229 virtual typename VectorType::value_type
230 value(const Point<dim> &p, const unsigned int component = 0) const override;
231
247 virtual void
248 value_list(const std::vector<Point<dim>> & points,
249 std::vector<typename VectorType::value_type> &values,
250 const unsigned int component = 0) const override;
251
252
268 virtual void
269 vector_value_list(const std::vector<Point<dim>> &points,
271 &values) const override;
272
288 virtual void
291 &gradients) const override;
292
310 const unsigned int component = 0) const override;
311
325 virtual void
327 const std::vector<Point<dim>> &p,
329 &gradients) const override;
330
344 virtual void
346 const std::vector<Point<dim>> & p,
348 const unsigned int component = 0) const override;
349
350
362 virtual typename VectorType::value_type
364 const unsigned int component = 0) const override;
365
378 virtual void
380 const Point<dim> & p,
381 Vector<typename VectorType::value_type> &values) const override;
382
394 virtual void
395 laplacian_list(const std::vector<Point<dim>> & points,
396 std::vector<typename VectorType::value_type> &values,
397 const unsigned int component = 0) const override;
398
410 virtual void
411 vector_laplacian_list(const std::vector<Point<dim>> &points,
413 &values) const override;
414
437 unsigned int
439 const std::vector<Point<dim>> &points,
441 & cells,
442 std::vector<std::vector<Point<dim>>> & qpoints,
443 std::vector<std::vector<unsigned int>> &maps) const;
444
445 private:
451
458
462 const VectorType &data_vector;
463
468
473
478
484 std_cxx17::optional<Point<dim>>
487 const Point<dim> &point) const;
488 };
489} // namespace Functions
490
491
493
494#endif
unsigned int compute_point_locations(const std::vector< Point< dim > > &points, std::vector< typename DoFHandler< dim, spacedim >::active_cell_iterator > &cells, std::vector< std::vector< Point< dim > > > &qpoints, std::vector< std::vector< unsigned int > > &maps) const
virtual void value_list(const std::vector< Point< dim > > &points, std::vector< typename VectorType::value_type > &values, const unsigned int component=0) const override
virtual void vector_gradient(const Point< dim > &p, std::vector< Tensor< 1, dim, typename VectorType::value_type > > &gradients) const override
virtual void laplacian_list(const std::vector< Point< dim > > &points, std::vector< typename VectorType::value_type > &values, const unsigned int component=0) const override
virtual Tensor< 1, dim, typename VectorType::value_type > gradient(const Point< dim > &p, const unsigned int component=0) const override
virtual VectorType::value_type laplacian(const Point< dim > &p, const unsigned int component=0) const override
void set_active_cell(const typename DoFHandler< dim, spacedim >::active_cell_iterator &newcell)
virtual void vector_value(const Point< dim > &p, Vector< typename VectorType::value_type > &values) const override
virtual VectorType::value_type value(const Point< dim > &p, const unsigned int component=0) const override
GridTools::Cache< dim, spacedim > cache
virtual void vector_gradient_list(const std::vector< Point< dim > > &p, std::vector< std::vector< Tensor< 1, dim, typename VectorType::value_type > > > &gradients) const override
virtual void gradient_list(const std::vector< Point< dim > > &p, std::vector< Tensor< 1, dim, typename VectorType::value_type > > &gradients, const unsigned int component=0) const override
const Mapping< dim > & mapping
virtual void vector_value_list(const std::vector< Point< dim > > &points, std::vector< Vector< typename VectorType::value_type > > &values) const override
std_cxx17::optional< Point< dim > > get_reference_coordinates(const typename DoFHandler< dim, spacedim >::active_cell_iterator &cell, const Point< dim > &point) const
FEFieldFunction(const DoFHandler< dim, spacedim > &dh, const VectorType &data_vector, const Mapping< dim > &mapping=StaticMappingQ1< dim >::mapping)
virtual void vector_laplacian_list(const std::vector< Point< dim > > &points, std::vector< Vector< typename VectorType::value_type > > &values) const override
SmartPointer< const DoFHandler< dim, spacedim >, FEFieldFunction< dim, VectorType, spacedim > > dh
virtual void vector_laplacian(const Point< dim > &p, Vector< typename VectorType::value_type > &values) const override
Abstract base class for mapping classes.
Definition mapping.h:317
Definition point.h:112
A class that provides a separate storage location on each thread that accesses the object.
#define DEAL_II_NAMESPACE_OPEN
Definition config.h:472
#define DEAL_II_NAMESPACE_CLOSE
Definition config.h:473
static ::ExceptionBase & ExcPointNotAvailableHere()
typename ActiveSelector::active_cell_iterator active_cell_iterator