CPPLapack
 All Classes Files Functions Variables Friends Pages
zhsmatrix-unary.hpp
Go to the documentation of this file.
1 //=============================================================================
2 /*! +zhsmatrix operator */
3 inline const zhsmatrix& operator+(const zhsmatrix& mat)
4 {CPPL_VERBOSE_REPORT;
5  return mat;
6 }
7 
8 //=============================================================================
9 /*! -zhsmatrix operator */
10 inline _zhsmatrix operator-(const zhsmatrix& mat)
11 {CPPL_VERBOSE_REPORT;
12  zhsmatrix newmat(mat);
13 
14  const std::vector<zcomponent>::iterator newmat_data_end =newmat.data.end();
15  for(std::vector<zcomponent>::iterator it=newmat.data.begin(); it!=newmat_data_end; it++){
16  it->v =-it->v;
17  }
18 
19  return _(newmat);
20 }
std::vector< zcomponent > data
matrix data
Definition: zhsmatrix.hpp:11
Complex Double-precision Hermitian Sparse Matrix Class.
Definition: zhsmatrix.hpp:3
_zhsmatrix operator-(const zhsmatrix &mat)
const zhsmatrix & operator+(const zhsmatrix &mat)
_dcovector _(dcovector &vec)
(DO NOT USE) Smart-temporary Complex Double-precision Hermitian Sparse Matrix Class ...
Definition: _zhsmatrix.hpp:3