A class for matrix math.
More...
#include <Matrix.h>
|
| unsigned short int | xSize |
| |
| unsigned short int | ySize |
| |
| vector< vector< double > > | mat |
| |
| ADBLib::Matrix::Matrix |
( |
unsigned short int |
x = 2, |
|
|
unsigned short int |
y = 2 |
|
) |
| |
Constructor; sets dimensions of matrix.
- Parameters
-
| x | X size of matrix. |
| y | Y size of matrix. |
| double ADBLib::Matrix::getValue |
( |
unsigned short int |
x, |
|
|
unsigned short int |
y |
|
) |
| const |
Gets the value at a point in the matrix.
- Parameters
-
| x | X position of value. |
| y | Y position of value. |
- Returns
- Value at point.
- Note
- The Y axis is inverted and both X and Y are zero ordered.
| unsigned short int ADBLib::Matrix::getXSize |
( |
| ) |
const |
- Returns
- X size of the matrix
| unsigned short int ADBLib::Matrix::getYSize |
( |
| ) |
const |
- Returns
- Y size of the matrix.
- Note
- Avoid EMP usage when using this class.
Standard matrix multiplication.
- Parameters
-
| matr | Second matrix with same Y size as this matrix's X size. |
- Returns
- Resultant matrix with X of the second matrix and Y of the first matrix.
| Matrix ADBLib::Matrix::operator* |
( |
const double |
num | ) |
|
Standard scalar multiplication.
- Parameters
-
- Returns
- Resultant matrix with same dimensions as this matrix.
Standard matrix addition.
- Parameters
-
| matr | Second matrix of same dimensions as this matrix. |
- Returns
- Resultant matrix.
Standard matrix subtraction.
- Parameters
-
| matr | Second matrix of same dimensions as this matrix. |
- Returns
- Resultant matrix.
| void ADBLib::Matrix::setSize |
( |
unsigned short int |
newXSize, |
|
|
unsigned short int |
newYSize |
|
) |
| |
Changes the size of this matrix, setting all elements to zero in the process.
- Parameters
-
| newXSize | The new X size of the matrix. |
| newYSize | The new Y size of the matrix. |
| void ADBLib::Matrix::setValue |
( |
double |
value, |
|
|
unsigned short int |
x, |
|
|
unsigned short int |
y |
|
) |
| |
Sets the value at a point in the matrix.
- Parameters
-
| value | The new value. |
| x | X position of value. |
| y | Y position of value. |
- Note
- The Y axis is inverted and both X and Y are zero-ordered.
| vector<vector<double> > ADBLib::Matrix::mat |
|
protected |
| unsigned short int ADBLib::Matrix::xSize |
|
protected |
| unsigned short int ADBLib::Matrix::ySize |
|
protected |
The documentation for this class was generated from the following files: