diff --git a/src/EvtGenModels/EvtSLBaryonAmp.cpp b/src/EvtGenModels/EvtSLBaryonAmp.cpp --- a/src/EvtGenModels/EvtSLBaryonAmp.cpp +++ b/src/EvtGenModels/EvtSLBaryonAmp.cpp @@ -427,7 +427,7 @@ EvtVector4R vector4P = parent->getP4Lab(); double pmag = vector4P.d3mag(); - double cosTheta = vector4P.get( 3 ) / pmag; + double cosTheta = pmag > 0.0 ? vector4P.get( 3 ) / pmag : 0.0; double theta = acos( cosTheta ); double phi = atan2( vector4P.get( 2 ), vector4P.get( 1 ) ); @@ -461,7 +461,7 @@ FormFactors->getdiracff( par_num, bar_num, q2, baryonmass, &f1, &f2, &f3, &g1, &g2, &g3 ); - const double form_fact[6] = {f1, f2, f3, g1, g2, g3}; + const double form_fact[6] = { f1, f2, f3, g1, g2, g3 }; EvtVector4C b11, b12, b21, b22, l1, l2; @@ -584,7 +584,7 @@ FormFactors->getraritaff( par_num, bar_num, q2, baryonmass, &f1, &f2, &f3, &f4, &g1, &g2, &g3, &g4 ); - const double form_fact[8] = {f1, f2, f3, f4, g1, g2, g3, g4}; + const double form_fact[8] = { f1, f2, f3, f4, g1, g2, g3, g4 }; EvtId l_num = parent->getDaug( 1 )->getId(); diff --git a/src/EvtGenModels/EvtSSD_DirectCP.cpp b/src/EvtGenModels/EvtSSD_DirectCP.cpp --- a/src/EvtGenModels/EvtSSD_DirectCP.cpp +++ b/src/EvtGenModels/EvtSSD_DirectCP.cpp @@ -81,7 +81,7 @@ EvtSpinType::spintype d2type = EvtPDL::getSpinType( getDaug( 1 ) ); EvtSpinType::spintype d1type = EvtPDL::getSpinType( getDaug( 0 ) ); if ( d1type == EvtSpinType::TENSOR || d2type == EvtSpinType::TENSOR ) - theProbMax *= 10; + theProbMax = 20.0; setProbMax( theProbMax ); } diff --git a/test/testDecayModel.cc b/test/testDecayModel.cc --- a/test/testDecayModel.cc +++ b/test/testDecayModel.cc @@ -1064,9 +1064,12 @@ double chiSq{ 0.0 }; int nDof{ 0 }; int iGood{ 0 }; - double pValue{ refHist->Chi2TestX( hist, chiSq, nDof, iGood, "WW" ) }; + const double pValue{ + refHist->Chi2TestX( hist, chiSq, nDof, iGood, "WW" ) }; + const double integral{ refHist->Integral() }; std::cout << "Histogram " << histName << " chiSq/nDof = " << chiSq - << "/" << nDof << ", pValue = " << pValue << std::endl; + << "/" << nDof << ", pValue = " << pValue + << ", integral = " << integral << std::endl; } else { std::cerr << "Could not find reference histogram " << histName @@ -1084,9 +1087,12 @@ double chiSq{ 0.0 }; int nDof{ 0 }; int iGood{ 0 }; - double pValue{ refHist->Chi2TestX( hist, chiSq, nDof, iGood, "WW" ) }; + const double pValue{ + refHist->Chi2TestX( hist, chiSq, nDof, iGood, "WW" ) }; + const double integral{ refHist->Integral() }; std::cout << "Histogram " << histName << " chiSq/nDof = " << chiSq - << "/" << nDof << ", pValue = " << pValue << std::endl; + << "/" << nDof << ", pValue = " << pValue + << ", integral = " << integral << std::endl; } else { std::cerr << "Could not find reference histogram " << histName