Bembel
integrate1.hpp
1 // This file is part of Bembel, the higher order C++ boundary element library.
2 //
3 // Copyright (C) 2022 see <http://www.bembel.eu>
4 //
5 // It was written as part of a cooperation of J. Doelz, H. Harbrecht, S. Kurz,
6 // M. Multerer, S. Schoeps, and F. Wolf at Technische Universitaet Darmstadt,
7 // Universitaet Basel, and Universita della Svizzera italiana, Lugano. This
8 // source code is subject to the GNU General Public License version 3 and
9 // provided WITHOUT ANY WARRANTY, see <http://www.bembel.eu> for further
10 // information.
11 #ifndef BEMBEL_SRC_DUFFYTRICK_INTEGRATE1_HPP_
12 #define BEMBEL_SRC_DUFFYTRICK_INTEGRATE1_HPP_
13 
14 namespace Bembel {
15 namespace DuffyTrick {
25 template <typename Derived, class T>
26 void integrate1(const LinearOperatorBase<Derived> &LinOp, const T &super_space,
27  const ElementTreeNode &e1, int rot1, const ElementTreeNode &e2,
28  int rot2, const ElementSurfacePoints &ffield_qnodes1,
29  const ElementSurfacePoints &ffield_qnodes2, const Cubature &Q,
30  Eigen::Matrix<typename LinearOperatorTraits<Derived>::Scalar,
31  Eigen::Dynamic, Eigen::Dynamic> *intval) {
32  double h = e1.get_h();
33  intval->setZero();
34  SurfacePoint qp1, qp2;
35  for (auto i = 0; i < Q.w_.size(); ++i) {
36  super_space.map2surface(e1, Q.xi_.col(i), h * Q.w_(i), &qp1);
37  for (auto j = 0; j < Q.w_.size(); ++j) {
38  super_space.map2surface(e2, Q.xi_.col(j), h * Q.w_(j), &qp2);
39  LinOp.evaluateIntegrand(super_space, qp1, qp2, intval);
40  }
41  }
42 
43  BEMBEL_UNUSED_(rot1);
44  BEMBEL_UNUSED_(rot2);
45  BEMBEL_UNUSED_(ffield_qnodes1);
46  BEMBEL_UNUSED_(ffield_qnodes2);
47  return;
48 }
49 } // namespace DuffyTrick
50 } // namespace Bembel
51 #endif // BEMBEL_SRC_DUFFYTRICK_INTEGRATE1_HPP_
The ElementTreeNode corresponds to an element in the element tree.
double get_h() const
getter
void integrate1(const LinearOperatorBase< Derived > &LinOp, const T &super_space, const ElementTreeNode &e1, int rot1, const ElementTreeNode &e2, int rot2, const ElementSurfacePoints &ffield_qnodes1, const ElementSurfacePoints &ffield_qnodes2, const Cubature &Q, Eigen::Matrix< typename LinearOperatorTraits< Derived >::Scalar, Eigen::Dynamic, Eigen::Dynamic > *intval)
no-problem quadrature routine, elements are sufficiently far away from each other,...
Definition: integrate1.hpp:26
Eigen::Matrix< double, 12, 1 > SurfacePoint
typedef of SurfacePoint
std::vector< SurfacePoint, Eigen::aligned_allocator< SurfacePoint > > ElementSurfacePoints
typedef std::vector<SurfacePoint> with aligned allocator of Eigen for compatibility with older compil...
Routines for the evalutation of pointwise errors.
Definition: AnsatzSpace.hpp:14
linear operator base class. this serves as a common interface for existing linear operators.
struct containing specifications on the linear operator has to be specialized or derived for any part...