Loading [MathJax]/extensions/TeX/newcommand.js
 deal.II version GIT relicensing-3075-gc235bd4825 2025-04-15 08:10:00+00:00
\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\}}
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages Concepts
evaluation_selector.h
Go to the documentation of this file.
1// ------------------------------------------------------------------------
2//
3// SPDX-License-Identifier: LGPL-2.1-or-later
4// Copyright (C) 2017 - 2023 by the deal.II authors
5//
6// This file is part of the deal.II library.
7//
8// Part of the source code is dual licensed under Apache-2.0 WITH
9// LLVM-exception OR LGPL-2.1-or-later. Detailed license information
10// governing the source code and code contributions can be found in
11// LICENSE.md and CONTRIBUTING.md at the top level directory of deal.II.
12//
13// ------------------------------------------------------------------------
14
15
16#ifndef dealii_matrix_free_evaluation_selector_h
17#define dealii_matrix_free_evaluation_selector_h
18
19#include <deal.II/base/config.h>
20
24
25#include <type_traits>
26
27
29
30
31
37template <int dim, int fe_degree, int n_q_points_1d, typename Number>
39{
47 static void
48 evaluate(const unsigned int n_components,
49 const EvaluationFlags::EvaluationFlags evaluation_flag,
50 const Number *values_dofs,
52
60 static void
61 integrate(const unsigned int n_components,
62 const EvaluationFlags::EvaluationFlags integration_flag,
63 Number *values_dofs,
65 const bool sum_into_values_array = false);
66};
67
68//----------------------Implementation for SelectEvaluator---------------------
69#ifndef DOXYGEN
70
71template <int dim, int fe_degree, int n_q_points_1d, typename Number>
72inline void
74 const unsigned int n_components,
75 const EvaluationFlags::EvaluationFlags evaluation_flag,
76 const Number *values_dofs,
78{
79 Assert(fe_degree >= 0 && n_q_points_1d > 0, ExcInternalError());
80
82 fe_degree,
83 n_q_points_1d>(n_components, evaluation_flag, values_dofs, eval);
84}
85
86
87
88template <int dim, int fe_degree, int n_q_points_1d, typename Number>
89inline void
91 const unsigned int n_components,
92 const EvaluationFlags::EvaluationFlags integration_flag,
93 Number *values_dofs,
95 const bool sum_into_values_array)
96{
97 Assert(fe_degree >= 0 && n_q_points_1d > 0, ExcInternalError());
98
100 template run<fe_degree, n_q_points_1d>(
101 n_components, integration_flag, values_dofs, eval, sum_into_values_array);
102}
103#endif // DOXYGEN
104
106
107#endif
#define DEAL_II_NAMESPACE_OPEN
Definition config.h:35
#define DEAL_II_NAMESPACE_CLOSE
Definition config.h:36
#define Assert(cond, exc)
static ::ExceptionBase & ExcInternalError()
EvaluationFlags
The EvaluationFlags enum.
static void integrate(const unsigned int n_components, const EvaluationFlags::EvaluationFlags integration_flag, Number *values_dofs, FEEvaluationData< dim, Number, false > &eval, const bool sum_into_values_array=false)
static void evaluate(const unsigned int n_components, const EvaluationFlags::EvaluationFlags evaluation_flag, const Number *values_dofs, FEEvaluationData< dim, Number, false > &eval)