![]() |
MFEM v4.8.0
Finite element discretization library
|
Class for gather-scatter (gs) operations on Vectors based on corresponding global identifiers. More...
#include <gslib.hpp>
Public Types | |
enum | GSOp { ADD , MUL , MIN , MAX } |
Supported operation types. See class description. More... | |
Public Member Functions | |
GSOPGSLIB (Array< long long > &ids) | |
GSOPGSLIB (MPI_Comm comm_, Array< long long > &ids) | |
virtual | ~GSOPGSLIB () |
void | UpdateIdentifiers (const Array< long long > &ids) |
void | GS (Vector &senddata, GSOp op) |
Protected Attributes | |
struct gslib::crystal * | cr |
struct gslib::comm * | gsl_comm |
struct gslib::gs_data * | gsl_data = NULL |
int | num_ids |
Class for gather-scatter (gs) operations on Vectors based on corresponding global identifiers.
This functionality is useful for gs-ops on DOF values across processor boundary, where the global identifier would be the corresponding true DOF index. Operations currently supported are min, max, sum, and multiplication. Note: identifier 0 does not participate in the gather-scatter operation and a given identifier can be included multiple times on a given rank. For example, consider a vector, v:
Consider a corresponding Array<int>, a:
A gather-scatter "minimum" operation, done as follows: GSOPGSLIB gs = GSOPGSLIB(MPI_COMM_WORLD, a); gs.GS(v, GSOp::MIN); would return into v:
mfem::GSOPGSLIB::GSOPGSLIB | ( | MPI_Comm | comm_, |
Array< long long > & | ids ) |
void mfem::GSOPGSLIB::UpdateIdentifiers | ( | const Array< long long > & | ids | ) |
|
protected |