Loading...
Searching...
No Matches
galerkin.hh
Go to the documentation of this file.
// SPDX-FileCopyrightText: Copyright © DUNE Project contributors, see file LICENSE.md in module root
// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
// vi: set et ts=4 sw=2 sts=2:
#ifndef DUNE_GALERKIN_HH
#define DUNE_GALERKIN_HH
#include "aggregates.hh"
#include "pinfo.hh"
#include <dune/common/poolallocator.hh>
#include <dune/common/enumset.hh>
#include <set>
#include <limits>
#include <algorithm>
namespace Dune
{
namespace Amg
{
template<class T>
struct OverlapVertex
{
typedef T Aggregate;
typedef T Vertex;
Aggregate* aggregate;
Vertex vertex;
};
template<class M>
class SparsityBuilder
{
public:
SparsityBuilder(M& matrix);
void insert(const typename M::size_type& index);
void operator++();
std::size_t minRowSize();
std::size_t maxRowSize();
std::size_t sumRowSize();
std::size_t index()
{
return row_.index();
}
private:
typename M::CreateIterator row_;
std::size_t minRowSize_;
std::size_t maxRowSize_;
std::size_t sumRowSize_;
#ifdef DUNE_ISTL_WITH_CHECKING
bool diagonalInserted;
#endif
};
class BaseGalerkinProduct
{
public:
template<class M, class V, class I, class O>
void calculate(const M& fine, const AggregatesMap<V>& aggregates, M& coarse,
const I& pinfo, const O& copy);
};
template<class T>
class GalerkinProduct
: public BaseGalerkinProduct
{
public:
typedef T ParallelInformation;
template<class G, class V, class Set>
typename G::MutableMatrix* build(G& fineGraph, V& visitedMap,
const ParallelInformation& pinfo,
AggregatesMap<typename G::VertexDescriptor>& aggregates,
const typename G::Matrix::size_type& size,
const Set& copy);
private:
template<class G, class I, class Set>
const OverlapVertex<typename G::VertexDescriptor>*
buildOverlapVertices(const G& graph, const I& pinfo,
AggregatesMap<typename G::VertexDescriptor>& aggregates,
const Set& overlap,
std::size_t& overlapCount);
template<class A>
struct OVLess
{
bool operator()(const OverlapVertex<A>& o1, const OverlapVertex<A>& o2)
{
return *o1.aggregate < *o2.aggregate;
}
};
};
template<>
class GalerkinProduct<SequentialInformation>
: public BaseGalerkinProduct
{
public:
template<class G, class V, class Set>
typename G::MutableMatrix* build(G& fineGraph, V& visitedMap,
const SequentialInformation& pinfo,
const AggregatesMap<typename G::VertexDescriptor>& aggregates,
const typename G::Matrix::size_type& size,
const Set& copy);
};
struct BaseConnectivityConstructor
{
template<class R, class G, class V>
static void constructOverlapConnectivity(R& row, G& graph, V& visitedMap,
const AggregatesMap<typename G::VertexDescriptor>& aggregates,
const OverlapVertex<typename G::VertexDescriptor>*& seed,
const OverlapVertex<typename G::VertexDescriptor>* overlapEnd);
template<class R, class G, class V>
static void constructNonOverlapConnectivity(R& row, G& graph, V& visitedMap,
const AggregatesMap<typename G::VertexDescriptor>& aggregates,
const typename G::VertexDescriptor& seed);
template<class G, class S, class V>
class ConnectedBuilder
{
public:
typedef G Graph;
typedef typename Graph::ConstEdgeIterator ConstEdgeIterator;
typedef S Set;
typedef V VisitedMap;
typedef typename Graph::VertexDescriptor Vertex;
ConnectedBuilder(const AggregatesMap<Vertex>& aggregates, Graph& graph,
VisitedMap& visitedMap, Set& connected);
void operator()(const ConstEdgeIterator& edge);
private:
const AggregatesMap<Vertex>& aggregates_;
Graph& graph_;
VisitedMap& visitedMap_;
Set& connected_;
};
};
template<class G, class T>
struct ConnectivityConstructor : public BaseConnectivityConstructor
{
typedef typename G::VertexDescriptor Vertex;
template<class V, class O, class R>
static void examine(G& graph,
V& visitedMap,
const T& pinfo,
const AggregatesMap<Vertex>& aggregates,
const O& overlap,
const OverlapVertex<Vertex>* overlapVertices,
const OverlapVertex<Vertex>* overlapEnd,
R& row);
};
template<class G>
struct ConnectivityConstructor<G,SequentialInformation> : public BaseConnectivityConstructor
{
typedef typename G::VertexDescriptor Vertex;
template<class V, class R>
static void examine(G& graph,
V& visitedMap,
const SequentialInformation& pinfo,
const AggregatesMap<Vertex>& aggregates,
R& row);
};
template<class T>
struct DirichletBoundarySetter
{
template<class M, class O>
static void set(M& coarse, const T& pinfo, const O& copy);
};
template<>
struct DirichletBoundarySetter<SequentialInformation>
{
template<class M, class O>
static void set(M& coarse, const SequentialInformation& pinfo, const O& copy);
};
template<class R, class G, class V>
void BaseConnectivityConstructor::constructNonOverlapConnectivity(R& row, G& graph, V& visitedMap,
const AggregatesMap<typename G::VertexDescriptor>& aggregates,
const typename G::VertexDescriptor& seed)
{
assert(row.index()==aggregates[seed]);
row.insert(aggregates[seed]);
ConnectedBuilder<G,R,V> conBuilder(aggregates, graph, visitedMap, row);
typedef typename G::VertexDescriptor Vertex;
typedef std::allocator<Vertex> Allocator;
typedef SLList<Vertex,Allocator> VertexList;
typedef typename AggregatesMap<Vertex>::DummyEdgeVisitor DummyVisitor;
VertexList vlist;
DummyVisitor dummy;
aggregates.template breadthFirstSearch<true,false>(seed,aggregates[seed], graph, vlist, dummy,
conBuilder, visitedMap);
}
template<class R, class G, class V>
void BaseConnectivityConstructor::constructOverlapConnectivity(R& row, G& graph, V& visitedMap,
const AggregatesMap<typename G::VertexDescriptor>& aggregates,
const OverlapVertex<typename G::VertexDescriptor>*& seed,
const OverlapVertex<typename G::VertexDescriptor>* overlapEnd)
{
ConnectedBuilder<G,R,V> conBuilder(aggregates, graph, visitedMap, row);
const typename G::VertexDescriptor aggregate=*seed->aggregate;
if (row.index()==*seed->aggregate) {
while(seed != overlapEnd && aggregate == *seed->aggregate) {
row.insert(*seed->aggregate);
// Walk over all neighbours and add them to the connected array.
visitNeighbours(graph, seed->vertex, conBuilder);
// Mark vertex as visited
put(visitedMap, seed->vertex, true);
++seed;
}
}
}
template<class G, class S, class V>
BaseConnectivityConstructor::ConnectedBuilder<G,S,V>::ConnectedBuilder(const AggregatesMap<Vertex>& aggregates,
Graph& graph, VisitedMap& visitedMap,
Set& connected)
: aggregates_(aggregates), graph_(graph), visitedMap_(visitedMap), connected_(connected)
{}
template<class G, class S, class V>
void BaseConnectivityConstructor::ConnectedBuilder<G,S,V>::operator()(const ConstEdgeIterator& edge)
{
const Vertex& vertex = aggregates_[edge.target()];
assert(vertex!= AggregatesMap<Vertex>::UNAGGREGATED);
if(vertex!= AggregatesMap<Vertex>::ISOLATED)
connected_.insert(vertex);
}
template<class T>
template<class G, class I, class Set>
const OverlapVertex<typename G::VertexDescriptor>*
GalerkinProduct<T>::buildOverlapVertices(const G& graph, const I& pinfo,
AggregatesMap<typename G::VertexDescriptor>& aggregates,
const Set& overlap,
std::size_t& overlapCount)
{
// count the overlap vertices.
typedef typename G::ConstVertexIterator ConstIterator;
typedef typename I::GlobalLookupIndexSet GlobalLookup;
typedef typename GlobalLookup::IndexPair IndexPair;
const ConstIterator end = graph.end();
overlapCount = 0;
const GlobalLookup& lookup=pinfo.globalLookup();
for(ConstIterator vertex=graph.begin(); vertex != end; ++vertex) {
const IndexPair* pair = lookup.pair(*vertex);
if(pair!=0 && overlap.contains(pair->local().attribute()))
++overlapCount;
}
// Allocate space
typedef typename G::VertexDescriptor Vertex;
OverlapVertex<Vertex>* overlapVertices = new OverlapVertex<Vertex>[overlapCount=0 ? 1 : overlapCount];
if(overlapCount==0)
return overlapVertices;
// Initialize them
overlapCount=0;
for(ConstIterator vertex=graph.begin(); vertex != end; ++vertex) {
const IndexPair* pair = lookup.pair(*vertex);
if(pair!=0 && overlap.contains(pair->local().attribute())) {
overlapVertices[overlapCount].aggregate = &aggregates[pair->local()];
overlapVertices[overlapCount].vertex = pair->local();
++overlapCount;
}
}
dverb << overlapCount<<" overlap vertices"<<std::endl;
std::sort(overlapVertices, overlapVertices+overlapCount, OVLess<Vertex>());
// due to the sorting the isolated aggregates (to be skipped) are at the end.
return overlapVertices;
}
template<class G, class T>
template<class V, class O, class R>
void ConnectivityConstructor<G,T>::examine(G& graph,
V& visitedMap,
const T& pinfo,
const AggregatesMap<Vertex>& aggregates,
const O& overlap,
const OverlapVertex<Vertex>* overlapVertices,
const OverlapVertex<Vertex>* overlapEnd,
R& row)
{
typedef typename T::GlobalLookupIndexSet GlobalLookup;
const GlobalLookup& lookup = pinfo.globalLookup();
typedef typename G::VertexIterator VertexIterator;
VertexIterator vend=graph.end();
#ifdef DUNE_ISTL_WITH_CHECKING
std::set<Vertex> examined;
#endif
// The aggregates owned by the process have lower local indices
// then those not owned. We process them in the first pass.
// They represent the rows 0, 1, ..., n of the coarse matrix
for(VertexIterator vertex = graph.begin(); vertex != vend; ++vertex)
if(!get(visitedMap, *vertex)) {
// In the first pass we only process owner nodes
typedef typename GlobalLookup::IndexPair IndexPair;
const IndexPair* pair = lookup.pair(*vertex);
if(pair==0 || !overlap.contains(pair->local().attribute())) {
#ifdef DUNE_ISTL_WITH_CHECKING
assert(examined.find(aggregates[*vertex])==examined.end());
examined.insert(aggregates[*vertex]);
#endif
constructNonOverlapConnectivity(row, graph, visitedMap, aggregates, *vertex);
// only needed for ALU
// (ghosts with same global id as owners on the same process)
if (SolverCategory::category(pinfo) == static_cast<int>(SolverCategory::nonoverlapping)) {
if(overlapVertices != overlapEnd) {
if(*overlapVertices->aggregate!=AggregatesMap<Vertex>::ISOLATED) {
constructOverlapConnectivity(row, graph, visitedMap, aggregates, overlapVertices, overlapEnd);
}
else{
++overlapVertices;
}
}
}
++row;
}
}
dvverb<<"constructed "<<row.index()<<" non-overlapping rows"<<std::endl;
// Now come the aggregates not owned by use.
// They represent the rows n+1, ..., N
while(overlapVertices != overlapEnd)
if(*overlapVertices->aggregate!=AggregatesMap<Vertex>::ISOLATED) {
#ifdef DUNE_ISTL_WITH_CHECKING
typedef typename GlobalLookup::IndexPair IndexPair;
const IndexPair* pair = lookup.pair(overlapVertices->vertex);
assert(pair!=0 && overlap.contains(pair->local().attribute()));
assert(examined.find(aggregates[overlapVertices->vertex])==examined.end());
examined.insert(aggregates[overlapVertices->vertex]);
#endif
constructOverlapConnectivity(row, graph, visitedMap, aggregates, overlapVertices, overlapEnd);
++row;
}else{
++overlapVertices;
}
}
template<class G>
template<class V, class R>
void ConnectivityConstructor<G,SequentialInformation>::examine(G& graph,
V& visitedMap,
[[maybe_unused]] const SequentialInformation& pinfo,
const AggregatesMap<Vertex>& aggregates,
R& row)
{
typedef typename G::VertexIterator VertexIterator;
VertexIterator vend=graph.end();
for(VertexIterator vertex = graph.begin(); vertex != vend; ++vertex) {
if(!get(visitedMap, *vertex)) {
constructNonOverlapConnectivity(row, graph, visitedMap, aggregates, *vertex);
++row;
}
}
}
template<class M>
SparsityBuilder<M>::SparsityBuilder(M& matrix)
: row_(matrix.createbegin()),
minRowSize_(std::numeric_limits<std::size_t>::max()),
maxRowSize_(0), sumRowSize_(0)
{
#ifdef DUNE_ISTL_WITH_CHECKING
diagonalInserted = false;
#endif
}
template<class M>
std::size_t SparsityBuilder<M>::maxRowSize()
{
return maxRowSize_;
}
template<class M>
std::size_t SparsityBuilder<M>::minRowSize()
{
return minRowSize_;
}
template<class M>
std::size_t SparsityBuilder<M>::sumRowSize()
{
return sumRowSize_;
}
template<class M>
void SparsityBuilder<M>::operator++()
{
sumRowSize_ += row_.size();
minRowSize_=std::min<std::size_t>(minRowSize_, row_.size());
maxRowSize_=std::max<std::size_t>(maxRowSize_, row_.size());
++row_;
#ifdef DUNE_ISTL_WITH_CHECKING
assert(diagonalInserted);
diagonalInserted = false;
#endif
}
template<class M>
void SparsityBuilder<M>::insert(const typename M::size_type& index)
{
row_.insert(index);
#ifdef DUNE_ISTL_WITH_CHECKING
diagonalInserted = diagonalInserted || row_.index()==index;
#endif
}
template<class T>
template<class G, class V, class Set>
typename G::MutableMatrix*
GalerkinProduct<T>::build(G& fineGraph, V& visitedMap,
const ParallelInformation& pinfo,
AggregatesMap<typename G::VertexDescriptor>& aggregates,
const typename G::Matrix::size_type& size,
const Set& overlap)
{
typedef OverlapVertex<typename G::VertexDescriptor> OverlapVertex;
std::size_t count;
const OverlapVertex* overlapVertices = buildOverlapVertices(fineGraph,
pinfo,
aggregates,
overlap,
count);
typedef typename G::MutableMatrix M;
M* coarseMatrix = new M(size, size, M::row_wise);
// Reset the visited flags of all vertices.
// As the isolated nodes will be skipped we simply mark them as visited
typedef typename G::VertexIterator Vertex;
Vertex vend = fineGraph.end();
for(Vertex vertex = fineGraph.begin(); vertex != vend; ++vertex) {
assert(aggregates[*vertex] != AggregatesMap<typename G::VertexDescriptor>::UNAGGREGATED);
put(visitedMap, *vertex, aggregates[*vertex]==AggregatesMap<typename G::VertexDescriptor>::ISOLATED);
}
typedef typename G::MutableMatrix M;
SparsityBuilder<M> sparsityBuilder(*coarseMatrix);
ConnectivityConstructor<G,T>::examine(fineGraph, visitedMap, pinfo,
aggregates, overlap,
overlapVertices,
overlapVertices+count,
sparsityBuilder);
dinfo<<pinfo.communicator().rank()<<": Matrix ("<<coarseMatrix->N()<<"x"<<coarseMatrix->M()<<" row: min="<<sparsityBuilder.minRowSize()<<" max="
<<sparsityBuilder.maxRowSize()<<" avg="
<<static_cast<double>(sparsityBuilder.sumRowSize())/coarseMatrix->N()
<<std::endl;
delete[] overlapVertices;
return coarseMatrix;
}
template<class G, class V, class Set>
typename G::MutableMatrix*
GalerkinProduct<SequentialInformation>::build(G& fineGraph, V& visitedMap,
const SequentialInformation& pinfo,
const AggregatesMap<typename G::VertexDescriptor>& aggregates,
const typename G::Matrix::size_type& size,
[[maybe_unused]] const Set& overlap)
{
typedef typename G::MutableMatrix M;
M* coarseMatrix = new M(size, size, M::row_wise);
// Reset the visited flags of all vertices.
// As the isolated nodes will be skipped we simply mark them as visited
typedef typename G::VertexIterator Vertex;
Vertex vend = fineGraph.end();
for(Vertex vertex = fineGraph.begin(); vertex != vend; ++vertex) {
assert(aggregates[*vertex] != AggregatesMap<typename G::VertexDescriptor>::UNAGGREGATED);
put(visitedMap, *vertex, aggregates[*vertex]==AggregatesMap<typename G::VertexDescriptor>::ISOLATED);
}
SparsityBuilder<M> sparsityBuilder(*coarseMatrix);
ConnectivityConstructor<G,SequentialInformation>::examine(fineGraph, visitedMap, pinfo,
aggregates, sparsityBuilder);
dinfo<<"Matrix row: min="<<sparsityBuilder.minRowSize()<<" max="
<<sparsityBuilder.maxRowSize()<<" average="
<<static_cast<double>(sparsityBuilder.sumRowSize())/coarseMatrix->N()<<std::endl;
return coarseMatrix;
}
template<class M, class V, class P, class O>
void BaseGalerkinProduct::calculate(const M& fine, const AggregatesMap<V>& aggregates, M& coarse,
const P& pinfo, [[maybe_unused]] const O& copy)
{
coarse = static_cast<typename M::field_type>(0);
typedef typename M::ConstIterator RowIterator;
RowIterator endRow = fine.end();
for(RowIterator row = fine.begin(); row != endRow; ++row)
if(aggregates[row.index()] != AggregatesMap<V>::ISOLATED) {
assert(aggregates[row.index()]!=AggregatesMap<V>::UNAGGREGATED);
typedef typename M::ConstColIterator ColIterator;
ColIterator endCol = row->end();
for(ColIterator col = row->begin(); col != endCol; ++col)
if(aggregates[col.index()] != AggregatesMap<V>::ISOLATED) {
assert(aggregates[row.index()]!=AggregatesMap<V>::UNAGGREGATED);
coarse[aggregates[row.index()]][aggregates[col.index()]]+=*col;
}
}
// get the right diagonal matrix values on copy lines from owner processes
typedef typename M::block_type BlockType;
std::vector<BlockType> rowsize(coarse.N(),BlockType(0));
for (RowIterator row = coarse.begin(); row != coarse.end(); ++row)
rowsize[row.index()]=coarse[row.index()][row.index()];
pinfo.copyOwnerToAll(rowsize,rowsize);
for (RowIterator row = coarse.begin(); row != coarse.end(); ++row)
coarse[row.index()][row.index()] = rowsize[row.index()];
// don't set dirichlet boundaries for copy lines to make novlp case work,
// the preconditioner yields slightly different results now.
// Set the dirichlet border
//DirichletBoundarySetter<P>::template set<M>(coarse, pinfo, copy);
}
template<class T>
template<class M, class O>
void DirichletBoundarySetter<T>::set(M& coarse, const T& pinfo, const O& copy)
{
typedef typename T::ParallelIndexSet::const_iterator ConstIterator;
ConstIterator end = pinfo.indexSet().end();
typedef typename M::block_type Block;
Block identity=Block(0.0);
for(typename Block::RowIterator b=identity.begin(); b != identity.end(); ++b)
b->operator[](b.index())=1.0;
for(ConstIterator index = pinfo.indexSet().begin();
index != end; ++index) {
if(copy.contains(index->local().attribute())) {
typedef typename M::ColIterator ColIterator;
typedef typename M::row_type Row;
Row row = coarse[index->local()];
ColIterator cend = row.find(index->local());
ColIterator col = row.begin();
for(; col != cend; ++col)
*col = 0;
cend = row.end();
assert(col != cend); // There should be a diagonal entry
*col = identity;
for(++col; col != cend; ++col)
*col = 0;
}
}
}
template<class M, class O>
void DirichletBoundarySetter<SequentialInformation>::set(M& coarse,
const SequentialInformation& pinfo,
const O& overlap)
{}
} // namespace Amg
} // namespace Dune
#endif
pinfo.hh
aggregates.hh
Provides classes for the Coloring process of AMG.
Dune::Amg::GalerkinProduct::OVLess::operator()
bool operator()(const OverlapVertex< A > &o1, const OverlapVertex< A > &o2)
Definition galerkin.hh:155
Dune::Amg::BaseConnectivityConstructor::constructNonOverlapConnectivity
static void constructNonOverlapConnectivity(R &row, G &graph, V &visitedMap, const AggregatesMap< typename G::VertexDescriptor > &aggregates, const typename G::VertexDescriptor &seed)
Construct the connectivity of an aggregate in the overlap.
Definition galerkin.hh:313
Dune::Amg::BaseConnectivityConstructor::ConnectedBuilder::Graph
G Graph
The type of the graph.
Definition galerkin.hh:211
Dune::Amg::SparsityBuilder::operator++
void operator++()
Definition galerkin.hh:539
Dune::Amg::BaseConnectivityConstructor::ConnectedBuilder::operator()
void operator()(const ConstEdgeIterator &edge)
Process an edge pointing to another aggregate.
Definition galerkin.hh:359
Dune::Amg::SparsityBuilder::insert
void insert(const typename M::size_type &index)
Definition galerkin.hh:552
Dune::Amg::BaseConnectivityConstructor::constructOverlapConnectivity
static void constructOverlapConnectivity(R &row, G &graph, V &visitedMap, const AggregatesMap< typename G::VertexDescriptor > &aggregates, const OverlapVertex< typename G::VertexDescriptor > *&seed, const OverlapVertex< typename G::VertexDescriptor > *overlapEnd)
Definition galerkin.hh:331
Dune::Amg::GalerkinProduct::build
G::MutableMatrix * build(G &fineGraph, V &visitedMap, const ParallelInformation &pinfo, AggregatesMap< typename G::VertexDescriptor > &aggregates, const typename G::Matrix::size_type &size, const Set &copy)
Calculates the coarse matrix via a Galerkin product.
Definition galerkin.hh:563
Dune::Amg::SparsityBuilder::index
std::size_t index()
Definition galerkin.hh:81
Dune::Amg::GalerkinProduct::ParallelInformation
T ParallelInformation
Definition galerkin.hh:120
Dune::Amg::ConnectivityConstructor::Vertex
G::VertexDescriptor Vertex
Definition galerkin.hh:272
Dune::Amg::OverlapVertex::Aggregate
T Aggregate
The aggregate descriptor.
Definition galerkin.hh:37
Dune::Amg::SparsityBuilder::SparsityBuilder
SparsityBuilder(M &matrix)
Constructor.
Definition galerkin.hh:513
Dune::Amg::BaseConnectivityConstructor::ConnectedBuilder::ConnectedBuilder
ConnectedBuilder(const AggregatesMap< Vertex > &aggregates, Graph &graph, VisitedMap &visitedMap, Set &connected)
Constructor.
Definition galerkin.hh:352
Dune::Amg::BaseConnectivityConstructor::ConnectedBuilder::ConstEdgeIterator
Graph::ConstEdgeIterator ConstEdgeIterator
The constant edge iterator.
Definition galerkin.hh:215
Dune::Amg::OverlapVertex::Vertex
T Vertex
The vertex descriptor.
Definition galerkin.hh:42
Dune::Amg::ConnectivityConstructor< G, SequentialInformation >::Vertex
G::VertexDescriptor Vertex
Definition galerkin.hh:288
Dune::Amg::ConnectivityConstructor::examine
static void examine(G &graph, V &visitedMap, const T &pinfo, const AggregatesMap< Vertex > &aggregates, const O &overlap, const OverlapVertex< Vertex > *overlapVertices, const OverlapVertex< Vertex > *overlapEnd, R &row)
Definition galerkin.hh:420
Dune::Amg::BaseConnectivityConstructor::ConnectedBuilder::VisitedMap
V VisitedMap
The type of the map for marking vertices as visited.
Definition galerkin.hh:225
Dune::Amg::visitNeighbours
int visitNeighbours(const G &graph, const typename G::VertexDescriptor &vertex, V &visitor)
Visit all neighbour vertices of a vertex in a graph.
Dune::Amg::AggregatesMap::ISOLATED
static const V ISOLATED
Identifier of isolated vertices.
Definition aggregates.hh:577
Dune::Amg::BaseConnectivityConstructor::ConnectedBuilder::Set
S Set
The type of the connected set.
Definition galerkin.hh:220
Dune::Amg::OverlapVertex::aggregate
Aggregate * aggregate
The aggregate the vertex belongs to.
Definition galerkin.hh:47
Dune::Amg::SparsityBuilder::sumRowSize
std::size_t sumRowSize()
Definition galerkin.hh:534
Dune::Amg::OverlapVertex::vertex
Vertex vertex
The vertex descriptor.
Definition galerkin.hh:52
Dune::Amg::SparsityBuilder::minRowSize
std::size_t minRowSize()
Definition galerkin.hh:528
Dune::Amg::DirichletBoundarySetter::set
static void set(M &coarse, const T &pinfo, const O &copy)
Definition galerkin.hh:682
Dune::Amg::AggregatesMap::UNAGGREGATED
static const V UNAGGREGATED
Identifier of not yet aggregated vertices.
Definition aggregates.hh:572
Dune::Amg::BaseConnectivityConstructor::ConnectedBuilder::Vertex
Graph::VertexDescriptor Vertex
The vertex descriptor of the graph.
Definition galerkin.hh:230
Dune::Amg::BaseGalerkinProduct::calculate
void calculate(const M &fine, const AggregatesMap< V > &aggregates, M &coarse, const I &pinfo, const O &copy)
Calculate the galerkin product.
Dune::Amg::SparsityBuilder::maxRowSize
std::size_t maxRowSize()
Definition galerkin.hh:523
std
STL namespace.
Dune
Definition allocator.hh:11
Dune::get
PropertyMapTypeSelector< Amg::VertexVisitedTag, Amg::PropertiesGraph< G, Amg::VertexProperties, EP, VM, EM > >::Type get(const Amg::VertexVisitedTag &tag, Amg::PropertiesGraph< G, Amg::VertexProperties, EP, VM, EM > &graph)
Definition dependency.hh:293
Dune::col
MatrixSparsityPatternGatherScatter< M, I >::ColIter MatrixSparsityPatternGatherScatter< M, I >::col
Definition matrixredistribute.hh:591
Dune::Amg
Definition novlpschwarz.hh:256
Dune::Amg::AggregatesMap
Class providing information about the mapping of the vertices onto aggregates.
Definition aggregates.hh:566
Dune::Amg::AggregatesMap::DummyEdgeVisitor
A Dummy visitor that does nothing for each visited edge.
Definition aggregates.hh:604
Dune::Amg::OverlapVertex
Definition galerkin.hh:33
Dune::Amg::SparsityBuilder
Functor for building the sparsity pattern of the matrix using examineConnectivity.
Definition galerkin.hh:63
Dune::Amg::BaseGalerkinProduct
Definition galerkin.hh:99
Dune::Amg::GalerkinProduct
Definition galerkin.hh:118
Dune::Amg::BaseConnectivityConstructor
Definition galerkin.hh:185
Dune::Amg::BaseConnectivityConstructor::ConnectedBuilder
Visitor for identifying connected aggregates during a breadthFirstSearch.
Definition galerkin.hh:206
Dune::Amg::ConnectivityConstructor
Definition galerkin.hh:271
Dune::Amg::DirichletBoundarySetter
Definition galerkin.hh:300
Dune::Amg::SequentialInformation
Definition pinfo.hh:28
Dune::SolverCategory::nonoverlapping
@ nonoverlapping
Category for non-overlapping solvers.
Definition solvercategory.hh:27
Dune::SolverCategory::category
static Category category(const OP &op, decltype(op.category()) *=nullptr)
Helperfunction to extract the solver category either from an enum, or from the newly introduced virtu...
Definition solvercategory.hh:34