FirstOrderPartialTestTrial.hpp 968 Bytes
Newer Older
1
2
3
4
#pragma once

#include <type_traits>

5
#include <amdis/localoperators/FirstOrderTestPartialTrial.hpp>
6
7
8

namespace AMDiS
{
9
10
11
12
13
  /**
   * \addtogroup operators
   * @{
   **/

14
15
16
17
  namespace tag
  {
    struct partialtest_trial
    {
18
      std::size_t comp;
19
    };
20
21
22
23
24

    struct partial_test
    {
      std::size_t comp;
    };
25
26
27
  }


28
  /// first-order operator \f$ \langle\partial_i\psi, c\,\phi\rangle \f$
29
30
  template <class LC>
  struct GridFunctionOperatorRegistry<tag::partialtest_trial, LC>
31
  {
32
33
34
35
36
37
    static constexpr int degree = 1;
    static tag::test_partialtrial transposedTag(tag::partialtest_trial t)
    {
      return {t.comp};
    }
    using type = FirstOrderTestPartialTrial;
38
39
  };

40
41

  /// Create a first-order term with derivative on trial-function
42
43
  template <class Expr>
  auto fot(Expr&& expr, tag::partial_test t, int quadOrder = -1)
44
  {
45
    return makeOperator(tag::partialtest_trial{t.comp}, FWD(expr), quadOrder);
46
47
  }

48
49
  /** @} **/

50
} // end namespace AMDiS