Zoltan2 Version of the Day
Classes | Namespaces | Enumerations | Functions
Zoltan2_AlgRCB_methods.hpp File Reference

Methods written for the RCB algorithm. More...

#include <Zoltan2_PartitioningSolution.hpp>
#include <Zoltan2_XpetraTraits.hpp>
#include <Zoltan2_Metric.hpp>
#include <Tpetra_Vector.hpp>
#include <sstream>
#include <string>
#include <cmath>
#include <bitset>
Include dependency graph for Zoltan2_AlgRCB_methods.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  Teuchos::Zoltan2_RCBOperation< Ordinal, T >
 A Teuchos::MPIComm reduction operation. More...

Namespaces

namespace  Teuchos
namespace  Zoltan2

Enumerations

enum  Zoltan2::rcbParams {
  Zoltan2::rcb_balanceCount, Zoltan2::rcb_balanceWeight, Zoltan2::rcb_minTotalWeight, Zoltan2::rcb_minMaximumWeight,
  Zoltan2::rcb_balanceTotalMaximum, Zoltan2::rcb_averageCuts, Zoltan2::rcb_rectilinearBlocks, Zoltan2::rcb_multiplePartSizeSpecs,
  Zoltan2::NUM_RCB_PARAMS
}
 The boolean parameters of interest to the RCB algorithm. More...
enum  Zoltan2::leftRightFlag { Zoltan2::unsetFlag = 0xfd, Zoltan2::leftFlag = 0xfe, Zoltan2::rightFlag = 0xff }
 During partitioning, flags are stored in unsigned char arrays. More...

Functions

template<typename Adapter >
void Zoltan2::getFractionLeft (const RCP< const Environment > &env, partId_t part0, partId_t part1, const RCP< PartitioningSolution< Adapter > > &solution, ArrayRCP< double > &fractionLeft, partId_t &numPartsLeftHalf)
 Determine the fraction of work in the left half.
template<typename mvector_t >
void Zoltan2::getCutDimension (const RCP< const Environment > &env, const RCP< Comm< int > > &comm, int coordDim, const RCP< mvector_t > &vectors, ArrayView< typename mvector_t::local_ordinal_type > index, int &dimension, typename mvector_t::scalar_type &minCoord, typename mvector_t::scalar_type &maxCoord)
 Choose a coordinate dimension for the next cut.
template<typename mvector_t >
void Zoltan2::migrateData (const RCP< const Environment > &env, const RCP< Comm< int > > &comm, ArrayView< unsigned char > lrflags, RCP< mvector_t > &vectors, int &leftNumProcs)
 Migrate coordinates and weights to new processes.
template<typename lno_t , typename scalar_t >
scalar_t Zoltan2::getCoordWeight (lno_t id, multiCriteriaNorm mcnorm, ArrayView< StridedData< lno_t, scalar_t > > weights)
template<typename scalar_t >
bool Zoltan2::emptyPartsCheck (const RCP< const Environment > &env, const ArrayView< double > fractionLeft, scalar_t minCoord, scalar_t maxCoord, leftRightFlag &lrf, scalar_t &cutValue)
 Solve partitioning if there are empty parts.
template<typename lno_t , typename gno_t , typename scalar_t >
void Zoltan2::testCoordinatesOnRightBoundary (const RCP< const Environment > &env, const RCP< Comm< int > > &comm, scalar_t totalWeightLeft, scalar_t targetLeftScalar, int cutLocation, ArrayView< scalar_t > localSums, ArrayView< scalar_t > globalSums, ArrayView< lno_t > index, ArrayView< StridedData< lno_t, scalar_t > > weights, multiCriteriaNorm mcnorm, ArrayView< unsigned char > lrFlags, scalar_t &globalWeightMovedRight)
 Move boundary coordinates to the right.
template<typename mvector_t >
void Zoltan2::BSPfindCut (const RCP< const Environment > &env, const RCP< Comm< int > > &comm, const std::bitset< NUM_RCB_PARAMS > &params, int numTestCuts, typename mvector_t::scalar_type tolerance, int cutDim, int coordDim, const RCP< mvector_t > &vectors, ArrayView< typename mvector_t::local_ordinal_type > index, ArrayView< double > fractionLeft, ArrayView< bool > uniformWeights, typename mvector_t::scalar_type coordGlobalMin, typename mvector_t::scalar_type coordGlobalMax, typename mvector_t::scalar_type &cutValue, ArrayView< unsigned char > lrFlags, typename mvector_t::scalar_type &totalWeightLeft, typename mvector_t::scalar_type &totalWeightRight, typename mvector_t::local_ordinal_type &localCountLeft, typename mvector_t::scalar_type &imbalance)
 Find the point in space that divides the data evenly with respect to the weights, part sizes, and the user's objective.
template<typename mvector_t , typename Adapter >
void Zoltan2::determineCut (const RCP< const Environment > &env, const RCP< Comm< int > > &comm, const std::bitset< NUM_RCB_PARAMS > &params, int numTestCuts, typename mvector_t::scalar_type tolerance, int coordDim, const RCP< mvector_t > &vectors, const ArrayView< bool > uniformWeights, multiCriteriaNorm mcnorm, const RCP< PartitioningSolution< Adapter > > &solution, partId_t part0, partId_t part1, ArrayView< unsigned char > lrflags, int &cutDimension, typename mvector_t::scalar_type &cutValue, typename mvector_t::scalar_type &imbalance, partId_t &numPartsLeftHalf, typename mvector_t::scalar_type &weightLeftHalf, typename mvector_t::scalar_type &weightRightHalf)
 Divide the coordinates into a "left" half and "right" half.
template<typename mvector_t , typename Adapter >
void Zoltan2::serialRCB (const RCP< const Environment > &env, int depth, const std::bitset< NUM_RCB_PARAMS > &params, int numTestCuts, typename mvector_t::scalar_type tolerance, int coordDim, const RCP< mvector_t > &vectors, ArrayView< typename mvector_t::local_ordinal_type > index, const ArrayView< bool > uniformWeights, const RCP< PartitioningSolution< Adapter > > &solution, partId_t part0, partId_t part1, ArrayView< partId_t > partNum)
 Perform RCB on the local process only.

Detailed Description

Methods written for the RCB algorithm.

Definition in file Zoltan2_AlgRCB_methods.hpp.