50 #ifndef _ZOLTAN2_ORDERINGSOLUTION_HPP_ 51 #define _ZOLTAN2_ORDERINGSOLUTION_HPP_ 70 template <
typename lno_t,
typename gno_t>
131 std::cerr <<
"No inverse!" << std::endl;
147 std::cerr <<
"No perm!" << std::endl;
182 return const_cast<ArrayRCP<gno_t>&
> (
gids_);
193 return const_cast<ArrayRCP<lno_t>&
> (
invperm_);
195 return const_cast<ArrayRCP<lno_t>&
> (
perm_);
202 return gids_.getRawPtr();
215 return perm_.getRawPtr();
Defines the Solution base class.
size_t getPermutationSize()
Get (local) size of permutation.
void setHavePerm(bool status)
Set havePerm (intended for ordering algorithms only)
Just a placeholder for now.
void computeInverse()
Compute inverse permutation.
bool havePerm()
Do we have the direct permutation?
OrderingSolution(size_t perm_size)
Constructor allocates memory for the solution.
ArrayRCP< gno_t > & getGidsRCP()
Get (local) permuted GIDs by RCP.
ArrayRCP< lno_t > & getPermutationRCPConst(bool inverse=false) const
Get (local) permutation by const RCP. If inverse = true, return inverse permutation. By default, perm[i] is where new index i can be found in the old ordering. When inverse==true, perm[i] is where old index i can be found in the new ordering.
ArrayRCP< lno_t > & getPermutationRCP(bool inverse=false)
Get (local) permutation by RCP. If inverse = true, return inverse permutation. By default...
ArrayRCP< gno_t > & getGidsRCPConst() const
Get (local) permuted GIDs by const RCP.
bool haveInverse()
Do we have the inverse permutation?
void computePerm()
Compute direct permutation from inverse.
ArrayRCP< lno_t > invperm_
gno_t * getGids()
Get pointer to (local) GIDs.
lno_t * getPermutation(bool inverse=false)
Get pointer to (local) permutation. If inverse = true, return inverse permutation. By default, perm[i] is where new index i can be found in the old ordering. When inverse==true, perm[i] is where old index i can be found in the new ordering.
Gathering definitions used in software development.
void setHaveInverse(bool status)
Set haveInverse (intended for ordering algorithms only)
The class containing ordering solutions.