SkelGIS  3.0
skelgis::DMatrix_impl< T, 0, true > Struct Template Reference

DMatrix_impl class. More...

#include <dmatrix_impl.hpp>

Inheritance diagram for skelgis::DMatrix_impl< T, 0, true >:
skelgis::DMatrix_base< T >

List of all members.

Public Member Functions

 DMatrix_impl ()
 default constructor of the distributed matrix interface
 DMatrix_impl (HEADER h, const T value, bool loc=false)
 constructor of the distributed matrix
 DMatrix_impl (const char *binFile, bool loc=false)
 constructor of the distributed matrix
 ~DMatrix_impl ()
 destructor of the distributed matrix
iterator< T, 0 > begin ()
 Get the beginning iterator of the DMatrix (on the first element of the DMatrix)
iterator_cont< T, 0 > begin_cont ()
iterator_step< T, 0 > begin_step (int step, int nb)
iterator_rev< T, 0 > begin_rev ()
iterator_line< T, 0 > begin_line ()
iterator< T, 0 > end ()
 Get the ending iterator of the DMatrix (on the last element of the DMatrix)
iterator_cont< T, 0 > end_cont ()
iterator_step< T, 0 > end_step ()
iterator_rev< T, 0 > end_rev ()
iterator_line< T, 0 > end_line ()
iterator< T, 0 > getIterator (int col, int li)
 get the iterator on the matrix at position (x,y)
iterator_cont< T, 0 > getIterator_cont (int col, int li)
 get the iterator contiguous on the matrix at position (x,y)
iterator_rev< T, 0 > getIterator_rev (int col, int li)
 get the iterator reverse on the matrix at position (x,y)
void getIndexes (iterator< T, 0 > it, int &col, int &li)
 get the indexes of the iterator on the matrix
void getIndexes (iterator_cont< T, 0 > it, int &col, int &li)
void getIndexes (iterator_rev< T, 0 > it, int &col, int &li)
void print ()
 Print the matrix by bloc.
void write (char *binFile)
 Write the zone file concerned for the current MPI process.

Protected Member Functions

void create ()
 Creation of the ditributed matrix.
void initValues (T value)
 Values initialization of the elements of the DMatrix_impl.
void read (const char *binFile)
 Read the zone of the binary file concerned for the current MPI process.
void indexesIt (unsigned int rank, int &col, int &li)
 Get the indexes associated to a precise rank.

Detailed Description

template<class T>
struct skelgis::DMatrix_impl< T, 0, true >

DMatrix_impl class.

template of the distributed matrix implementation of SkelGIS. This is the second specialization of the DMatrix_impl.

Template Parameters:
Tis the type of data to store in the DMatrix_impl R overlap template parameter is not asked and specialized to 0. The default value of line is used (true).

Definition at line 1481 of file dmatrix_impl.hpp.


Constructor & Destructor Documentation

template<class T >
skelgis::DMatrix_impl< T, 0, true >::DMatrix_impl ( HEADER  h,
const T  value,
bool  loc = false 
) [inline]

constructor of the distributed matrix

This constructor will simply allocate the good space.

Parameters:
his the header to use to build your matrix
valueis the default value to put in the matrix
locis a boolean value to indicate if the DMatrix_impl has to stay local to one MPI process (used in ApplyReduction).

Definition at line 1618 of file dmatrix_impl.hpp.

template<class T >
skelgis::DMatrix_impl< T, 0, true >::DMatrix_impl ( const char *  binFile,
bool  loc = false 
) [inline]

constructor of the distributed matrix

The constructor evaluate how to divide the matrix in submatrice and do the work.

Parameters:
binFileis the path of the binary file you want to work on
locis a boolean value to indicate if the DMatrix_impl has to stay local to one MPI process (used in ApplyReduction).

Definition at line 1634 of file dmatrix_impl.hpp.


Member Function Documentation

template<class T >
iterator<T,0> skelgis::DMatrix_impl< T, 0, true >::begin ( ) [inline]

Get the beginning iterator of the DMatrix (on the first element of the DMatrix)

This method exists for each type of iterator in SkelGIS.

Returns:
the iterator of the first element

Definition at line 1659 of file dmatrix_impl.hpp.

template<class T >
void skelgis::DMatrix_impl< T, 0, true >::create ( ) [inline, protected]

Creation of the ditributed matrix.

Data distribution and construction of the parallel data structure.

Definition at line 1492 of file dmatrix_impl.hpp.

template<class T >
iterator<T,0> skelgis::DMatrix_impl< T, 0, true >::end ( ) [inline]

Get the ending iterator of the DMatrix (on the last element of the DMatrix)

This method exists for each type of iterator in SkelGIS.

Returns:
the iterator of the last element

Definition at line 1671 of file dmatrix_impl.hpp.

template<class T >
void skelgis::DMatrix_impl< T, 0, true >::getIndexes ( iterator< T, 0 >  it,
int &  col,
int &  li 
) [inline]

get the indexes of the iterator on the matrix

Parameters:
itis the iterator from which the indexes will be taken
xis the iterator position x returned
yis the iterator position y returned

Definition at line 1731 of file dmatrix_impl.hpp.

template<class T >
iterator<T,0> skelgis::DMatrix_impl< T, 0, true >::getIterator ( int  col,
int  li 
) [inline]

get the iterator on the matrix at position (x,y)

Parameters:
xis row index y is column index
Returns:
returns the iterator at position (x,y)

Definition at line 1683 of file dmatrix_impl.hpp.

template<class T >
iterator_cont<T,0> skelgis::DMatrix_impl< T, 0, true >::getIterator_cont ( int  col,
int  li 
) [inline]

get the iterator contiguous on the matrix at position (x,y)

Parameters:
xis row index y is column index
Returns:
returns the iterator at position (x,y)

Definition at line 1699 of file dmatrix_impl.hpp.

template<class T >
iterator_rev<T,0> skelgis::DMatrix_impl< T, 0, true >::getIterator_rev ( int  col,
int  li 
) [inline]

get the iterator reverse on the matrix at position (x,y)

Parameters:
xis row index y is column index
Returns:
returns the iterator at position (x,y)

Definition at line 1715 of file dmatrix_impl.hpp.

template<class T >
void skelgis::DMatrix_impl< T, 0, true >::indexesIt ( unsigned int  rank,
int &  col,
int &  li 
) [inline, protected]

Get the indexes associated to a precise rank.

Parameters:
rankis the rank at which the indexes values are wanted
colis the column return value
liis the line return value

Definition at line 1597 of file dmatrix_impl.hpp.

template<class T >
void skelgis::DMatrix_impl< T, 0, true >::initValues ( value) [inline, protected]

Values initialization of the elements of the DMatrix_impl.

Parameters:
valueis the value to set to the elements

Definition at line 1548 of file dmatrix_impl.hpp.

template<class T >
void skelgis::DMatrix_impl< T, 0, true >::read ( const char *  binFile) [inline, protected]

Read the zone of the binary file concerned for the current MPI process.

Parameters:
binFileis binary file to read

Definition at line 1562 of file dmatrix_impl.hpp.

template<class T >
void skelgis::DMatrix_impl< T, 0, true >::write ( char *  binFile) [inline]

Write the zone file concerned for the current MPI process.

write the MPI prcess zone, and spread the data in the subMatrices OpenMP only one submatrice if OpenMP is disabled

Parameters:
binFileis binary file to write in

Definition at line 1759 of file dmatrix_impl.hpp.


The documentation for this struct was generated from the following file:
 All Classes Files Functions Variables Defines