6 std::cerr <<
"# [MARK] operator+(const zgbmatrix&, const _zgematrix&)"
11 if(matA.N!=matB.
N || matA.M!=matB.
M){
12 std::cerr <<
"[ERROR] operator+(zgbmatrix&, _zgematrix&)" << std::endl
13 <<
"These two matrises can not make a summation." << std::endl
14 <<
"Your input was (" << matA.M <<
"x" << matA.N <<
") + ("
15 << matB.
M <<
"x" << matB.
N <<
")." << std::endl;
20 for(
long i=0; i<matA.M; i++){
21 for(
long j=max(0,i-matA.KL); j<min(matA.N,i+matA.KU+1); j++){
34 std::cerr <<
"# [MARK] operator-(const zgbmatrix&, const _zgematrix&)"
39 if(matA.N!=matB.
N || matA.M!=matB.
M){
40 std::cerr <<
"[ERROR] operator+(zgbmatrix&, _zgematrix&)" << std::endl
41 <<
"These two matrises can not make a summation." << std::endl
42 <<
"Your input was (" << matA.M <<
"x" << matA.N <<
") + ("
43 << matB.
M <<
"x" << matB.
N <<
")." << std::endl;
49 for(
long i=0; i<matB.
M*matB.
N; i++){
54 for(
long i=0; i<matA.M; i++){
55 for(
long j=max(0,i-matA.KL); j<min(matA.N,i+matA.KU+1); j++){
56 matB(i,j) +=matA(i,j);
68 std::cerr <<
"# [MARK] operator*(const zgbmatrix&, const _zgematrix&)"
74 std::cerr <<
"[ERROR] operator*(zgbmatrix&, _zgematrix&)" << std::endl
75 <<
"These two matrises can not make a product." << std::endl
76 <<
"Your input was (" << matA.M <<
"x" << matA.N <<
") * ("
77 << matB.
M <<
"x" << matB.
N <<
")." << std::endl;
86 #pragma omp parallel for private(j,k)
87 for(i=0; i<newmat.m; i++){
88 for(j=0; j<newmat.n; j++){
89 for(k=max(0,i-matA.KL); k<min(matA.N,i+matA.KU+1); k++){
90 newmat(i,j)+=matA(i,k)*matB(k,j);
long N
matrix column size
Definition: _zgematrix.hpp:8
friend _zrovector operator-(const _zrovector &)
Definition: _zrovector-unary.hpp:15
Complex Double-precision General Dence Matrix Class.
Definition: zgematrix.hpp:3
(DO NOT USE) Smart-temporary Complex Double-precision General Dence Matrix Class
Definition: _zgematrix.hpp:3
void destroy() const
Definition: _zgematrix-misc.hpp:3
Complex Double-precision General Band Matrix Class.
Definition: zgbmatrix.hpp:3
std::complex< double > * Array
1D Array to store matrix data
Definition: _zgematrix.hpp:9
friend _zrovector operator*(const zrovector &, const zgematrix &)
Definition: zrovector-zgematrix.hpp:3
long M
matrix row size
Definition: _zgematrix.hpp:7
friend const _zrovector & operator+(const _zrovector &)
Definition: _zrovector-unary.hpp:3