Skip to content
Snippets Groups Projects
Commit 105ccc22 authored by Hörl, Maximilian's avatar Hörl, Maximilian
Browse files

[WIP] change quadrature rule

parent e1f94d76
No related branches found
No related tags found
No related merge requests found
...@@ -73,11 +73,11 @@ private: ...@@ -73,11 +73,11 @@ private:
//and the indices elemIdxSLE + i + 1, i = 1,...,dim, refer to the //and the indices elemIdxSLE + i + 1, i = 1,...,dim, refer to the
//basis function phi_elem,i //basis function phi_elem,i
const int elemIdxSLE = (dim + 1)*elemIdx; const int elemIdxSLE = (dim + 1)*elemIdx;
/*
/* //TODO: can be done outside of the loop? //TODO: can be done outside of the loop?
const Dune::QuadratureRule<double,dim>& rule = const Dune::QuadratureRule<double,dim>& rule =
Dune::QuadratureRules<double,dim>::rule(geo.type(), problem_.quadratureOrder()); Dune::QuadratureRules<double,dim>::rule(geo.type(), problem_.quadratureOrder());
Dune::FieldVector<double, dim+1> update(0.0); // Dune::FieldVector<double, dim+1> update(0.0);
//NOTE: how are quadrature rules in Dune applied correctly? //NOTE: how are quadrature rules in Dune applied correctly?
for (const auto& ip : rule) for (const auto& ip : rule)
...@@ -88,12 +88,12 @@ private: ...@@ -88,12 +88,12 @@ private:
const double weight = ip.weight(); const double weight = ip.weight();
//quadrature for int_elem q*phi_elem,0 dV //quadrature for int_elem q*phi_elem,0 dV
b[elemIdxSLE] += weight * problem_.q(qp); b[elemIdxSLE] += weight * problem_.q(geo.global(qp)) * geo.integrationElement(qp);
//quadrature for int_elem q*phi_elem,i dV //quadrature for int_elem q*phi_elem,i dV
for (int i = 0; i < dim; i++) for (int i = 0; i < dim; i++)
{ {
b[elemIdxSLE + i + 1] += weight * qp[i] * problem_.q(qp); b[elemIdxSLE + i + 1] += weight * qp[i] * problem_.q(geo.global(qp)) * geo.integrationElement(qp);
} }
} }
*/ */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment