Isorropia: Partitioning, Load Balancing and more
|
Interface (abstract base class) for computing a new coloring and describing the result. More...
#include <Isorropia_Colorer.hpp>
Public Member Functions | |
virtual | ~Colorer () |
Destructor. More... | |
virtual void | color (bool forceColoring=false)=0 |
Method which does the work of computing a new coloring. More... | |
virtual int | numColors () const |
Method which returns the number (global) of colors used. More... | |
virtual int | numElemsWithColor (int theColor) const |
Return the number of local elements of a given color. More... | |
virtual void | elemsWithColor (int theColor, int *elementList, int len) const |
Fill user-allocated list (of length len) with the local element ids for LOCAL elements of the given color. More... | |
virtual int | extractColorsView (int &size, const int *&array) const |
Give access of the color assignments array that is owned by the current processor. More... | |
virtual int | extractColorsCopy (int len, int &size, int *array) const |
Copy a part of the color assignments array. More... | |
virtual void | setParameters (const Teuchos::ParameterList ¶mlist)=0 |
Set parameters for the Operator instance. More... | |
virtual void | compute (bool forceRecomputing=false)=0 |
Method which does the work of computing a new partitioning/coloring/ordering, depending on the child class used. More... | |
virtual bool | alreadyComputed () const =0 |
Query whether the computation has already been called. More... | |
virtual int | numProperties () const =0 |
Return the number of different values used for "properties". More... | |
virtual int | numLocalProperties () const =0 |
Return the number of different values used for "properties" for this process only. More... | |
virtual const int & | operator[] (int myElem) const =0 |
Return the "property" for a given element that resided locally. More... | |
virtual int | numElemsWithProperty (int property) const =0 |
Return the number of LOCAL elements with the given property. More... | |
virtual void | elemsWithProperty (int property, int *elementList, int len) const =0 |
Fill user-allocated list (of length len) with the local element ids of the LOCAL elements with the given property. More... | |
virtual int | extractPropertiesView (int &size, const int *&array) const =0 |
Give access of the property array that is owned by the current processor. More... | |
virtual int | extractPropertiesCopy (int len, int &size, int *array) const =0 |
Copy a part of the property array. More... | |
Interface (abstract base class) for computing a new coloring and describing the result.
The colors returned have values between 1 and C, where C is the number of colors used.
|
inlinevirtual |
Destructor.
Reimplemented in Isorropia::Epetra::Colorer.
|
pure virtual |
Method which does the work of computing a new coloring.
forceColoring | Optional argument defaults to false. Depending on the implementation, color() should only perform a coloring the first time it is called, and subsequent repeated calls are no-ops. If the user's intent is to re-compute the coloring (e.g., if parameters or other inputs have been changed), then setting this flag to true will force a new coloring to be computed. |
Implemented in Isorropia::Epetra::Colorer.
|
inlinevirtual |
Method which returns the number (global) of colors used.
|
inlinevirtual |
Return the number of local elements of a given color.
theColor | The wanted color. |
|
inlinevirtual |
Fill user-allocated list (of length len) with the local element ids for LOCAL elements of the given color.
theColor | the wanted color |
elementList | an array to receive local elements of the given color |
len | the number of elements wanted |
|
inlinevirtual |
Give access of the color assignments array that is owned by the current processor.
size | [out] Number of elements in the array. |
array | [out] Pointer to the color assignements array inside the object. |
|
inlinevirtual |
Copy a part of the color assignments array.
len | [in] of the array given by the user. |
size | [out] Number of elements in the array. |
array | [out] Array of color assignments. Allocated by the user with a size of at least len elements. |
|
pure virtualinherited |
Set parameters for the Operator 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.
paramlist | [in] List of parameters that the user wants to use. |
Implemented in Isorropia::Epetra::Operator.
|
pure virtualinherited |
Method which does the work of computing a new partitioning/coloring/ordering, depending on the child class used.
forceRecomputing | Optional argument defaults to false. Depending on the implementation, compute() should only perform a computation the first time it is called, and subsequent repeated calls are no-ops. If the user's intent is to re-compute the results (e.g., if parameters or other inputs have been changed), then setting this flag to true will force a new result to be computed. |
Implemented in Isorropia::Epetra::Operator, Isorropia::Epetra::Partitioner, Isorropia::Epetra::Colorer, Isorropia::Epetra::Partitioner2D, Isorropia::Epetra::Orderer, and Isorropia::Epetra::LevelScheduler.
|
pure virtualinherited |
Query whether the computation has already been called.
True
if the computation has already been done, False
otherwise. Implemented in Isorropia::Epetra::Operator.
|
pure virtualinherited |
Return the number of different values used for "properties".
For example, the number of colors or the number of parts used for the overall graph/matrix.
Implemented in Isorropia::Epetra::Operator.
|
pure virtualinherited |
Return the number of different values used for "properties" for this process only.
Implemented in Isorropia::Epetra::Operator.
|
pure virtualinherited |
Return the "property" for a given element that resided locally.
myElem | [in] the local ID of the element we want to know the property. |
Implemented in Isorropia::Epetra::Operator.
|
pure virtualinherited |
Return the number of LOCAL elements with the given property.
property | [in] Value of the property to consider. |
Implemented in Isorropia::Epetra::Operator.
|
pure virtualinherited |
Fill user-allocated list (of length len) with the local element ids of the LOCAL elements with the given property.
property | [in] Value of the property to consider. |
elementList | [out] User allocated array (of size at least len ) of local ID that have the asked property. |
len | [in] Maximum lenght for the array. If len is greater than the result of numElemsWithProperty() for property , only the first and relevant elements are filled. |
Implemented in Isorropia::Epetra::Operator.
|
pure virtualinherited |
Give access of the property array that is owned by the current processor.
size | [out] Number of elements in the array. |
array | [out] Pointer to the the properties array inside the object. |
Implemented in Isorropia::Epetra::Operator.
|
pure virtualinherited |
Copy a part of the property array.
len | [in] of the array given by the user. |
size | [out] Number of elements in the array. |
array | [out] Array of properties. Allocated by the user with a size of at least len elements. |
Implemented in Isorropia::Epetra::Operator.