/home/bes3soft/bes3soft/Boss/7.0.2/dist/7.0.2/Reconstruction/MdcDedxAlg/MdcDedxAlg-00-06-57/MdcDedxAlg/MdcDedxTrk.h

Go to the documentation of this file.
00001 //    BesIII MDC dE/dx Reconstruction Module
00002 //    Class: MdcDedxTrk
00003 //    Created by Dayong WANG 2003/11
00004 
00005 #ifndef _INCLUDE_ExTrk_H
00006 #define _INCLUDE_ExTrk_H
00007 
00008 #ifndef _ExTrk_DEFINED_
00009 #define _ExTrk_DEFINED_
00010 #endif
00011 
00012 #include <cmath>
00013 #include <vector>
00014 
00015 #include "MdcRecEvent/RecMdcTrack.h"
00016 #include "MdcRecEvent/RecMdcKalTrack.h"
00017 #include "MdcRecEvent/RecMdcDedx.h"
00018 //#include "MdcDedxAlg/MdcDedxCorrection.h"
00019 
00020 class MdcDedxCorrection;
00021 class MdcDedxTrk
00022 {
00023 
00024     public:
00025         MdcDedxTrk( RecMdcTrack& trk );
00026         MdcDedxTrk( RecMdcKalTrack& trk_kal, int pid);
00027         MdcDedxTrk();
00028         ~MdcDedxTrk();
00029 
00030         void set_ExTrk(  RecMdcTrack& trk );
00031         void set_ExTrk_Kal(  RecMdcKalTrack& trk_kal, int pid);
00032 
00033         double cal_dedx(  float );
00034         double cal_dedx_bitrunc(float, int, int& );   
00035         double cal_dedx_median(  float );
00036         double cal_dedx_geometric(  float );
00037         double cal_dedx_geometric_trunc(  float );
00038         double cal_dedx_harmonic(  float );
00039         double cal_dedx_harmonic_trunc(  float );
00040         double cal_dedx_transform(  int );
00041         double cal_dedx_log(  float , int);   
00042         double SpaceChargeCorrec( double, double, int, double );
00043 
00044         void set_dEdx( int l, float dEdx_meas, int trkalg,int runflag, int vflag[3], double t0, vector<double> & DedxCurve_Parameter, vector<double> & DedxSigma_Parameter, MdcDedxCorrection*);
00045         void set_phlist( const vector<double>& phlist) {m_phlist = phlist;}
00046         void set_phlist_hit( const vector<double>& phlist) {m_phlist_hit = phlist;}
00047         void setVecDedxHits(const DedxHitRefVec& vecdedxhit) { m_vecdedxhit= vecdedxhit;} 
00048 
00049         vector<double> get_phlist(void) {return m_phlist;}
00050         vector<double> get_phlist_hit(void) {return m_phlist_hit;}
00051         DedxHitRefVec  getVecDedxHits() const {return m_vecdedxhit;}
00052 
00053         RecMdcTrack*  trk_ptr() const {return m_trk;}   
00054         RecMdcKalTrack*  trk_ptr_kal() const {return m_trk_kal;}
00055 
00056 
00057         int stat()const {return m_stat;}
00058         int trk_id()const {return m_trk_id;}
00059         //int trk_id_kal()const {return m_trk_id_kal;}                          
00060         int nsample()const {return m_nsample;}
00061         int quality()const {return m_quality;}
00062         double dedx()const {return m_dEdx;}
00063         int charge()const {return m_charge;}
00064         double P()const {return m_P;}
00065         double theta()const {return m_theta;}
00066         double phi()const {return m_phi;}
00067         double Pt()const {return m_P*std::sin(m_theta);}
00068         double expect(int pid)const;
00069         double exp_sigma(int pid)const;
00070         double prob(int pid)const;
00071         double chi_dedx(int pid) const;
00072         double* pexpect() {return dedx_exp;}
00073         double* pexp_sigma() {return ex_sigma;}
00074         double* pprob() {return pid_prob;}   
00075         double* pchi_dedx() {return chi_ex;}  
00076 
00077     private:
00078         double dedx_exp[5];
00079         double ex_sigma[5];
00080         double pid_prob[5];
00081         double chi_ex[5];
00082         double m_dEdx;
00083         float  m_truncate;
00084 
00085         RecMdcTrack* m_trk;
00086         RecMdcKalTrack* m_trk_kal;
00087         int m_stat;
00088         int m_trk_id;
00089         //int m_trk_id_kal;
00090         int m_quality;
00091         int m_charge;
00092         float m_P; 
00093         double m_theta;
00094         double m_phi;
00095         int m_nsample;   //all the hits on track;
00096         double m_pl_rp;       
00097 
00098         vector<double> m_phlist;
00099         vector<double> m_phlist_hit;
00100         DedxHitRefVec m_vecdedxhit;
00101 };
00102 
00103 //--------------------------------------------------------------------
00104 inline double MdcDedxTrk::expect( int pid) const 
00105 {
00106     if( pid >= 0 && pid < 5 ) return dedx_exp[pid];
00107     else return -1;
00108 }
00109 
00110 inline double MdcDedxTrk::exp_sigma( int pid) const 
00111 {
00112     if( pid >= 0 && pid < 5 ) return ex_sigma[pid];
00113     else return -1;
00114 }
00115 
00116 inline double MdcDedxTrk::prob( int pid) const 
00117 {
00118     if( pid >= 0 && pid < 5 ) return pid_prob[pid];
00119     else return -1;
00120 }
00121 
00122 inline double MdcDedxTrk::chi_dedx( int pid) const 
00123 {
00124     if( pid >= 0 && pid < 5 ) return chi_ex[pid];
00125     else return -1;
00126 }
00127 #endif

Generated on Tue Nov 29 23:13:26 2016 for BOSS_7.0.2 by  doxygen 1.4.7