BOSS 7.1.1
BESIII Offline Software System
Loading...
Searching...
No Matches
PionZeroList.h
Go to the documentation of this file.
1#ifndef Physics_Analysis_PionZeroList_H
2#define Physics_Analysis_PionZeroList_H
3
4#include <vector>
5#include <algorithm>
6#include "CLHEP/Vector/ThreeVector.h"
7#include "CLHEP/Vector/LorentzVector.h"
8using namespace CLHEP;
9using CLHEP::Hep3Vector;
10using CLHEP::HepLorentzVector;
11typedef std::vector<Hep3Vector> Vp3;
12typedef std::vector<HepLorentzVector> Vp4;
13
15 public:
16 PionZero(HepLorentzVector &vp_gam_1, int &index_gam_1, HepLorentzVector &vp_gam_2, int &index_gam_2);
18 int get_index(int i){ return i>0 ? m_index_2 : m_index_1; }
19 double get_mass() { return m_inv_mass; }
20 double get_goodness() { return m_goodness; }
21 void cal_goodness(int good_method); // 0: mass diff; 1: chi^2; 2: ...???
22 HepLorentzVector get_gam_vp(int i){return i>0 ? m_vp_2 : m_vp_1;}
23 HepLorentzVector get_pi0_vp(){return m_vp_total;}
24 private:
25 int m_index_1, m_index_2, m_good_method;
26 HepLorentzVector m_vp_1, m_vp_2, m_vp_total;
27 double m_goodness; // desribe how good of a pi0
28 double m_inv_mass;
29};
30
31
33 public:
34 PionZeroList(Vp4 &input_vp); // initial photon four-momentum list input
35 void set_cut(int index, double cut);
36 void sort(); // sort all pion0 list with goodness( lower is better )
37 void reduce(); // delete all the pion0 with re-used photons
38 void print(); // print all information in pion0 list
39 void refresh(); // after reduce and sort, we should refresh the mom list
40 int get_num_pi0(){ return m_num_pi0; }
41 Vp4 get_pi0_list(){ return m_pi0_vp; }
42
43 class f_less: public std::binary_function<PionZero, PionZero, bool>{
44 public:
45 result_type operator()(first_argument_type p1, second_argument_type p2){
46 return (result_type) (p1.get_goodness() < p2.get_goodness());
47 }
48 };
49
50 private:
51 Vp4 m_gam_vp, m_pi0_vp;
52 std::vector<PionZero> Vpi0_list;
53 double m_low_cut, m_high_cut; // mass cuts of pion0
54 int m_num_pi0;
55};
56
57#endif
double p1[4]
double p2[4]
std::vector< HepLorentzVector > Vp4
Definition Gam4pikp.cxx:53
std::vector< HepLorentzVector > Vp4
std::vector< Hep3Vector > Vp3
result_type operator()(first_argument_type p1, second_argument_type p2)
Vp4 get_pi0_list()
void set_cut(int index, double cut)
int get_num_pi0()
PionZeroList(Vp4 &input_vp)
int get_index(int i)
HepLorentzVector get_pi0_vp()
double get_goodness()
HepLorentzVector get_gam_vp(int i)
double get_mass()
void cal_goodness(int good_method)