Reference documentation for deal.II version 9.2.0
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
Public Member Functions | Protected Attributes | List of all members
Utilities::MPI::ConsensusAlgorithms::Interface< T1, T2 > Class Template Referenceabstract

#include <deal.II/base/mpi_consensus_algorithms.h>

Inheritance diagram for Utilities::MPI::ConsensusAlgorithms::Interface< T1, T2 >:
[legend]

Public Member Functions

 Interface (Process< T1, T2 > &process, const MPI_Comm &comm)
 
virtual ~Interface ()=default
 
virtual void run ()=0
 

Protected Attributes

Process< T1, T2 > & process
 
const MPI_Commcomm
 
const unsigned int my_rank
 
const unsigned int n_procs
 

Detailed Description

template<typename T1, typename T2>
class Utilities::MPI::ConsensusAlgorithms::Interface< T1, T2 >

A base class for algorithms that implement the task of coming up with communication patterns to retrieve data from other processes in a dynamic-sparse way. In computer science, this is often called a consensus problem.

Dynamic-sparse means in this context:

Naturally, the user has to provide:

This base class only introduces a basic interface to achieve these goals, while derived classes implement different algorithms to actually compute such communication patterns. The last two features of the list above this paragraph are implemented in classes derived from ConsensusAlgorithm::Process.

Template Parameters
T1The type of the elements of the vector to be sent.
T2The type of the elements of the vector to be received.
Author
Peter Munch, 2019

Definition at line 170 of file mpi_consensus_algorithms.h.

Constructor & Destructor Documentation

◆ Interface()

template<typename T1 , typename T2 >
Utilities::MPI::ConsensusAlgorithms::Interface< T1, T2 >::Interface ( Process< T1, T2 > &  process,
const MPI_Comm comm 
)

◆ ~Interface()

template<typename T1 , typename T2 >
virtual Utilities::MPI::ConsensusAlgorithms::Interface< T1, T2 >::~Interface ( )
virtualdefault

Destructor.

Member Function Documentation

◆ run()

template<typename T1 , typename T2 >
virtual void Utilities::MPI::ConsensusAlgorithms::Interface< T1, T2 >::run ( )
pure virtual

Member Data Documentation

◆ process

template<typename T1 , typename T2 >
Process<T1, T2>& Utilities::MPI::ConsensusAlgorithms::Interface< T1, T2 >::process
protected

Reference to the process provided by the user.

Definition at line 190 of file mpi_consensus_algorithms.h.

◆ comm

template<typename T1 , typename T2 >
const MPI_Comm& Utilities::MPI::ConsensusAlgorithms::Interface< T1, T2 >::comm
protected

MPI communicator.

Definition at line 195 of file mpi_consensus_algorithms.h.

◆ my_rank

template<typename T1 , typename T2 >
const unsigned int Utilities::MPI::ConsensusAlgorithms::Interface< T1, T2 >::my_rank
protected

Rank of this process.

Definition at line 200 of file mpi_consensus_algorithms.h.

◆ n_procs

template<typename T1 , typename T2 >
const unsigned int Utilities::MPI::ConsensusAlgorithms::Interface< T1, T2 >::n_procs
protected

Number of processes in the communicator.

Definition at line 205 of file mpi_consensus_algorithms.h.


The documentation for this class was generated from the following file: