LatNet Builder Manual  2.0.1-11
Software Package for Constructing Highly Uniform Point Sets
NetBuilder::ProgressiveRowReducer Class Reference

Class used to perform row reduction operations on a matrix. More...

#include <ProgressiveRowReducer.h>

Public Member Functions

 ProgressiveRowReducer (unsigned int nCols=0)
 Constructor. More...
 
void reset (unsigned int nCols)
 Clears the reducer and set the number of columns to nCols. More...
 
void addRow (GeneratingMatrix newRow)
 Adds a row below the current matrix and updates the reduction subsequently. More...
 
void addColumn (GeneratingMatrix newCol)
 Adds a column on the right to the current matrix and updates the reduction subsequently. More...
 
void replaceRow (unsigned int rowIndex, GeneratingMatrix &&newRow, int verbose=0)
 Replaces the row in position rowIndex by newRow. More...
 
unsigned int computeRank () const
 Computes the rank of the matrix.
 
std::vector< unsigned int > computeRanks (unsigned int firstCol, unsigned int numCol) const
 Computes the ranks of the submatrices with an increasing number of columns. More...
 
unsigned int smallestFullRank ()
 Returns the minimal number of columns necessary for the system spanned by the rows to be of full rank. More...
 
const GeneratingMatrixreducedMatrix () const
 Returns a const reference to the row-reduced matrix.
 
const GeneratingMatrixrowOperations () const
 Returns a const reference to the row operations matrix.
 
unsigned int numRows () const
 Returns the number of rows in the reducer.
 
unsigned int numCols () const
 Returns the number of columns in the reducer.
 
std::map< unsigned int, unsigned int > getPivots () const
 Returns a map of pivot positions (key: row index, value: column index).
 

Static Public Member Functions

static bool checkIfInvertible (GeneratingMatrix matrix)
 Check if a matrix is invertible. More...
 

Detailed Description

Class used to perform row reduction operations on a matrix.

Constructor & Destructor Documentation

◆ ProgressiveRowReducer()

NetBuilder::ProgressiveRowReducer::ProgressiveRowReducer ( unsigned int  nCols = 0)

Constructor.

Parameters
nColsnumber of columns of the reducer.

Member Function Documentation

◆ addColumn()

void NetBuilder::ProgressiveRowReducer::addColumn ( GeneratingMatrix  newCol)

Adds a column on the right to the current matrix and updates the reduction subsequently.

Parameters
newColThe one-column matrix to stack on the right.

◆ addRow()

void NetBuilder::ProgressiveRowReducer::addRow ( GeneratingMatrix  newRow)

Adds a row below the current matrix and updates the reduction subsequently.

Parameters
newRowThe one-row matrix to stack below.

◆ checkIfInvertible()

static bool NetBuilder::ProgressiveRowReducer::checkIfInvertible ( GeneratingMatrix  matrix)
static

Check if a matrix is invertible.

Returns false if the matrix is not-square or singular, and true otherwise.

◆ computeRanks()

std::vector<unsigned int> NetBuilder::ProgressiveRowReducer::computeRanks ( unsigned int  firstCol,
unsigned int  numCol 
) const

Computes the ranks of the submatrices with an increasing number of columns.

Parameters
firstColIndex of the the last column of the first submatrix.
numColNumber of submatrices to consider.

◆ replaceRow()

void NetBuilder::ProgressiveRowReducer::replaceRow ( unsigned int  rowIndex,
GeneratingMatrix &&  newRow,
int  verbose = 0 
)

Replaces the row in position rowIndex by newRow.

Parameters
rowIndexIndex of the row to discard.
newRowReplacement row.
verboseVerbosity level.

◆ reset()

void NetBuilder::ProgressiveRowReducer::reset ( unsigned int  nCols)

Clears the reducer and set the number of columns to nCols.

Parameters
nColsNew number of columns of the reducer.

◆ smallestFullRank()

unsigned int NetBuilder::ProgressiveRowReducer::smallestFullRank ( )
inline

Returns the minimal number of columns necessary for the system spanned by the rows to be of full rank.

Returns nCols() + 1 if the system is not of full rank even if all the columns are taken.


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