Epetra Package Browser (Single Doxygen Collection) Development
Public Member Functions
Epetra_Map Class Reference

Epetra_Map: A class for partitioning vectors and matrices. More...

#include <Epetra_Map.h>

Inheritance diagram for Epetra_Map:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 Epetra_Map (int NumGlobalElements, int IndexBase, const Epetra_Comm &Comm)
 Epetra_Map constructor for a Epetra-defined uniform linear distribution of elements.
 Epetra_Map (long long NumGlobalElements, int IndexBase, const Epetra_Comm &Comm)
 Epetra_Map (long long NumGlobalElements, long long IndexBase, const Epetra_Comm &Comm)
 Epetra_Map (int NumGlobalElements, int NumMyElements, int IndexBase, const Epetra_Comm &Comm)
 Epetra_Map constructor for a user-defined linear distribution of elements.
 Epetra_Map (long long NumGlobalElements, int NumMyElements, int IndexBase, const Epetra_Comm &Comm)
 Epetra_Map (long long NumGlobalElements, int NumMyElements, long long IndexBase, const Epetra_Comm &Comm)
 Epetra_Map (int NumGlobalElements, int NumMyElements, const int *MyGlobalElements, int IndexBase, const Epetra_Comm &Comm)
 Epetra_Map constructor for a user-defined arbitrary distribution of elements.
 Epetra_Map (long long NumGlobalElements, int NumMyElements, const long long *MyGlobalElements, int IndexBase, const Epetra_Comm &Comm)
 Epetra_Map (long long NumGlobalElements, int NumMyElements, const long long *MyGlobalElements, long long IndexBase, const Epetra_Comm &Comm)
 Epetra_Map (const Epetra_Map &map)
 Epetra_Map copy constructor.
virtual ~Epetra_Map (void)
 Epetra_Map destructor.
Epetra_Mapoperator= (const Epetra_Map &map)
 Assignment Operator.

Detailed Description

Epetra_Map: A class for partitioning vectors and matrices.

It is often the case that multiple matrix and vector objects have an identical distribution of elements on a parallel machine. The Epetra_Map class keep information that describes this distribution for matrices and vectors.

Epetra_Map allows the storage and retrieval of the following information. Depending on the constructor that is used, some of the information is defined by the user and some is determined by the constructor. Once a Epetra_Map is constructed any of the following attributes can be obtained by calling a query function that has the name as the attribute, e.g. to get the value of NumGlobalElements, you can call a function NumGlobalElements(). For attributes that are lists, the query functions return the list values in a user allocated array.

In addition to the information above that is passed in to or created by the Epetra_Map constructor, the following attributes are computed and available via query to the user using the same scheme as above, e.g., use NumGlobalPoints() to get the value of NumGlobalPoints.

The following functions allow boolean tests for certain properties.

Warning:
An Epetra_Comm object is required for all Epetra_Map constructors.
Note:
In the current implementation, Epetra_BlockMap is the base class for Epetra_Map.

Definition at line 119 of file Epetra_Map.h.


Constructor & Destructor Documentation

Epetra_Map::Epetra_Map ( int  NumGlobalElements,
int  IndexBase,
const Epetra_Comm Comm 
)

Epetra_Map constructor for a Epetra-defined uniform linear distribution of elements.

Creates a map that distributes NumGlobalElements elements evenly across all processors in the Epetra_Comm communicator. If NumGlobalElements does not divide exactly into the number of processors, the first processors in the communicator get one extra element until the remainder is gone.

Parameters:
InNumGlobalElements - Number of elements to distribute.
InIndexBase - Minimum index value used for arrays that use this map. Typically 0 for C/C++ and 1 for Fortran.
InComm - Epetra_Comm communicator containing information on the number of processors.
Returns:
Pointer to a Epetra_Map object.

Definition at line 50 of file Epetra_Map.cpp.

Epetra_Map::Epetra_Map ( long long  NumGlobalElements,
int  IndexBase,
const Epetra_Comm Comm 
)

Definition at line 57 of file Epetra_Map.cpp.

Epetra_Map::Epetra_Map ( long long  NumGlobalElements,
long long  IndexBase,
const Epetra_Comm Comm 
)

Definition at line 63 of file Epetra_Map.cpp.

Epetra_Map::Epetra_Map ( int  NumGlobalElements,
int  NumMyElements,
int  IndexBase,
const Epetra_Comm Comm 
)

Epetra_Map constructor for a user-defined linear distribution of elements.

Creates a map that puts NumMyElements on the calling processor. If NumGlobalElements=-1, the number of global elements will be the computed sum of NumMyElements across all processors in the Epetra_Comm communicator.

Parameters:
InNumGlobalElements - Number of elements to distribute. Must be either -1 or equal to the computed sum of NumMyElements across all processors in the Epetra_Comm communicator.
InNumMyElements - Number of elements owned by the calling processor.
InIndexBase - Minimum index value used for arrays that use this map. Typically 0 for C/C++ and 1 for Fortran.
InComm - Epetra_Comm communicator containing information on the number of processors.
Returns:
Pointer to a Epetra_Map object.

Definition at line 72 of file Epetra_Map.cpp.

Epetra_Map::Epetra_Map ( long long  NumGlobalElements,
int  NumMyElements,
int  IndexBase,
const Epetra_Comm Comm 
)

Definition at line 79 of file Epetra_Map.cpp.

Epetra_Map::Epetra_Map ( long long  NumGlobalElements,
int  NumMyElements,
long long  IndexBase,
const Epetra_Comm Comm 
)

Definition at line 85 of file Epetra_Map.cpp.

Epetra_Map::Epetra_Map ( int  NumGlobalElements,
int  NumMyElements,
const int *  MyGlobalElements,
int  IndexBase,
const Epetra_Comm Comm 
)

Epetra_Map constructor for a user-defined arbitrary distribution of elements.

Creates a map that puts NumMyElements on the calling processor. The indices of the elements are determined from the list MyGlobalElements. If NumGlobalElements=-1, the number of global elements will be the computed sum of NumMyElements across all processors in the Epetra_Comm communicator.

Parameters:
InNumGlobalElements - Number of elements to distribute. Must be either -1 or equal to the computed sum of NumMyElements across all processors in the Epetra_Comm communicator.
InNumMyElements - Number of elements owned by the calling processor.
InMyGlobalElements - Integer array of length NumMyElements. The ith entry contains the global index value of the ith element on this processor. Index values are not required to be contiguous on a processor, or to be within the range of 0 to NumGlobalElements. As long as the index values are consistently defined and used, any set of NumGlobalElements distinct integer values is acceptable.
InIndexBase - Minimum index value used for arrays that use this map. Typically 0 for C/C++ and 1 for Fortran.
InComm - Epetra_Comm communicator containing information on the number of processors.
Returns:
Pointer to a Epetra_Map object.

Definition at line 94 of file Epetra_Map.cpp.

Epetra_Map::Epetra_Map ( long long  NumGlobalElements,
int  NumMyElements,
const long long *  MyGlobalElements,
int  IndexBase,
const Epetra_Comm Comm 
)

Definition at line 103 of file Epetra_Map.cpp.

Epetra_Map::Epetra_Map ( long long  NumGlobalElements,
int  NumMyElements,
const long long *  MyGlobalElements,
long long  IndexBase,
const Epetra_Comm Comm 
)

Definition at line 111 of file Epetra_Map.cpp.

Epetra_Map::Epetra_Map ( const Epetra_Map map)

Epetra_Map copy constructor.

Definition at line 120 of file Epetra_Map.cpp.

Epetra_Map::~Epetra_Map ( void  ) [virtual]

Epetra_Map destructor.

Definition at line 126 of file Epetra_Map.cpp.


Member Function Documentation

Epetra_Map & Epetra_Map::operator= ( const Epetra_Map map)

Assignment Operator.

Definition at line 131 of file Epetra_Map.cpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines