The Original CHomP Software
Public Member Functions | Protected Attributes | List of all members
chomp::homology::flatMatrix< element >::row Class Reference

The class that represents a single row of the matrix. More...

#include <flatmatr.h>

Public Member Functions

 row (int _offset, element *_v)
 The constructor of a row of the matrix. More...
 
element & operator[] (int j)
 Returns a reference to the element at the given position. More...
 

Protected Attributes

int offset
 The offset in the vector of all the entries of the matrix. More...
 
element * v
 A reference to the vector that stores all the entries of the matrix. More...
 

Detailed Description

template<class element>
class chomp::homology::flatMatrix< element >::row

The class that represents a single row of the matrix.

Definition at line 88 of file flatmatr.h.

Constructor & Destructor Documentation

◆ row()

template<class element >
chomp::homology::flatMatrix< element >::row::row ( int  _offset,
element *  _v 
)
inline

The constructor of a row of the matrix.

Definition at line 92 of file flatmatr.h.

92 :
93 offset (_offset), v (_v) {}
element * v
A reference to the vector that stores all the entries of the matrix.
Definition: flatmatr.h:105
int offset
The offset in the vector of all the entries of the matrix.
Definition: flatmatr.h:101

Member Function Documentation

◆ operator[]()

template<class element >
element & chomp::homology::flatMatrix< element >::row::operator[] ( int  j)
inline

Returns a reference to the element at the given position.

Definition at line 96 of file flatmatr.h.

96{return v [offset + j];}

References chomp::homology::flatMatrix< element >::row::offset, and chomp::homology::flatMatrix< element >::row::v.

Member Data Documentation

◆ offset

template<class element >
int chomp::homology::flatMatrix< element >::row::offset
protected

The offset in the vector of all the entries of the matrix.

Definition at line 101 of file flatmatr.h.

Referenced by chomp::homology::flatMatrix< element >::row::operator[]().

◆ v

template<class element >
element* chomp::homology::flatMatrix< element >::row::v
protected

A reference to the vector that stores all the entries of the matrix.

Definition at line 105 of file flatmatr.h.

Referenced by chomp::homology::flatMatrix< element >::row::operator[]().


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