Skip to content
Snippets Groups Projects

Various minor improvements by Lisa

Merged oliver.sander_at_tu-dresden.de requested to merge lisa-cleanup into master
5 files
+ 74
104
Compare changes
  • Side-by-side
  • Inline
Files
5
@@ -28,6 +28,12 @@ class FEAssembler {
public:
const Basis basis_;
/** \brief Partition type on which to assemble
*
* We want a fully nonoverlapping partition, and therefore need to skip ghost elements.
*/
static constexpr auto partitionType = Dune::Partitions::interiorBorder;
protected:
LocalFEStiffness<GridView,
@@ -70,7 +76,7 @@ getNeighborsPerVertex(Dune::MatrixIndexSet& nb) const
nb.resize(n, n);
for (const auto& element : elements(basis_.getGridView(), Dune::Partitions::interior))
for (const auto& element : elements(basis_.getGridView(), partitionType))
{
const typename Basis::LocalFiniteElement& lfe = basis_.getLocalFiniteElement(element);
@@ -111,7 +117,7 @@ assembleGradientAndHessian(const VectorType& sol,
gradient.resize(sol.size());
gradient = 0;
for (const auto& element : elements(basis_.getGridView(), Dune::Partitions::interior))
for (const auto& element : elements(basis_.getGridView(), partitionType))
{
const int numOfBaseFct = basis_.getLocalFiniteElement(element).localBasis().size();
@@ -159,7 +165,7 @@ computeEnergy(const VectorType& sol) const
DUNE_THROW(Dune::Exception, "Solution vector doesn't match the basis!");
// Loop over all elements
for (const auto& element : elements(basis_.getGridView(), Dune::Partitions::interior))
for (const auto& element : elements(basis_.getGridView(), partitionType))
{
// Number of degrees of freedom on this element
size_t nDofs = basis_.getLocalFiniteElement(element).localBasis().size();
Loading