6 if(
n!=mat.
n ||
m!=mat.
n){
8 std::cerr <<
"These two matrises can not make a summation." << std::endl
9 <<
"Your input was (" <<
m <<
"x" <<
n <<
") += (" << mat.
n <<
"x" << mat.
n <<
")." << std::endl;
14 for(CPPL_INT
i=0;
i<
m;
i++){
15 for(CPPL_INT j=0; j<
n; j++){
29 if(
n!=mat.
n ||
m!=mat.
n){
31 std::cerr <<
"These two matrises can not make a sutraction." << std::endl
32 <<
"Your input was (" <<
m <<
"x" <<
n <<
") -= (" << mat.
n <<
"x" << mat.
n <<
")." << std::endl;
37 for(CPPL_INT
i=0;
i<
m;
i++){
38 for(CPPL_INT j=0; j<
n; j++){
54 std::cerr <<
"These two matrises can not make a product." << std::endl
55 <<
"Your input was (" <<
m <<
"x" <<
n <<
") *= (" << mat.
n <<
"x" << mat.
n <<
")." << std::endl;
66 dsymm_( &side, &uplo, &mat.
n, &
n, &alpha, mat.
array, &mat.
n,
array, &
m, &beta, newmat.
array, &newmat.
m );
82 if(matA.
n!=matB.
n || matA.
m!=matB.
n){
84 std::cerr <<
"These two matrises can not make a summation." << std::endl
85 <<
"Your input was (" << matA.
m <<
"x" << matA.
n <<
") + (" << matB.
n <<
"x" << matB.
n <<
")." << std::endl;
91 for(CPPL_INT
i=0;
i<matA.
m;
i++){
92 for(CPPL_INT j=0; j<matA.
n; j++){
93 newmat(
i,j) += matB(
i,j);
104 {CPPL_VERBOSE_REPORT;
106 if(matA.
n!=matB.
n || matA.
m!=matB.
n){
108 std::cerr <<
"These two matrises can not make a subtraction." << std::endl
109 <<
"Your input was (" << matA.
m <<
"x" << matA.
n <<
") - (" << matB.
n <<
"x" << matB.
n <<
")." << std::endl;
115 for(CPPL_INT
i=0;
i<matA.
m;
i++){
116 for(CPPL_INT j=0; j<matA.
n; j++){
117 newmat(
i,j) -= matB(
i,j);
128 {CPPL_VERBOSE_REPORT;
132 std::cerr <<
"These two matrises can not make a product." << std::endl
133 <<
"Your input was (" << matA.
m <<
"x" << matA.
n <<
") * (" << matB.
n <<
"x" << matB.
n <<
")." << std::endl;
144 dsymm_( &side, &uplo, &newmat.
m, &newmat.
n, &alpha, matB.
array, &matB.
n, matA.
array, &matA.
m, &beta, newmat.
array, &newmat.
m );
_dgematrix operator*(const dgematrix &matA, const _dsymatrix &matB)
_dgematrix operator+(const dgematrix &matA, const _dsymatrix &matB)
CPPL_INT m
matrix row size
double * array
1D array to store matrix data
_dgematrix i(const _dgbmatrix &mat)
friend void swap(dgematrix &, dgematrix &)
double & operator()(const CPPL_INT &, const CPPL_INT &)
CPPL_INT n
matrix column size
Real Double-precision General Dence Matrix Class.
_dgematrix operator-(const dgematrix &matA, const _dsymatrix &matB)
double * array
1D array to store matrix data
dgematrix & operator*=(const dgematrix &)
(DO NOT USE) Smart-temporary Real Double-precision General Dence Matrix Class
(DO NOT USE) Smart-temporary Real Double-precision Symmetric Matrix Class
dgematrix & operator-=(const dgematrix &)
friend _dgematrix i(const dgematrix &)
CPPL_INT n
matrix column size
dgematrix & operator+=(const dgematrix &)
_dcovector _(dcovector &vec)