1 #ifndef RECOTOOL_CFALGOQRATIO_CXX 2 #define RECOTOOL_CFALGOQRATIO_CXX 31 if(clusters.size()==2)
return -1;
38 for(
auto const& c : clusters) {
42 if(c->GetParams().sum_charge < 0) {
45 <<
"\033[00m Found a cluster with negative charge!\033[00m ... aborting " 46 << __FUNCTION__ <<std::endl;
51 if(q_max < c->GetParams().sum_charge)
52 q_max = c->GetParams().sum_charge;
57 for(
auto const& c : clusters){
58 ratio *= c->GetParams().sum_charge / q_max;
61 std::cout<<
"Sum Charge: "<<c->GetParams().sum_charge ;
62 std::cout<<
"Q max : "<<q_max<<std::endl ;
63 std::cout<<
"Ratio is: "<<ratio<<std::endl;
68 if( ratio >
_qratio_cut ) std::cout <<
" ... pass!" << std::endl;
69 else std::cout <<
" ... below cut value: " <<
_qratio_cut << std::endl;
Class def header for a class CFAlgoQRatio.