108#include <initializer_list>
125 double *mpBuf =
nullptr;
161 Matrix(
const std::initializer_list<MatIniLst> &lst);
170 explicit Matrix(
const std::initializer_list<MatIniLst> &lst,
int col);
181 explicit Matrix(
double *p,
int row,
int col,
int count);
643 bool det(
double &result)
const;
704 void rowAdd(
int des,
int src,
double factor);
757 Matrix getBlock(
int startRowId,
int startColId,
int blockRow,
int blockCol)
const;
807 static signed char sgn(
double num);
825 Matrix lrDivide(
int col)
const;
std::initializer_list< double > MatIniLst
Definition Matrix.h:110
本类用于进行矩阵的基本计算
Definition Matrix.h:120
friend Matrix operator*(const Matrix &lMat, const Matrix &rMat)
运算符重载,友元函数
Definition Matrix.cpp:357
void qrDecom(Matrix &Q, Matrix &R) const
公有函数
Definition Matrix.cpp:929
void rowMultiply(int des, double factor)
公有函数
Definition Matrix.cpp:797
friend bool operator!=(const Matrix &lMat, const Matrix &rMat)
运算符重载,友元函数
Definition Matrix.cpp:441
friend bool operator==(const Matrix &lMat, const Matrix &rMat)
运算符重载,友元函数
Definition Matrix.cpp:429
Matrix & operator=(const Matrix &tmp)
运算符重载,拷贝赋值函数
Definition Matrix.cpp:313
double * operator[](int num)
运算符重载
Definition Matrix.cpp:488
Matrix()
无参数构造函数
Definition Matrix.cpp:17
static void setPrecise(int precise)
静态函数
Definition Matrix.cpp:242
static Matrix randMatrix(int n)
静态函数
Definition Matrix.cpp:284
Matrix getBlock(int startRowId, int startColId, int blockRow, int blockCol) const
公有函数
Definition Matrix.cpp:836
Matrix & operator-=(const Matrix &tmp)
运算符重载
Definition Matrix.cpp:417
static Matrix udMerge(Matrix &up, Matrix &down)
静态函数
Definition Matrix.cpp:825
int getCol() const
公有函数
Definition Matrix.cpp:521
bool rowExchange(int des, int src)
公有函数
Definition Matrix.cpp:782
bool isSizeValidity()
公有函数
Definition Matrix.cpp:740
static Matrix zeros(int row)
静态函数
Definition Matrix.cpp:217
bool det(double &result) const
公有函数
Definition Matrix.cpp:614
static Matrix lrMerge(Matrix &left, Matrix &right)
静态函数
Definition Matrix.cpp:806
static Matrix eye(int row)
静态函数
Definition Matrix.cpp:151
friend Matrix operator/(const Matrix &lMat, const Matrix &rMat)
运算符重载,友元函数
Definition Matrix.cpp:372
Matrix transpose() const
公有函数
Definition Matrix.cpp:600
static Matrix ones(int row)
静态函数
Definition Matrix.cpp:184
Matrix sMultiple(const double &factor) const
公有函数
Definition Matrix.cpp:562
bool isEmptyMatrix() const
公有函数
Definition Matrix.cpp:763
Matrix & operator++()
运算符重载
Definition Matrix.cpp:457
friend Matrix operator-(const Matrix &lMat, const Matrix &rMat)
运算符重载,友元函数
Definition Matrix.cpp:352
static Matrix diag(Matrix mat)
静态函数
Definition Matrix.cpp:248
Matrix sub(const Matrix &tmp) const
公有函数
Definition Matrix.cpp:545
~Matrix()
析构函数
Definition Matrix.cpp:140
Matrix add(const Matrix &tmp) const
公有函数
Definition Matrix.cpp:527
Matrix & setBlock(int startRowId, int startColId, const Matrix &block)
公有函数
Definition Matrix.cpp:857
Matrix inverse() const
公有函数
Definition Matrix.cpp:727
Matrix & operator+=(const Matrix &tmp)
运算符重载
Definition Matrix.cpp:406
Matrix hessenberg(Matrix &Q) const
公有函数
Definition Matrix.cpp:878
Matrix rMultiple(const Matrix &tmp) const
公有函数
Definition Matrix.cpp:573
bool isSquareMatrix() const
公有函数
Definition Matrix.cpp:757
Matrix & operator--()
运算符重载
Definition Matrix.cpp:469
void rowAdd(int des, int src, double factor)
公有函数
Definition Matrix.cpp:773
friend std::ostream & operator<<(std::ostream &os, const Matrix &tmp)
运算符重载,友元函数
Definition Matrix.cpp:498
Matrix gauss() const
公有函数
Definition Matrix.cpp:660
int rank() const
公有函数
Definition Matrix.cpp:710
Matrix eigen() const
公有函数
Definition Matrix.cpp:976
int getRow() const
公有函数
Definition Matrix.cpp:516
friend Matrix operator+(const Matrix &lMat, const Matrix &rMat)
运算符重载,友元函数
Definition Matrix.cpp:347