My Project
dgbmatrix-unary.hpp
1 //=============================================================================
3 inline const dgbmatrix& operator+(const dgbmatrix& mat)
4 {
5 #ifdef CPPL_VERBOSE
6  std::cerr << "# [MARK] operator+(const dgbmatrix&)"
7  << std::endl;
8 #endif//CPPL_VERBOSE
9 
10  return mat;
11 }
12 
13 //=============================================================================
15 inline _dgbmatrix operator-(const dgbmatrix& mat)
16 {
17 #ifdef CPPL_VERBOSE
18  std::cerr << "# [MARK] operator-(const dgbmatrix&)"
19  << std::endl;
20 #endif//CPPL_VERBOSE
21 
22  dgbmatrix newmat(mat.M,mat.N,mat.KL,mat.KU);
23  for(long i=0; i<(newmat.KL+newmat.KU+1)*newmat.N; i++){
24  newmat.Array[i]=-mat.Array[i];
25  }
26 
27  return _(newmat);
28 }
friend _drovector operator-(const _drovector &)
Definition: _drovector-unary.hpp:15
Real Double-precision General Band Matrix Class.
Definition: dgbmatrix.hpp:3
(DO NOT USE) Smart-temporary Real Double-precision General Band Matrix Class
Definition: _dgbmatrix.hpp:3
friend const _drovector & operator+(const _drovector &)
Definition: _drovector-unary.hpp:3