FlexELA
Loading...
Searching...
No Matches
Public Member Functions | List of all members
domain::MPIDomain Class Reference

An extension of Domain for parallelization with MPI. More...

#include <mpidomain.h>

Inheritance diagram for domain::MPIDomain:
domain::Domain

Public Member Functions

 MPIDomain (const int &ni, const int &nj, const int &nk, const int &nn, MPI_Comm comm_cart)
 Construct a new MPIDomain object.
 
constexpr bool hasNeighbor (Face f) const
 Determine if there is a neighboring domain on the Face f.
 
constexpr bool isBoss () const
 Check if this process is the boss (rank is 0)
 
void updateGhost (const Face &recv)
 Update the ghost cell adjacent to Face recv.
 
template<class T >
getMax (const T &in) const
 Get the maximum value across all domains.
 
MPI_Comm getMPIComm () const
 Get the MPI communicator.
 
- Public Member Functions inherited from domain::Domain
 Domain (const int &ni, const int &nj, const int &nk, const int &nn)
 Construct a new Domain object.
 
fields::Helper< svec::SVectorgetGhost (const Face &f, const int &n)
 From s [n], returns ghost cells immediately adjacent to Face f.
 
fields::Helper< svec::SVectorgetEdge (const Face &f, const int &n)
 From s [n], returns cells in the domain immediately adjacent to Face f.
 
constexpr bool hasNeighbor (Face f) const
 Determine if there is a neighboring domain on the Face f.
 
template<class T >
getMax (const T &in) const
 Get the maximum value across all domains.
 

Additional Inherited Members

- Public Attributes inherited from domain::Domain
const int n [3]
 Storage for ni, nj, and nk.
 
const int & ni = n[0]
 Number of (non-ghost) cells in first direction.
 
const int & nj = n[1]
 Number of (non-ghost) cells in second direction.
 
const int & nk = n[2]
 Number of (non-ghost) cells in third direction.
 
const int nn
 Number of ELA instances.
 
std::vector< fields::Owner< svec::SVector > > s
 Source vector field.
 
std::vector< fields::Owner< svec::NormalizedSVector > > c
 Vector dilation field.
 

Detailed Description

An extension of Domain for parallelization with MPI.

Constructor & Destructor Documentation

◆ MPIDomain()

domain::MPIDomain::MPIDomain ( const int &  ni,
const int &  nj,
const int &  nk,
const int &  nn,
MPI_Comm  comm_cart 
)

Construct a new MPIDomain object.

See also
Domain()
Parameters
nini
njnj
nknk
nnnn
comm_cartMPI Cartesian Communicator

Member Function Documentation

◆ hasNeighbor()

constexpr bool domain::MPIDomain::hasNeighbor ( Face  f) const
constexpr

Determine if there is a neighboring domain on the Face f.

Unlike Domain::hasNeighbor(), the return value here depends on comm_cart provided in MPIDomain()

Parameters
f

◆ updateGhost()

void domain::MPIDomain::updateGhost ( const Face recv)

Update the ghost cell adjacent to Face recv.

  • This will do nothing to the ghost cells if hasNeighbor() is false for recv
  • All processes must call this, as the current processes may have to send data regardless of whether or not it is receiving data.
Parameters
recv

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