00001 #ifndef ATNUTREEMODULE_H 00002 #define ATNUTREEMODULE_H 00003 00004 #include "JobControl/JobCModule.h" 00005 #include "TFile.h" 00006 #include "TTree.h" 00007 #include "TObjArray.h" 00008 #include "TString.h" 00009 00010 class JobCommand; 00011 class MomNavigator; 00012 00013 class AtNuTreeModule : public JobCModule, public TObject 00014 { 00015 public: 00016 AtNuTreeModule(); 00017 ~AtNuTreeModule(); 00018 00019 void BeginJob(); 00020 JobCResult Ana(const MomNavigator *mom); 00021 const Registry& DefaultConfig() const; 00022 void Config(const Registry &r); 00023 void HandleCommand(JobCommand *command); 00024 void EndJob(); 00025 00026 private: 00027 00028 TFile* fAtNuFile; 00029 TTree* fAtNuTree; 00030 TString fAtNuFileName; 00031 TObjArray fMCStrpList[500]; 00032 TObjArray fTotStrpList[500]; 00033 TObjArray fTrkStrpList[500]; 00034 TObjArray fShwStrpList[500]; 00035 00036 Int_t StrpExtr[8]; 00037 Int_t StrpCell[28]; 00038 00039 // snarl information 00040 Int_t run; // run number 00041 Int_t subrun; // subrun number 00042 Int_t snarl; // snarl number 00043 Int_t runtype; // run type (0=pedestal, 1=calinject, 2=normaldata) 00044 Int_t trigsrc; // trigger source 00045 Int_t date; 00046 Int_t time; 00047 Int_t timeframe; // timeframe number 00048 Double_t trigtimeraw; // trigger time (raw) 00049 Double_t trigtimecorr; // trigger time (corrected) 00050 00051 Int_t Ndigits; // N digits (strip>2p.e.) 00052 Int_t Nstrps; // N strips (strip>2p.e.) 00053 Int_t Nplns; // N planes (strip>2p.e.) 00054 Int_t Ustrps; // U strips (strip>2p.e.) 00055 Int_t Uplns; // U planes (strip>2p.e.) 00056 Int_t Vstrps; // V strips (strip>2p.e.) 00057 Int_t Vplns; // V planes (strip>2p.e.) 00058 Int_t begpln; // first plane (strip>2p.e.) 00059 Int_t endpln; // last plane (strip>2p.e.) 00060 Int_t Nmuplns; // true muon planes 00061 00062 Double_t totPH; // total pulseheight 00063 00064 // Monte Carlo truth 00065 Int_t IDnu; // MC nu (-14=mubar, -12=elbar, 12=el, 14=mu) 00066 Int_t IDact; // MC act (0=NC, 1=CC, ....) 00067 Int_t IDboson; // MC boson (23=Z0, 24=W) 00068 Int_t IDtarget; // MC target (2212=p, 2112=n) 00069 Int_t IDres; // MC res ( .... ) 00070 Double_t x; // MC x 00071 Double_t y; // MC y 00072 Double_t Q2; // MC q^2 00073 Double_t W2; // MC w^2 00074 Double_t Xsection; // MC interaction cross-section 00075 Double_t EMfrac; // EMFrac 00076 Double_t PnuX; // MC nu momentum X 00077 Double_t PnuY; // MC nu momentum Y 00078 Double_t PnuZ; // MC nu momentum Z 00079 Double_t Enu; // MC nu energy 00080 Double_t PmuX; // MC mu momentum X 00081 Double_t PmuY; // MC mu momentum Y 00082 Double_t PmuZ; // MC mu momentum Z 00083 Double_t Emu; // MC mu energy 00084 Double_t PelX; // MC el momentum X 00085 Double_t PelY; // MC el momentum Y 00086 Double_t PelZ; // MC el momentum Z 00087 Double_t Eel; // MC el energy 00088 Double_t PhadX; // MC had momentum X 00089 Double_t PhadY; // MC had momentum Y 00090 Double_t PhadZ; // MC had momentum Z 00091 Double_t Ehad; // MC had energy 00092 Double_t PtargX; // MC target momentum X 00093 Double_t PtargY; // MC target momentum Y 00094 Double_t PtargZ; // MC target momentum Z 00095 Double_t Etarg; // MC target energy 00096 Double_t vtxX; // MC vertex X 00097 Double_t vtxY; // MC vertex Y 00098 Double_t vtxZ; // MC vertex Z 00099 Double_t muvtxX; // MC mu vertex X 00100 Double_t muvtxY; // MC mu vertex Y 00101 Double_t muvtxZ; // MC mu vertex Z 00102 Double_t muvtxR; // MC mu vertex R 00103 Int_t muvtxpln; 00104 Double_t muendvtxX; 00105 Double_t muendvtxY; 00106 Double_t muendvtxZ; 00107 Double_t muendvtxR; 00108 Int_t muendvtxpln; 00109 Double_t mupbeg; 00110 Double_t mupend; 00111 00112 // track 00113 Int_t Ntrks; 00114 Int_t TRKlast; // last track 00115 Double_t TRKcputime; // cpu time 00116 Int_t TRKplns[3]; // N planes 00117 Int_t TRKstrps[3]; // N strips 00118 Int_t TRKdigits[3]; // Ndigits 00119 Int_t TRKvtxpln[3]; // vertex plane 00120 Int_t TRKbegpln[3]; // first plane 00121 Int_t TRKendpln[3]; // last plane 00122 Int_t TRKtrkplns[3]; // N track-like planes 00123 Double_t TRKtrkPH[3]; // total track pulseheight 00124 Double_t TRKshwPH[3]; // total other pulseheight 00125 Double_t TRKassocPH[3]; // total associated pulseheight 00126 Double_t TRKassocPHfrac[3]; // total associated pulseheight fraction 00127 Double_t TRKpbegX[3]; // direction at beg vertex X 00128 Double_t TRKpbegY[3]; // direction at beg vertex Y 00129 Double_t TRKpbegZ[3]; // direction at beg vertex Z 00130 Double_t TRKpendX[3]; // direction at end vertex X 00131 Double_t TRKpendY[3]; // direction at end vertex Y 00132 Double_t TRKpendZ[3]; // direction at end vertex Z 00133 Double_t TRKplinX[3]; // linear direction X 00134 Double_t TRKplinY[3]; // linear direction Y 00135 Double_t TRKplinZ[3]; // linear direction Z 00136 Double_t TRKbegvtxX[3]; // beg vertex X 00137 Double_t TRKbegvtxY[3]; // beg vertex Y 00138 Double_t TRKbegvtxZ[3]; // beg vertex Z 00139 Double_t TRKbegvtxR[3]; // beg vertex R 00140 Double_t TRKbegvtxRdigits[3]; // beg vertex R digits 00141 Int_t TRKbegplndigits[3]; // beg pln digits 00142 Double_t TRKbegtrace[3]; // beg vertex trace 00143 Double_t TRKbegtraceZ[3]; // beg vertex trace Z 00144 Double_t TRKbegvtxUwidth[3]; // beg vertex Uwidth 00145 Double_t TRKbegvtxUmean[3]; // beg vertex Umean 00146 Double_t TRKbegvtxVwidth[3]; // beg vertex Vwidth 00147 Double_t TRKbegvtxVmean[3]; // beg vertex Vmean 00148 Double_t TRKbegvtxRmax[3]; // beg vertex Rmax 00149 Double_t TRKbegvtxQmax[3]; // beg vertex Qmax 00150 Double_t TRKendvtxX[3]; // end vertex X 00151 Double_t TRKendvtxY[3]; // end vertex Y 00152 Double_t TRKendvtxZ[3]; // end vertex Z 00153 Double_t TRKendvtxR[3]; // end vertex R 00154 Double_t TRKendvtxRdigits[3]; // end vertex R digits 00155 Int_t TRKendplndigits[3]; // end pln digits 00156 Double_t TRKendtrace[3]; // end vertex trace 00157 Double_t TRKendtraceZ[3]; // end vertex trace Z 00158 Double_t TRKendvtxUwidth[3]; // end vertex Uwidth 00159 Double_t TRKendvtxUmean[3]; // end vertex Umean 00160 Double_t TRKendvtxVwidth[3]; // end vertex Vwidth 00161 Double_t TRKendvtxVmean[3]; // end vertex Vmean 00162 Double_t TRKendvtxRmax[3]; // end vertex Rmax 00163 Double_t TRKendvtxQmax[3]; // end vertex Qmax 00164 Double_t TRKdir[3]; // direction along track using time 00165 Double_t TRKdirTrue[3]; // true direction along track 00166 Double_t TRKdirTimeSlope[3]; // time slope 00167 Double_t TRKdirTimeScatter[3]; // time scatter 00168 Double_t TRKbegTimeFitRms[3];// beg time fit rms 00169 Int_t TRKbegTimeFitNdf[3]; // beg time fit ndf 00170 Double_t TRKendTimeFitRms[3];// end time fit rms 00171 Int_t TRKendTimeFitNdf[3]; // end time fit ndf 00172 Int_t TRKbegvtxshw[3]; // beg vtx shw 00173 Int_t TRKbegvtxshwstrips[3]; // beg vtx shw strips 00174 Int_t TRKbegvtxshwreseeded[3]; // beg vtx shw reseeded 00175 Int_t TRKendvtxshw[3]; // end vtx shw 00176 Int_t TRKendvtxshwstrips[3]; // end vtx shw strips 00177 Int_t TRKendvtxshwreseeded[3]; // end vtx shw reseeded 00178 Double_t TRKrange[3]; // range 00179 Double_t TRKrangeSteel[3]; // range through steel 00180 Double_t TRKmomentumRange[3]; // reconstructed momentum (using range) 00181 Double_t TRKscore[3]; // track quality 00182 Double_t TRKscoreMuEff[3]; // percentage of track hits that are muon hits 00183 Double_t TRKscoreMuPur[3]; // percentage of muon hits that are track hits 00184 Double_t TRKscorePiEff[3]; // percentage of track hits that are pion hits 00185 Double_t TRKscorePiPur[3]; // percentage of pion hits that are track hits 00186 Int_t TRKreseeded[3]; // reseeded 00187 00188 // fitted track 00189 Int_t Nfits; 00190 Int_t FITlast; // last track 00191 Double_t FITcputime[3]; // cpu time 00192 Int_t FITvtxpln[3]; // vertex plane 00193 Int_t FITbegpln[3]; // first plane 00194 Int_t FITendpln[3]; // last plane 00195 Double_t FITcharge[3]; // reconstructed charge (-1=neg, 1=pos) 00196 Double_t FITchisqlin[3]; // chi squared for linear fit 00197 Double_t FITchisq[3]; // chi squared for polynomial fit 00198 Double_t FITQPmean[3]; // Q/P mean 00199 Double_t FITQPerr[3]; // Q/P error 00200 Double_t FITQPcorr[3]; // Q/P corrected mean 00201 Double_t FITQPwidth[3]; // Q/P width 00202 Int_t FITQPplns[3]; // Q/P plns 00203 Double_t FITmomentumCurve[3]; // reconstructed energy (GeV) 00204 Double_t FITmomentumCurveErr[3]; 00205 Int_t FITpass[3]; 00206 00207 // shower 00208 Int_t Nshws; 00209 Int_t SHWlast; // last shower 00210 Double_t SHWcputime; // cpu time 00211 Int_t SHWplns[3]; // N planes 00212 Int_t SHWstrps[3]; // N strips 00213 Int_t SHWdigits[3]; // N digits 00214 Int_t SHWvtxpln[3]; // vertex plane 00215 Int_t SHWbegpln[3]; // first plane 00216 Int_t SHWendpln[3]; // last plane 00217 Double_t SHWtotPH[3]; // total pulse height 00218 Double_t SHWpshwX[3]; // direction X 00219 Double_t SHWpshwY[3]; // direction Y 00220 Double_t SHWpshwZ[3]; // direction Z 00221 Double_t SHWwidthU[3]; 00222 Double_t SHWwidthV[3]; 00223 Double_t SHWvtxX[3]; // vertex X 00224 Double_t SHWvtxY[3]; // vertex Y 00225 Double_t SHWvtxZ[3]; // vertex Z 00226 Double_t SHWdir[3]; // direction along shower using time (<0=going south, >0=going north) 00227 Double_t SHWdirTrue[3]; 00228 Int_t SHWvtxshw[3]; 00229 Double_t SHWdirTrk[3]; // direction along shower using vtx showers ( .... ) 00230 00231 Double_t SHWenergyPH[3]; // reconstructed energy (using pulse height) 00232 Double_t SHWenergyNstrps[3]; // reconstructed energy (using N strips) 00233 Int_t SHWreseeded[3]; // reseeded 00234 00235 ClassDef(AtNuTreeModule,1) 00236 }; 00237 00238 #endif
1.3.9.1