1 #ifndef QNANO_NEW_CDAGGERC_ITERATOR_SINGLEI_DEFINED_H 2 #define QNANO_NEW_CDAGGERC_ITERATOR_SINGLEI_DEFINED_H 4 #include "manybody/Fermion_Double_Index.h" 27 void calculate_next();
39 double get_sign()
const{
51 void setup(
const Fermion_Index &fi,
int c_index_,
int n_max_){
63 if(c_index>=(
int)fi.size()){
64 std::cerr<<
"CdaggerC_Iterator::constructor: c_index>=fi.size()"<<std::endl;
67 if(n_max<(
int)fi.size()){
68 std::cerr<<
"CdaggerC_Iterator::constructor: n_max<fi.size()"<<std::endl;
76 for(
int i=c_index-1; i>=0; i--){
78 fi_cur[i+1]=fi_cur[i];
80 if(fi_cur.size()>0)fi_cur[0]=0;
82 if(c_index%2==1)sign=-1.;
91 setup(fi, c_index_, n_max_);
Definition: CdaggerC_Iterator_SingleI.h:8
Definition: Fermion_Index.h:19