5 #include <TLorentzVector.h>
12 Megajet::Megajet(vector<float> Px_vector, vector<float> Py_vector, vector<float> Pz_vector,
13 vector<float> E_vector,
int megajet_association_method) :
14 Object_Px(Px_vector), Object_Py(Py_vector), Object_Pz(Pz_vector), Object_E(E_vector),
15 megajet_meth(megajet_association_method),
status(0) {
17 if(
Object_Px.size() < 2)
cout <<
"Error in Megajet: you should provide at least two jets to form Megajets" << endl;
18 for(
int j=0;
j<(int)
jIN.size(); ++
j) {
25 Megajet::Megajet(vector<float> Px_vector, vector<float> Py_vector, vector<float> Pz_vector,
26 vector<float> E_vector) :
27 Object_Px(Px_vector), Object_Py(Py_vector), Object_Pz(Pz_vector), Object_E(E_vector),
30 if(
Object_Px.size() < 2)
cout <<
"Error in Megajet: you should provide at least two jets to form Megajets" << endl;
31 for(
int j=0;
j<(int)
jIN.size(); ++
j) {
74 int N_JETS = (int)
jIN.size();
77 for(
int i = 0;
i < N_JETS;
i++){
89 for(
int j = 0;
j < 5; ++
j){
95 for(
int i = 1;
i < N_comb-1;
i++){
96 TLorentzVector j_temp1, j_temp2;
101 if(itemp/j_count == 1){
106 itemp -= j_count*(itemp/j_count);
111 j1.push_back(j_temp1);
112 j2.push_back(j_temp2);
119 TLorentzVector myJ1 = TLorentzVector(0,0,0,0);
120 TLorentzVector myJ2 = TLorentzVector(0,0,0,0);
121 for(
int i=0;
i<(int)
j1.size();
i++) {
122 double M_temp =
j1[
i].M2()+
j2[
i].M2();
123 if(M_min < 0 || M_temp < M_min){
133 if(myJ1.Pt() > myJ2.Pt()){
134 jOUT.push_back(myJ1);
135 jOUT.push_back(myJ2);
137 jOUT.push_back(myJ2);
138 jOUT.push_back(myJ1);
146 TLorentzVector myJ1 = TLorentzVector(0,0,0,0);
147 TLorentzVector myJ2 = TLorentzVector(0,0,0,0);
148 for(
int i=0;
i<(int)
j1.size();
i++) {
149 double M_temp =
j1[
i].M2()/
j1[
i].E()+
j2[
i].M2()/
j2[
i].E();
150 if(M_min < 0 || M_temp < M_min){
161 if(myJ1.Pt() > myJ2.Pt()){
162 jOUT.push_back(myJ1);
163 jOUT.push_back(myJ2);
165 jOUT.push_back(myJ2);
166 jOUT.push_back(myJ1);
172 double M_max = -10000;
174 TLorentzVector myJ1 = TLorentzVector(0,0,0,0);
175 TLorentzVector myJ2 = TLorentzVector(0,0,0,0);
176 for(
int i=0;
i<(int)
j1.size();
i++) {
178 double M_temp = (
j1[
i].E()-myBeta*
j1[
i].M2()/
j1[
i].E())+(
j2[
i].E()-myBeta*
j2[
i].M2()/
j2[
i].E());
179 if(M_max < -9999 || M_temp > M_max){
190 if(myJ1.Pt() > myJ2.Pt()){
191 jOUT.push_back(myJ1);
192 jOUT.push_back(myJ2);
194 jOUT.push_back(myJ2);
195 jOUT.push_back(myJ1);
201 double dHT_min = 999999999999999.0;
203 TLorentzVector myJ1 = TLorentzVector(0,0,0,0);
204 TLorentzVector myJ2 = TLorentzVector(0,0,0,0);
205 for(
int i=0;
i<(int)
j1.size();
i++) {
206 double dHT_temp = fabs(
j1[
i].E()-
j2[
i].E());
207 if(dHT_temp < dHT_min){
215 if(myJ1.Pt() > myJ2.Pt()){
216 jOUT.push_back(myJ1);
217 jOUT.push_back(myJ2);
219 jOUT.push_back(myJ2);
220 jOUT.push_back(myJ1);
std::vector< float > Object_E
void CombineGeorgi()
Combining the jets in two hemispheres by maximizing (E1-Beta*m1^2/E1 + E2-Beta*m1^2/E2) ...
std::vector< float > Object_Pz
std::vector< TLorentzVector > jIN
std::vector< float > getAxis2()
std::vector< float > Axis2
std::vector< TLorentzVector > jOUT
std::vector< TLorentzVector > j1
std::vector< TLorentzVector > j2
std::vector< float > Object_Py
std::vector< float > Object_Px
std::vector< float > Axis1
std::vector< float > getAxis1()
void Combine()
Combine the jets in all the possible pairs of hemispheres.
void CombineMinEnergyMass()
Combining the jets in two hemispheres by minimizing m1^2/E1 + m2^2/E2.