33 namespace RestFrames {
36 const std::string& stitle,
37 int N_comb,
int N_mass)
39 m_Ncomb(N_comb), m_Nmass(N_mass)
41 for(
int i = 0; i < m_Nmass; i++){
43 m_Sigma.push_back(1.);
47 MinMassChi2CombJigsaw::~MinMassChi2CombJigsaw() {}
50 if(i < 0 || i >= m_Nmass)
53 m_Mass[i] = std::max(mass, 0.);
57 if(i < 0 || i >= m_Nmass)
65 bool MinMassChi2CombJigsaw::EvaluateMetric(
double& metric)
const {
70 for(
int i = 0; i < m_Nmass; i++){
72 P = GetDependancyStates(i).GetFourVector();
74 int N = GetDependancyStates(i).GetN();
75 for(
int j = 0; j < N; j++){
76 TLorentzVector v = GetDependancyStates(i)[j].GetFourVector();
77 TVector3 p = v.Vect() - v.Vect().Dot(GetTransverseAxis())*GetTransverseAxis();
84 chi2 += (mass-m_Mass[i])*(mass-m_Mass[i])/m_Sigma[i]/m_Sigma[i];