Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members

Isorropia::CostDescriber Class Reference

Interface (abstract base class) for describing the weights/costs associated with the vertices and/or edges of the object to be repartitioned and redistributed. More...

#include <Isorropia_CostDescriber.hpp>

Inheritance diagram for Isorropia::CostDescriber:

[legend]
List of all members.

Public Member Functions

virtual ~CostDescriber ()
 Destructor.
virtual void setParameters (const Teuchos::ParameterList &paramlist)=0
 Set parameters for the CostDescriber instance.
virtual bool haveVertexWeights () const =0
 Query whether non-default vertex weights are present.
virtual int getNumVertices () const =0
 Get the number of vertices.
virtual void getVertexWeights (int numVertices, int *global_ids, float *weights) const =0
 Get the lists of vertex ids and weights.
virtual bool haveGraphEdgeWeights () const =0
 Query whether non-default graph edge weights are present.
virtual int getNumGraphEdges (int vertex_global_id) const =0
 Get the number of graph edges for a specified vertex.
virtual void getGraphEdgeWeights (int vertex_global_id, int num_neighbors, int *neighbor_global_ids, float *weights) const =0
 Get the graph edge weights for a specified vertex.
virtual bool haveHypergraphEdgeWeights () const =0
 Query whether non-default hypergraph edge weights are present.
virtual int getNumHypergraphEdges () const =0
 Get the number of Hypergraph edges.
virtual void getHypergraphEdgeWeights (int numEdges, int *global_ids, float *weights) const =0
 Get the hypergraph edge weights.

Detailed Description

Interface (abstract base class) for describing the weights/costs associated with the vertices and/or edges of the object to be repartitioned and redistributed.

This interface is intended to be queried by the partitioner.

In many cases, a user may provide some weights but not others. E.g., they may provide vertex weights but not edge weights, etc. Any weights which are not provided are assumed to have a default value of 1.0. The caller which needs the weights (i.e., the partitioner) can save time/work by querying whether "non-default" weights are specified, and if not, then simply use weights of 1.0 rather than making the call to obtain the weights arrays. The queries for whether weights are provided are the methods haveVertexWeights(), haveGraphEdgeWeights() and haveHypergraphEdgeWeights().


Member Function Documentation

virtual void Isorropia::CostDescriber::setParameters const Teuchos::ParameterList &  paramlist  )  [pure virtual]
 

Set parameters for the CostDescriber instance.

The contents of the input paramlist object are copied into an internal ParameterList attribute. Instances of this interface should not retain a reference to the input ParameterList after this method returns.

Implemented in Isorropia::Epetra::CostDescriber.

virtual bool Isorropia::CostDescriber::haveVertexWeights  )  const [pure virtual]
 

Query whether non-default vertex weights are present.

If this function returns false, the caller can assume that vertex weights are all 1.0.

Implemented in Isorropia::Epetra::CostDescriber.

virtual int Isorropia::CostDescriber::getNumVertices  )  const [pure virtual]
 

Get the number of vertices.

Vertices typically correspond to matrix rows.

Implemented in Isorropia::Epetra::CostDescriber.

virtual bool Isorropia::CostDescriber::haveGraphEdgeWeights  )  const [pure virtual]
 

Query whether non-default graph edge weights are present.

If this function returns false, the caller can assume that graph edge weights are all 1.0.

Implemented in Isorropia::Epetra::CostDescriber.

virtual int Isorropia::CostDescriber::getNumGraphEdges int  vertex_global_id  )  const [pure virtual]
 

Get the number of graph edges for a specified vertex.

Graph edges typically correspond to matrix nonzeros.

Implemented in Isorropia::Epetra::CostDescriber.

virtual bool Isorropia::CostDescriber::haveHypergraphEdgeWeights  )  const [pure virtual]
 

Query whether non-default hypergraph edge weights are present.

If this function returns false, the caller can assume that hypergraph edge weights are all 1.0.

Implemented in Isorropia::Epetra::CostDescriber.

virtual int Isorropia::CostDescriber::getNumHypergraphEdges  )  const [pure virtual]
 

Get the number of Hypergraph edges.

Hypergraph edges typically correspond to matrix columns.

Implemented in Isorropia::Epetra::CostDescriber.


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