Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
MEDCoupling::ExplicitCoincidentDEC Class Reference
Inheritance diagram for MEDCoupling::ExplicitCoincidentDEC:
Collaboration diagram for MEDCoupling::ExplicitCoincidentDEC:

Public Member Functions

void broadcastTopology (BlockTopology *&, int tag)
 
void broadcastTopology (const ExplicitTopology *toposend, ExplicitTopology *toporecv, int tag)
 
 ExplicitCoincidentDEC ()
 
void prepareSourceDE ()
 
void prepareTargetDE ()
 
void recvData ()
 
void sendData ()
 
void synchronize ()
 
void transferMappingToSource ()
 
virtual ~ExplicitCoincidentDEC ()
 
- Public Member Functions inherited from MEDCoupling::DisjointDEC
void attachLocalField (MEDCouplingFieldDouble *field)
 
void attachLocalField (const ParaFIELD *field, bool ownPt=false)
 
void attachLocalField (const ICoCo::MEDField *field)
 
virtual void computeProcGroup ()
 
 DisjointDEC ()
 
 DisjointDEC (ProcessorGroup &source_group, ProcessorGroup &target_group)
 
 DisjointDEC (const DisjointDEC &)
 
 DisjointDEC (const std::set< int > &src_ids, const std::set< int > &trg_ids, const MPI_Comm &world_comm=MPI_COMM_WORLD)
 
ProcessorGroupgetSourceGrp () const
 
ProcessorGroupgetTargetGrp () const
 
bool isInSourceSide () const
 
bool isInTargetSide () const
 
bool isInUnion () const
 
DisjointDECoperator= (const DisjointDEC &s)
 
void renormalizeTargetField (bool isWAbs)
 
void sendRecvData (bool way=true)
 
void setNature (NatureOfField nature)
 
virtual ~DisjointDEC ()
 
- Public Member Functions inherited from MEDCoupling::DEC
void copyFrom (const DEC &other)
 
 DEC ()
 
virtual ~DEC ()
 
- Public Member Functions inherited from MEDCoupling::DECOptions
 DECOptions ()
 
 DECOptions (const DECOptions &deco)
 
AllToAllMethod getAllToAllMethod () const
 
bool getAsynchronous () const
 
bool getForcedRenormalization () const
 
const std::string & getMethod () const
 
TimeInterpolationMethod getTimeInterpolationMethod () const
 
void setAllToAllMethod (AllToAllMethod sp)
 
void setAsynchronous (bool dr)
 
void setForcedRenormalization (bool dr)
 
void setMethod (const char *m)
 
void setTimeInterpolationMethod (TimeInterpolationMethod it)
 

Additional Inherited Members

- Protected Member Functions inherited from MEDCoupling::DisjointDEC
void checkPartitionGroup () const
 
void cleanInstance ()
 
void compareFieldAndMethod () const throw (INTERP_KERNEL::Exception)
 
void copyInstance (const DisjointDEC &other)
 
- Protected Attributes inherited from MEDCoupling::DisjointDEC
const CommInterface_comm_interface
 
const ParaFIELD_local_field
 
bool _owns_field
 
bool _owns_groups
 
ProcessorGroup_source_group
 
ProcessorGroup_target_group
 
MPI_Comm _union_comm
 
ProcessorGroup_union_group
 

Detailed Description

This class aims at remapping fields that have identical supports (=the same underlying mesh) but different parallel topologies (=different sub-domains in the mesh). It can be used to couple together multi-physics codes that operate on the same domain with different partitioning.

It is very similar to what the StructuredCoincidentDEC does, except that it works with an arbitrary user-defined topology.

The remapping between the two supports is based on identity of global ids, instead of geometrical considerations (as it is the case for InterpKernelDEC). Therefore, beware that this DEC can not be used for coincident meshes if they do not have the exact same numbering.

With this DEC no projection, and no interpolation of the field data is done, contrary to what happens in InterpKernelDEC. It is just a matter of allocating the values from one side to the other, using directly the cell identifiers.

As all the other DECs, its usage requires two phases :

  • a setup phase during which the topologies are exchanged so that the target side knows from which processors it should expect the data.
  • a send/recv phase during which the field data is actually transferred.

This example illustrates the sending of a field with the ExplicitCoincidentDEC :

...
ExplicitCoincidentDEC dec(groupA, groupB);
dec.attachLocalField(field);
dec.synchronize();
if (groupA.containsMyRank())
dec.recvData();
else if (groupB.containsMyRank())
dec.sendData();
...

Creating a ParaFIELD to be attached to the DEC is done in exactly the same way as for the other DECs, if only the partitioning of the support mesh differs. In the case where the fields have also different component topologies, creating the ParaFIELD requires some more effort. See the parallelism section for more details.

Constructor & Destructor Documentation

MEDCoupling::ExplicitCoincidentDEC::ExplicitCoincidentDEC ( )

Constructor

MEDCoupling::ExplicitCoincidentDEC::~ExplicitCoincidentDEC ( )
virtual

Member Function Documentation

void MEDCoupling::ExplicitCoincidentDEC::broadcastTopology ( BlockTopology *&  ,
int  tag 
)

Referenced by synchronize().

void MEDCoupling::ExplicitCoincidentDEC::broadcastTopology ( const ExplicitTopology toposend,
ExplicitTopology toporecv,
int  tag 
)
void MEDCoupling::ExplicitCoincidentDEC::sendData ( )
virtual