Hopsan
|
#include <matrix.h>
Public Member Functions | |
Matrix () | |
default (no argument) constructor | |
Matrix (int rows, int cols) | |
constructs a Matrix of specified size | |
Matrix (const Matrix &src) | |
copy constructor | |
~Matrix () | |
void | create (int rows, int cols) |
creates(or resets) Matrix size and allocated space. | |
int | cols () const |
returns the number of columns | |
int | rows () const |
Matrix & | set (double v) |
set Matrix elements to v | |
Matrix & | operator= (const Matrix &mx) |
Matrix | operator* (const Matrix &mx) const |
Matrix multiplication. | |
void | swaprows (int i, int j) |
swap rows | |
Matrix | transpose () |
returns the transpose of the Matrix | |
double * | operator[] (int n) const |
returns a pointer to a Matrix row | |
void | print () const |
prints Matrix (using mprint) | |
Vec | operator* (const Vec &v) const |
matix multipled by Vec | |
Friends | |
Vec | operator* (const Vec &v, const Matrix &mx) |
Vec multiplied by Matrix. | |
defines a two-dimensional Matrix of doubles
~Matrix | ( | ) |
destructor
|
inline |
returns the number of rows