3#include "GaudiKernel/MsgStream.h"
4#include "GaudiKernel/AlgFactory.h"
5#include "GaudiKernel/ISvcLocator.h"
6#include "GaudiKernel/SmartDataPtr.h"
7#include "GaudiKernel/IDataProviderSvc.h"
8#include "GaudiKernel/PropertyMgr.h"
9#include "VertexFit/IVertexDbSvc.h"
10#include "GaudiKernel/Bootstrap.h"
11#include "GaudiKernel/ISvcLocator.h"
13#include "EventModel/EventModel.h"
14#include "EventModel/Event.h"
16#include "EvtRecEvent/EvtRecEvent.h"
17#include "EvtRecEvent/EvtRecTrack.h"
18#include "DstEvent/TofHitStatus.h"
19#include "EventModel/EventHeader.h"
22#include "GaudiKernel/INTupleSvc.h"
23#include "GaudiKernel/NTuple.h"
24#include "GaudiKernel/Bootstrap.h"
25#include "GaudiKernel/IHistogramSvc.h"
26#include "CLHEP/Vector/ThreeVector.h"
27#include "CLHEP/Vector/LorentzVector.h"
28#include "CLHEP/Vector/TwoVector.h"
30using CLHEP::Hep3Vector;
31using CLHEP::Hep2Vector;
32using CLHEP::HepLorentzVector;
33#include "CLHEP/Geometry/Point3D.h"
35#include "VertexFit/KinematicFit.h"
36#include "VertexFit/VertexFit.h"
37#include "VertexFit/IVertexDbSvc.h"
38#include "ParticleID/ParticleID.h"
41#include "DQASelDimu/DQASelDimu.h"
43#ifndef ENABLE_BACKWARDS_COMPATIBILITY
46using CLHEP::HepLorentzVector;
48const double mpi = 0.13957;
49const double mk = 0.493677;
50const double xmass[5] = {0.000511, 0.105658, 0.139570,0.493677, 0.938272};
51const double velc = 299.792458;
52typedef std::vector<int>
Vint;
53typedef std::vector<HepLorentzVector>
Vp4;
55static int counter[10]={0,0,0,0,0,0,0,0,0,0};
60 Algorithm(name, pSvcLocator) {
63 declareProperty(
"writentuple",m_writentuple =
false);
64 declareProperty(
"ecms",m_ecms = 3.097);
65 declareProperty(
"beamangle",m_beamangle = 0.022);
66 declareProperty(
"Vr0cut", m_vr0cut=1.0);
67 declareProperty(
"Vz0cut", m_vz0cut=8.0);
68 declareProperty(
"Coscut", m_coscut=0.93);
70 declareProperty(
"EnergyThreshold", m_energyThreshold=0.04);
71 declareProperty(
"GammaPhiCut", m_gammaPhiCut=20.0);
72 declareProperty(
"GammaThetaCut", m_gammaThetaCut=20.0);
73 declareProperty(
"GammaTrkCut", m_gammaTrkCut=20.0);
74 declareProperty(
"GammaTLCut", m_gammatlCut=0);
75 declareProperty(
"GammaTHCut", m_gammathCut=60);
77 declareProperty (
"acoll_mu_cut", m_acoll_mu_cut=6.);
78 declareProperty (
"acopl_mu_cut", m_acopl_mu_cut=6.);
79 declareProperty (
"poeb_mu_cut", m_poeb_mu_cut=0.3);
80 declareProperty (
"dtof_mu_cut", m_dtof_mu_cut=4.);
81 declareProperty (
"eoeb_mu_cut", m_eoeb_mu_cut=0.35);
82 declareProperty (
"etotal_mu_cut", m_etotal_mu_cut=0.6);
83 declareProperty (
"tpoebh_mu_cut", m_tpoebh_mu_cut=0.9);
84 declareProperty (
"tpoebl_mu_cut", m_tpoebl_mu_cut=0.7);
85 declareProperty (
"tptotal_mu_cut", m_tptotal_mu_cut=1.0);
90 declareProperty (
"m_useEMConly", m_useEMConly=
false);
91 declareProperty (
"m_usePID", m_usePID=
false);
92 declareProperty (
"m_useMDC", m_useMDC=
true);
93 declareProperty (
"m_useDEDX", m_useDEDX=
false);
94 declareProperty (
"m_useTOF", m_useTOF=
false);
95 declareProperty (
"m_useEMC", m_useEMC=
true);
96 declareProperty (
"m_useMUC", m_useMUC=
false);
103 MsgStream log(
msgSvc(), name());
105 log << MSG::INFO <<
"in initialize()" << endmsg;
107 status = service(
"THistSvc", m_thistsvc);
108 if(status.isFailure() ){
109 log << MSG::INFO <<
"Unable to retrieve pointer to THistSvc" << endreq;
116 m_mumu_mass =
new TH1F(
"mumu_mass",
"mumu_mass", 80, m_ecms-0.3, m_ecms+0.5);
117 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_mass", m_mumu_mass);
118 m_mumu_acoll =
new TH1F(
"mumu_acoll",
"mumu_acoll", 60, 0, 6 );
119 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_acoll", m_mumu_acoll);
120 m_mumu_eop_mup =
new TH1F(
"mumu_eop_mup",
"mumu_eop_mup", 100,0.,0.5 );
121 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_eop_mup", m_mumu_eop_mup);
122 m_mumu_eop_mum =
new TH1F(
"mumu_eop_mum",
"mumu_eop_mum", 100,0.,0.5 );
123 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_eop_mum", m_mumu_eop_mum);
124 m_mumu_costheta_mup =
new TH1F(
"mumu_costheta_mup",
"mumu_costheta_mup", 100,-1,1 );
125 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_costheta_mup", m_mumu_costheta_mup);
126 m_mumu_costheta_mum =
new TH1F(
"mumu_costheta_mum",
"mumu_costheta_mum", 100,-1,1 );
127 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_costheta_mum", m_mumu_costheta_mum);
129 m_mumu_phi_mup =
new TH1F(
"mumu_phi_mup",
"mumu_phi_mup", 120,-3.2,3.2 );
130 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_phi_mup", m_mumu_phi_mup);
131 m_mumu_phi_mum =
new TH1F(
"mumu_phi_mum",
"mumu_phi_mum", 120,-3.2,3.2 );
132 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_phi_mum", m_mumu_phi_mum);
134 m_mumu_nneu =
new TH1F(
"mumu_nneu",
"mumu_nneu", 5,0,5 );
135 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_nneu", m_mumu_nneu);
136 m_mumu_nlay =
new TH1F(
"mumu_nlay",
"mumu_nlay", 9,0,10 );
137 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_nlay", m_mumu_nlay);
138 m_mumu_nhit =
new TH1F(
"mumu_nhit",
"mumu_nhit", 19,0,20 );
139 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_nhit", m_mumu_nhit);
141 m_mumu_eemc_mup=
new TH1F(
"mumu_eemc_mup",
"mumu_eemc_mup",100,0.0,1.0);
142 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_eemc_mup", m_mumu_eemc_mup);
143 m_mumu_eemc_mum=
new TH1F(
"mumu_eemc_mum",
"mumu_eemc_mum",100,0.0,1.0);
144 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_eemc_mum", m_mumu_eemc_mum);
145 m_mumu_x_mup=
new TH1F(
"mumu_x_mup",
"mumu_x_mup",100,-1.0,1.0);
146 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_x_mup", m_mumu_x_mup);
147 m_mumu_y_mup=
new TH1F(
"mumu_y_mup",
"mumu_y_mup",100,-1.0,1.0);
148 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_y_mup", m_mumu_y_mup);
149 m_mumu_z_mup=
new TH1F(
"mumu_z_mup",
"mumu_z_mup",100,-10.0,10.0);
150 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_z_mup", m_mumu_z_mup);
151 m_mumu_x_mum=
new TH1F(
"mumu_x_mum",
"mumu_x_mum",100,-1.0,1.0);
152 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_x_mum", m_mumu_x_mum);
153 m_mumu_y_mum=
new TH1F(
"mumu_y_mum",
"mumu_y_mum",100,-1.0,1.0);
154 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_y_mum", m_mumu_y_mum);
155 m_mumu_z_mum=
new TH1F(
"mumu_z_mum",
"mumu_z_mum",100,-10.0,10.0);
156 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_z_mum", m_mumu_z_mum);
158 m_mumu_px_mup=
new TH1F(
"mumu_px_mup",
"mumu_px_mup",200,-2.0,2.0);
159 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_px_mup", m_mumu_px_mup);
160 m_mumu_py_mup=
new TH1F(
"mumu_py_mup",
"mumu_py_mup",200,-2.0,2.0);
161 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_py_mup", m_mumu_py_mup);
162 m_mumu_pz_mup=
new TH1F(
"mumu_pz_mup",
"mumu_pz_mup",200,-2.0,2.0);
163 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_pz_mup", m_mumu_pz_mup);
164 m_mumu_p_mup=
new TH1F(
"mumu_p_mup",
"mumu_p_mup",100,1.0,2.0);
165 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_p_mup", m_mumu_p_mup);
166 m_mumu_px_mum=
new TH1F(
"mumu_px_mum",
"mumu_px_mum",100,-2.0,2.0);
167 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_px_mum", m_mumu_px_mum);
168 m_mumu_py_mum=
new TH1F(
"mumu_py_mum",
"mumu_py_mum",100,-2.0,2.0);
169 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_py_mum", m_mumu_py_mum);
170 m_mumu_pz_mum=
new TH1F(
"mumu_pz_mum",
"mumu_pz_mum",100,-2.0,2.0);
171 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_pz_mum", m_mumu_pz_mum);
172 m_mumu_p_mum=
new TH1F(
"mumu_p_mum",
"mumu_p_mum",100,1.0,2.0);
173 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_p_mum", m_mumu_p_mum);
174 m_mumu_deltatof=
new TH1F(
"mumu_deltatof",
"mumu_deltatof",50,0.0,10.0);
175 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_deltatof", m_mumu_deltatof);
177 m_mumu_pidchidedx_mup=
new TH1F(
"mumu_pidchidedx_mup",
"mumu_pidchidedx_mup",160,-4,4);
178 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_pidchidedx_mup", m_mumu_pidchidedx_mup);
179 m_mumu_pidchidedx_mum=
new TH1F(
"mumu_pidchidedx_mum",
"mumu_pidchidedx_mum",160,-4,4);
180 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_pidchidedx_mum", m_mumu_pidchidedx_mum);
181 m_mumu_pidchitof1_mup=
new TH1F(
"mumu_pidchitof1_mup",
"mumu_pidchitof1_mup",160,-4,4);
182 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_pidchitof1_mup", m_mumu_pidchitof1_mup);
183 m_mumu_pidchitof1_mum=
new TH1F(
"mumu_pidchitof1_mum",
"mumu_pidchitof1_mum",160,-4,4);
184 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_pidchitof1_mum", m_mumu_pidchitof1_mum);
185 m_mumu_pidchitof2_mup=
new TH1F(
"mumu_pidchitof2_mup",
"mumu_pidchitof2_mup",160,-4,4);
186 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_pidchitof2_mup", m_mumu_pidchitof2_mup);
187 m_mumu_pidchitof2_mum=
new TH1F(
"mumu_pidchitof2_mum",
"mumu_pidchitof2_mum",160,-4,4);
188 status = m_thistsvc->regHist(
"/DQAHist/Dimu/mumu_pidchitof2_mum", m_mumu_pidchitof2_mum);
194NTuplePtr nt1(
ntupleSvc(),
"DQAFILE/Dimu");
195if ( nt1 ) m_tuple1 = nt1;
197 m_tuple1 =
ntupleSvc()->book (
"DQAFILE/Dimu", CLID_ColumnWiseTuple,
"N-Tuple");
199 status = m_tuple1->addItem (
"run", m_run);
200 status = m_tuple1->addItem (
"rec", m_rec);
201 status = m_tuple1->addItem (
"Nchrg", m_ncharg);
202 status = m_tuple1->addItem (
"Nneu", m_nneu,0,40);
203 status = m_tuple1->addItem (
"NGch", m_ngch, 0, 40);
204 status = m_tuple1->addItem (
"NGam", m_nGam);
207 status = m_tuple1->addItem (
"dimutag", m_dimutag);
209 status = m_tuple1->addItem (
"acoll", m_acoll);
210 status = m_tuple1->addItem (
"acopl", m_acopl);
211 status = m_tuple1->addItem (
"deltatof", m_deltatof);
212 status = m_tuple1->addItem (
"eop1", m_eop1);
213 status = m_tuple1->addItem (
"eop2", m_eop2);
214 status = m_tuple1->addItem (
"eoeb1", m_eoeb1);
215 status = m_tuple1->addItem (
"eoeb2", m_eoeb2);
216 status = m_tuple1->addItem (
"poeb1", m_poeb1);
217 status = m_tuple1->addItem (
"poeb2", m_poeb2);
218 status = m_tuple1->addItem (
"etoeb1", m_etoeb1);
219 status = m_tuple1->addItem (
"etoeb2", m_etoeb2);
220 status = m_tuple1->addItem (
"mucinfo1", m_mucinfo1);
221 status = m_tuple1->addItem (
"mucinfo2", m_mucinfo2);
224 status = m_tuple1->addIndexedItem (
"delang",m_nneu, m_delang);
225 status = m_tuple1->addIndexedItem (
"delphi",m_nneu, m_delphi);
226 status = m_tuple1->addIndexedItem (
"delthe",m_nneu, m_delthe);
227 status = m_tuple1->addIndexedItem (
"npart",m_nneu, m_npart);
228 status = m_tuple1->addIndexedItem (
"nemchits",m_nneu, m_nemchits);
229 status = m_tuple1->addIndexedItem (
"module",m_nneu, m_module);
230 status = m_tuple1->addIndexedItem (
"x",m_nneu, m_x);
231 status = m_tuple1->addIndexedItem (
"y",m_nneu, m_y);
232 status = m_tuple1->addIndexedItem (
"z",m_nneu, m_z);
233 status = m_tuple1->addIndexedItem (
"px",m_nneu, m_px);
234 status = m_tuple1->addIndexedItem (
"py",m_nneu, m_py);
235 status = m_tuple1->addIndexedItem (
"pz",m_nneu, m_pz);
236 status = m_tuple1->addIndexedItem (
"theta",m_nneu, m_theta);
237 status = m_tuple1->addIndexedItem (
"phi",m_nneu, m_phi);
238 status = m_tuple1->addIndexedItem (
"dx",m_nneu, m_dx);
239 status = m_tuple1->addIndexedItem (
"dy",m_nneu, m_dy);
240 status = m_tuple1->addIndexedItem (
"dz",m_nneu, m_dz);
241 status = m_tuple1->addIndexedItem (
"dtheta",m_nneu, m_dtheta);
242 status = m_tuple1->addIndexedItem (
"dphi",m_nneu, m_dphi);
243 status = m_tuple1->addIndexedItem (
"energy",m_nneu, m_energy);
244 status = m_tuple1->addIndexedItem (
"dE",m_nneu, m_dE);
245 status = m_tuple1->addIndexedItem (
"eSeed",m_nneu, m_eSeed);
246 status = m_tuple1->addIndexedItem (
"nSeed",m_nneu, m_nSeed);
247 status = m_tuple1->addIndexedItem (
"e3x3",m_nneu, m_e3x3);
248 status = m_tuple1->addIndexedItem (
"e5x5",m_nneu, m_e5x5);
249 status = m_tuple1->addIndexedItem (
"secondMoment",m_nneu, m_secondMoment);
250 status = m_tuple1->addIndexedItem (
"latMoment",m_nneu, m_latMoment);
251 status = m_tuple1->addIndexedItem (
"a20Moment",m_nneu, m_a20Moment);
252 status = m_tuple1->addIndexedItem (
"a42Moment",m_nneu, m_a42Moment);
253 status = m_tuple1->addIndexedItem (
"getTime",m_nneu, m_getTime);
254 status = m_tuple1->addIndexedItem (
"getEAll",m_nneu, m_getEAll);
258 status = m_tuple1->addIndexedItem(
"charge", m_ngch, m_charge);
259 status = m_tuple1->addIndexedItem (
"vx", m_ngch, m_vx0);
260 status = m_tuple1->addIndexedItem (
"vy", m_ngch, m_vy0);
261 status = m_tuple1->addIndexedItem (
"vz", m_ngch, m_vz0);
264 status = m_tuple1->addIndexedItem (
"px", m_ngch, m_px) ;
265 status = m_tuple1->addIndexedItem (
"py", m_ngch, m_py) ;
266 status = m_tuple1->addIndexedItem (
"pz", m_ngch, m_pz) ;
267 status = m_tuple1->addIndexedItem (
"p", m_ngch, m_p) ;
271 status = m_tuple1->addIndexedItem (
"kal_vx", m_ngch, m_kal_vx0);
272 status = m_tuple1->addIndexedItem (
"kal_vy", m_ngch, m_kal_vy0);
273 status = m_tuple1->addIndexedItem (
"kal_vz", m_ngch, m_kal_vz0);
276 status = m_tuple1->addIndexedItem (
"kal_px", m_ngch, m_kal_px) ;
277 status = m_tuple1->addIndexedItem (
"kal_py", m_ngch, m_kal_py) ;
278 status = m_tuple1->addIndexedItem (
"kal_pz", m_ngch, m_kal_pz) ;
279 status = m_tuple1->addIndexedItem (
"kal_p", m_ngch, m_kal_p) ;
282 status = m_tuple1->addIndexedItem (
"probPH" , m_ngch, m_probPH) ;
283 status = m_tuple1->addIndexedItem (
"normPH" , m_ngch, m_normPH) ;
284 status = m_tuple1->addIndexedItem (
"chie" , m_ngch, m_chie) ;
285 status = m_tuple1->addIndexedItem (
"chimu" , m_ngch, m_chimu) ;
286 status = m_tuple1->addIndexedItem (
"chipi" , m_ngch, m_chipi) ;
287 status = m_tuple1->addIndexedItem (
"chik" , m_ngch, m_chik) ;
288 status = m_tuple1->addIndexedItem (
"chip" , m_ngch, m_chip) ;
289 status = m_tuple1->addIndexedItem (
"ghit" , m_ngch, m_ghit) ;
290 status = m_tuple1->addIndexedItem (
"thit" , m_ngch, m_thit) ;
292 status = m_tuple1->addIndexedItem (
"e_emc" , m_ngch, m_e_emc) ;
293 status = m_tuple1->addIndexedItem (
"phi_emc" , m_ngch, m_phi_emc) ;
294 status = m_tuple1->addIndexedItem (
"theta_emc" , m_ngch, m_theta_emc) ;
296 status = m_tuple1->addIndexedItem (
"nhit_muc" , m_ngch, m_nhit_muc) ;
297 status = m_tuple1->addIndexedItem (
"nlay_muc" , m_ngch, m_nlay_muc) ;
298 status = m_tuple1->addIndexedItem (
"t_btof" , m_ngch, m_t_btof );
299 status = m_tuple1->addIndexedItem (
"t_etof" , m_ngch, m_t_etof );
300 status = m_tuple1->addIndexedItem (
"qual_etof" , m_ngch, m_qual_etof );
301 status = m_tuple1->addIndexedItem (
"tof_etof" , m_ngch, m_tof_etof );
302 status = m_tuple1->addIndexedItem (
"te_etof" , m_ngch, m_te_etof );
303 status = m_tuple1->addIndexedItem (
"tmu_etof" , m_ngch, m_tmu_etof );
304 status = m_tuple1->addIndexedItem (
"tpi_etof" , m_ngch, m_tpi_etof );
305 status = m_tuple1->addIndexedItem (
"tk_etof" , m_ngch, m_tk_etof );
306 status = m_tuple1->addIndexedItem (
"tp_etof" , m_ngch, m_tp_etof );
308 status = m_tuple1->addIndexedItem (
"qual_btof1", m_ngch, m_qual_btof1 );
309 status = m_tuple1->addIndexedItem (
"tof_btof1" , m_ngch, m_tof_btof1 );
310 status = m_tuple1->addIndexedItem (
"te_btof1" , m_ngch, m_te_btof1 );
311 status = m_tuple1->addIndexedItem (
"tmu_btof1" , m_ngch, m_tmu_btof1 );
312 status = m_tuple1->addIndexedItem (
"tpi_btof1" , m_ngch, m_tpi_btof1 );
313 status = m_tuple1->addIndexedItem (
"tk_btof1" , m_ngch, m_tk_btof1 );
314 status = m_tuple1->addIndexedItem (
"tp_btof1" , m_ngch, m_tp_btof1 );
316 status = m_tuple1->addIndexedItem (
"qual_btof2", m_ngch, m_qual_btof2 );
317 status = m_tuple1->addIndexedItem (
"tof_btof2" , m_ngch, m_tof_btof2 );
318 status = m_tuple1->addIndexedItem (
"te_btof2" , m_ngch, m_te_btof2 );
319 status = m_tuple1->addIndexedItem (
"tmu_btof2" , m_ngch, m_tmu_btof2 );
320 status = m_tuple1->addIndexedItem (
"tpi_btof2" , m_ngch, m_tpi_btof2 );
321 status = m_tuple1->addIndexedItem (
"tk_btof2" , m_ngch, m_tk_btof2 );
322 status = m_tuple1->addIndexedItem (
"tp_btof2" , m_ngch, m_tp_btof2 );
323 status = m_tuple1->addIndexedItem (
"pidcode" , m_ngch, m_pidcode);
324 status = m_tuple1->addIndexedItem (
"pidprob" , m_ngch, m_pidprob);
325 status = m_tuple1->addIndexedItem (
"pidchiDedx" , m_ngch, m_pidchiDedx);
326 status = m_tuple1->addIndexedItem (
"pidchiTof1" , m_ngch, m_pidchiTof1);
327 status = m_tuple1->addIndexedItem (
"pidchiTof2" , m_ngch, m_pidchiTof2);
329 status = m_tuple1->addItem (
"px_cms_ep", m_px_cms_ep);
330 status = m_tuple1->addItem (
"py_cms_ep", m_py_cms_ep);
331 status = m_tuple1->addItem (
"pz_cms_ep", m_pz_cms_ep);
332 status = m_tuple1->addItem (
"e_cms_ep", m_e_cms_ep);
333 status = m_tuple1->addItem (
"cos_ep", m_cos_ep);
334 status = m_tuple1->addItem (
"px_cms_em", m_px_cms_em);
335 status = m_tuple1->addItem (
"py_cms_em", m_py_cms_em);
336 status = m_tuple1->addItem (
"pz_cms_em", m_pz_cms_em);
337 status = m_tuple1->addItem (
"e_cms_em", m_e_cms_em);
338 status = m_tuple1->addItem (
"cos_em", m_cos_em);
339 status = m_tuple1->addItem (
"mass_ee", m_mass_ee);
340 status = m_tuple1->addItem (
"emax", m_emax);
341 status = m_tuple1->addItem (
"esum", m_esum);
342 status = m_tuple1->addItem (
"npip", m_npip );
343 status = m_tuple1->addItem (
"npim", m_npim );
344 status = m_tuple1->addItem (
"nkp", m_nkp );
345 status = m_tuple1->addItem (
"nkm", m_nkm );
346 status = m_tuple1->addItem (
"np", m_np );
347 status = m_tuple1->addItem (
"npb", m_npb );
349 status = m_tuple1->addItem (
"nep", m_nep );
350 status = m_tuple1->addItem (
"nem", m_nem );
351 status = m_tuple1->addItem (
"nmup", m_nmup );
352 status = m_tuple1->addItem (
"nmum", m_nmum );
356 log << MSG::ERROR <<
" Cannot book N-tuple:" << long(m_tuple1) << endmsg;
357 return StatusCode::FAILURE;
365log << MSG::INFO <<
"successfully return from initialize()" <<endmsg;
366return StatusCode::SUCCESS;
375 setFilterPassed(
false);
376 const double beamEnergy = m_ecms/2.;
377 const HepLorentzVector
p_cms(m_ecms*
sin(m_beamangle*0.5),0.0,0.0,m_ecms);
378 const Hep3Vector
u_cms = -
p_cms.boostVector();
379 MsgStream log(
msgSvc(), name());
380 log << MSG::INFO <<
"in execute()" << endreq;
383 SmartDataPtr<Event::EventHeader> eventHeader(eventSvc(),
"/Event/EventHeader");
386 log << MSG::FATAL <<
"Could not find Event Header" << endreq;
387 return StatusCode::SUCCESS;
390 m_run = eventHeader->runNumber();
391 m_rec = eventHeader->eventNumber();
399 log << MSG::FATAL <<
"Could not find EvtRecEvent" << endreq;
400 return StatusCode::SUCCESS;
402 log << MSG::INFO <<
"ncharg, nneu, tottks = "
403 << evtRecEvent->totalCharged() <<
" , "
404 << evtRecEvent->totalNeutral() <<
" , "
405 << evtRecEvent->totalTracks() <<endreq;
407 m_ncharg = evtRecEvent->totalCharged();
409 m_nneu = evtRecEvent->totalNeutral();
414 HepSymMatrix Evx(3, 0);
416 Gaudi::svcLocator()->service(
"VertexDbSvc", vtxsvc);
426 Evx[0][0]=vv[0]*vv[0];
427 Evx[0][1]=vv[0]*vv[1];
428 Evx[1][1]=vv[1]*vv[1];
429 Evx[1][2]=vv[1]*vv[2];
430 Evx[2][2]=vv[2]*vv[2];
436 log << MSG::FATAL <<
"Could not find EvtRecTrackCol" << endreq;
437 return StatusCode::SUCCESS;
444 for(
int i = 0; i < evtRecEvent->totalCharged(); i++){
446 if(!(*itTrk)->isMdcTrackValid())
continue;
447 if(!(*itTrk)->isMdcKalTrackValid())
continue;
450 double pch=mdcTrk->
p();
451 double x0=mdcTrk->
x();
452 double y0=mdcTrk->
y();
453 double z0=mdcTrk->
z();
454 double phi0=mdcTrk->
helix(1);
458 double Rxy=(x0-xv)*
cos(phi0)+(y0-yv)*
sin(phi0);
463 if(fabs(z0) >= m_vz0cut)
continue;
464 if(fabs(Rxy) >= m_vr0cut)
continue;
467 if(fabs(m_vz0) >= m_vz0cut)
continue;
468 if(m_vr0 >= m_vr0cut)
continue;
474 nCharge += mdcTrk->
charge();
485 int nGood = iGood.size();
487 log << MSG::DEBUG <<
"ngood, totcharge = " << nGood <<
" , " << nCharge << endreq;
489 if((nGood != 2)||(nCharge!=0)){
490 return StatusCode::SUCCESS;
498 Vint ipip, ipim, iep,iem,imup,imum;
508 for(
int i = 0; i < m_ngch; i++) {
528 HepLorentzVector ptrk;
529 ptrk.setPx(mdcTrk->
px()) ;
530 ptrk.setPy(mdcTrk->
py()) ;
531 ptrk.setPz(mdcTrk->
pz()) ;
532 double p3 = ptrk.mag() ;
537 m_pidprob[i]=pid->
prob(1);
538 m_pidchiDedx[i]=pid->
chiDedx(1);
539 m_pidchiTof1[i]=pid->
chiTof1(1);
540 m_pidchiTof2[i]=pid->
chiTof2(1);
541 if(mdcTrk->
charge() > 0) {
542 imup.push_back(iGood[i]);
545 if (mdcTrk->
charge() < 0) {
546 imum.push_back(iGood[i]);
555 m_nmup = imup.size() ;
556 m_nmum = imum.size() ;
566 for(
int i = evtRecEvent->totalCharged(); i< evtRecEvent->totalTracks(); i++) {
567 if(i>=evtRecTrkCol->size())
break;
569 if(!(*itTrk)->isEmcShowerValid())
continue;
571 Hep3Vector emcpos(emcTrk->
x(), emcTrk->
y(), emcTrk->
z());
576 int module=emcTrk->
module();
577 double x = emcTrk->
x();
578 double y = emcTrk->
y();
579 double z = emcTrk->
z();
580 double dx = emcTrk->
dx();
581 double dy = emcTrk->
dy();
582 double dth = emcTrk->
dtheta();
583 double dph = emcTrk->
dphi();
584 double dz = emcTrk->
dz();
586 double dE = emcTrk->
dE();
587 double eSeed = emcTrk->
eSeed();
588 double e3x3 = emcTrk->
e3x3();
589 double e5x5 = emcTrk->
e5x5();
592 double getTime = emcTrk->
time();
593 double getEAll = emcTrk->
getEAll();
603 m_nemchits[iphoton]=
n;
604 m_npart[iphoton]=npart;
605 m_module[iphoton]=module;
606 m_theta[iphoton]=EmcPos.theta();
607 m_phi[iphoton]=EmcPos.phi();
614 m_dtheta[iphoton]=dth;
618 m_eSeed[iphoton]=eSeed;
619 m_nSeed[iphoton]=nseed;
620 m_e3x3[iphoton]=e3x3;
621 m_e5x5[iphoton]=e5x5;
622 m_secondMoment[iphoton]=secondMoment;
623 m_latMoment[iphoton]=latMoment;
624 m_getTime[iphoton]=getTime;
625 m_getEAll[iphoton]=getEAll;
626 m_a20Moment[iphoton]=a20Moment;
627 m_a42Moment[iphoton]=a42Moment;
639 for(
int j = 0; j < nGood; j++) {
643 if (!(*jtTrk)->isMdcTrackValid())
continue;
645 double jtcharge = jtmdcTrk->
charge();
646 if(!(*jtTrk)->isExtTrackValid())
continue;
651 double angd = extpos.angle(emcpos);
652 double thed = extpos.theta() - emcpos.theta();
653 double phid = extpos.deltaPhi(emcpos);
654 thed = fmod(thed+CLHEP::twopi+CLHEP::twopi+
pi, CLHEP::twopi) - CLHEP::pi;
655 phid = fmod(phid+CLHEP::twopi+CLHEP::twopi+
pi, CLHEP::twopi) - CLHEP::pi;
657 if(fabs(thed) < fabs(dthe)) dthe = thed;
658 if(fabs(phid) < fabs(dphi)) dphi = phid;
659 if(angd < dang) dang = angd;
669 dthe = dthe * 180 / (CLHEP::pi);
670 dphi = dphi * 180 / (CLHEP::pi);
671 dang = dang * 180 / (CLHEP::pi);
672 double eraw = emcTrk->
energy();
673 double phi = emcTrk->
phi();
674 double the = emcTrk->
theta();
676 m_delphi[iphoton]=dphi;
677 m_delthe[iphoton]=dthe;
678 m_delang[iphoton]=dang;
679 if(
energy < m_energyThreshold)
continue;
680 if(getTime>m_gammathCut||getTime<m_gammatlCut)
continue;
682 if(dang< m_gammaTrkCut)
continue;
685 if(iphoton>=40)
return StatusCode::SUCCESS;
688 int nGam = iGam.size();
700 for(
int i = 0; i < m_nGam; i++) {
702 if(!(*itTrk)->isEmcShowerValid())
continue;
704 double eraw = emcTrk->
energy();
705 double phi = emcTrk->
phi();
706 double the = emcTrk->
theta();
707 HepLorentzVector ptrk;
708 ex_gam+=eraw*
sin(the)*
cos(phi);
709 ey_gam+=eraw*
sin(the)*
sin(phi);
710 ez_gam+=eraw*
cos(the);
711 et_gam+=eraw*
sin(the);
736 for(
int i = 0; i < m_ngch; i++ ){
740 if(!(*itTrk)->isMdcTrackValid())
continue;
741 if(!(*itTrk)->isMdcKalTrackValid())
continue;
748 m_charge[ii] = mdcTrk->
charge();
749 m_vx0[ii] = mdcTrk->
x();
750 m_vy0[ii] = mdcTrk->
y();
751 m_vz0[ii] = mdcTrk->
z();
754 m_px[ii] = mdcTrk->
px();
755 m_py[ii] = mdcTrk->
py();
756 m_pz[ii] = mdcTrk->
pz();
757 m_p[ii] = mdcTrk->
p();
765 m_kal_vx0[ii] = mdcKalTrk->
x();
766 m_kal_vy0[ii] = mdcKalTrk->
y();
767 m_kal_vz0[ii] = mdcKalTrk->
z();
770 m_kal_px[ii] = mdcKalTrk->
px();
771 m_kal_py[ii] = mdcKalTrk->
py();
772 m_kal_pz[ii] = mdcKalTrk->
pz();
773 m_kal_p[ii] = mdcKalTrk->
p();
776 px_had+=mdcKalTrk->
px();
777 py_had+=mdcKalTrk->
py();
778 pz_had+=mdcKalTrk->
pz();
779 pt_had+=mdcKalTrk->
pxy();
780 p_had+=mdcKalTrk->
p();
781 e_had+=sqrt(mdcKalTrk->
p()*mdcKalTrk->
p()+mdcKalTrk->
mass()*mdcKalTrk->
mass());
783 double ptrk = mdcKalTrk->
p() ;
786 if((*itTrk)->isMdcDedxValid()) {
789 m_probPH[ii]= dedxTrk->
probPH();
790 m_normPH[ii]= dedxTrk->
normPH();
792 m_chie[ii] = dedxTrk->
chiE();
793 m_chimu[ii] = dedxTrk->
chiMu();
794 m_chipi[ii] = dedxTrk->
chiPi();
795 m_chik[ii] = dedxTrk->
chiK();
796 m_chip[ii] = dedxTrk->
chiP();
801 if((*itTrk)->isEmcShowerValid()) {
804 m_e_emc[ii] = emcTrk->
energy();
805 m_phi_emc[ii] = emcTrk->
phi();
806 m_theta_emc[ii] = emcTrk->
theta();
810 if((*itTrk)->isMucTrackValid()){
813 m_nhit_muc[ii] = mucTrk->
numHits() ;
818 if((*itTrk)->isTofTrackValid()) {
820 SmartRefVector<RecTofTrack> tofTrkCol = (*itTrk)->tofTrack();
822 SmartRefVector<RecTofTrack>::iterator iter_tof = tofTrkCol.begin();
824 for(;iter_tof != tofTrkCol.end(); iter_tof++ ) {
826 status->
setStatus((*iter_tof)->status());
829 if( (status->
is_cluster()) ) m_t_etof[ii] = (*iter_tof)->tof();
830 if( !(status->
is_counter()) ){
if(status)
delete status;
continue;}
831 if( status->
layer()!=0 ) {
if(status)
delete status;
continue;}
832 double path=(*iter_tof)->path();
833 double tof = (*iter_tof)->tof();
834 double ph = (*iter_tof)->ph();
835 double rhit = (*iter_tof)->zrhit();
836 double qual = 0.0 + (*iter_tof)->quality();
837 double cntr = 0.0 + (*iter_tof)->tofID();
839 for(
int j = 0; j < 5; j++) {
840 double gb = ptrk/
xmass[j];
841 double beta = gb/sqrt(1+gb*gb);
842 texp[j] = path /beta/
velc;
845 m_qual_etof[ii] = qual;
846 m_tof_etof[ii] = tof ;
849 if( (status->
is_cluster()) ) m_t_btof[ii] = (*iter_tof)->tof();
850 if( !(status->
is_counter()) ){
if(status)
delete status;
continue;}
851 if(status->
layer()==1){
852 double path=(*iter_tof)->path();
853 double tof = (*iter_tof)->tof();
854 double ph = (*iter_tof)->ph();
855 double rhit = (*iter_tof)->zrhit();
856 double qual = 0.0 + (*iter_tof)->quality();
857 double cntr = 0.0 + (*iter_tof)->tofID();
859 for(
int j = 0; j < 5; j++) {
860 double gb = ptrk/
xmass[j];
861 double beta = gb/sqrt(1+gb*gb);
862 texp[j] = path /beta/
velc;
865 m_qual_btof1[ii] = qual;
866 m_tof_btof1[ii] = tof ;
869 if(status->
layer()==2){
870 double path=(*iter_tof)->path();
871 double tof = (*iter_tof)->tof();
872 double ph = (*iter_tof)->ph();
873 double rhit = (*iter_tof)->zrhit();
874 double qual = 0.0 + (*iter_tof)->quality();
875 double cntr = 0.0 + (*iter_tof)->tofID();
877 for(
int j = 0; j < 5; j++) {
878 double gb = ptrk/
xmass[j];
879 double beta = gb/sqrt(1+gb*gb);
880 texp[j] = path /beta/
velc;
883 m_qual_btof2[ii] = qual;
884 m_tof_btof2[ii] = tof ;
887 if(status)
delete status;
899 if(m_ngch != 2 || nCharge != 0 )
return StatusCode::SUCCESS;
909 HepLorentzVector p41e,p42e,p4le;
910 Hep3Vector p31e,p32e,p3le;
911 HepLorentzVector p41m,p42m,p4lm;
912 Hep3Vector p31m,p32m,p3lm;
913 HepLorentzVector p41h,p42h,p4lh;
914 Hep3Vector p31h,p32h,p3lh;
919 for(
int i = 0; i < m_ngch; i++ ){
920 if(m_charge[i]>0)itTrk1= evtRecTrkCol->begin() + iGood[i];
921 if(m_charge[i]<0) itTrk2= evtRecTrkCol->begin() + iGood[i];
922 if(m_charge[i]>0) mdcKalTrk1 = (*itTrk1)->mdcKalTrack();
923 if(m_charge[i]<0) mdcKalTrk2 = (*itTrk2)->mdcKalTrack();
924 if(m_charge[i]>0)iip=i;
925 if(m_charge[i]<0)iim=i;
929 if(m_charge[i]<0) w2_ini=
WTrackParameter (
xmass[1],mdcKalTrk2 ->getZHelixMu(),mdcKalTrk2 ->getZErrorMu());
932 if(m_charge[i]>0) p41m =w1_ini.
p();
933 if(m_charge[i]<0) p42m =w2_ini.
p();
934 if(m_charge[i]>0) p41m.boost(
u_cms);
935 if(m_charge[i]<0) p42m.boost(
u_cms);
936 if(m_charge[i]>0) p31m = p41m.vect();
937 if(m_charge[i]<0) p32m = p42m.vect();
941 m_px_cms_ep=p41m.px();
942 m_py_cms_ep=p41m.py();
943 m_pz_cms_ep=p41m.pz();
947 m_px_cms_em=p42m.px();
948 m_py_cms_em=p42m.py();
949 m_pz_cms_em=p42m.pz();
956 double e01=(iip!=-1)?m_e_emc[iip]:0;
957 double e02=(iim!=-1)?m_e_emc[iim]:0;
958 int ilarge=( e01 > e02 ) ?iip:iim;
960 p4lm=( e01 > e02 ) ?p41m:p42m;
963 p3lm=( e01 > e02 ) ?p31m:p32m;
966 double acollm= 180.-p31m.angle(p32m)* 180.0 / CLHEP::pi;
967 double acoplm= 180.- (p31m.perpPart()).angle(p32m.perpPart ())* 180.0 / CLHEP::pi;
968 double poeb1m=p41m.rho()/beamEnergy;
969 double poeb2m=p42m.rho()/beamEnergy;
970 double poeblm=p4lm.rho()/beamEnergy;
972 double eemc1=m_e_emc[iip];
973 double eemc2=m_e_emc[iim];
976 double ex1=m_kal_vx0[iip];
977 double ey1=m_kal_vy0[iip];
978 double ez1=m_kal_vz0[iip];
979 double epx1=m_kal_px[iip];
980 double epy1=m_kal_py[iip];
981 double epz1=m_kal_pz[iip];
982 double epp1=m_kal_p[iip];
983 double ex2=m_kal_vx0[iim];
984 double ey2=m_kal_vy0[iim];
985 double ez2=m_kal_vz0[iim];
986 double epx2=m_kal_px[iim];
987 double epy2=m_kal_py[iim];
988 double epz2=m_kal_pz[iim];
989 double epp2=m_kal_p[iim];
991 double pidchidedx1=m_pidchiDedx[iip];
992 double pidchitof11= m_pidchiTof1[iip];
993 double pidchitof21= m_pidchiTof2[iip];
994 double pidchidedx2=m_pidchiDedx[iim];
995 double pidchitof12= m_pidchiTof1[iim];
996 double pidchitof22= m_pidchiTof2[iim];
998 double eoeb1=m_e_emc[iip]/beamEnergy;
999 double eoeb2=m_e_emc[iim]/beamEnergy;
1003 if(p41m.rho()>0)eopm1=m_e_emc[iip]/p41m.rho();
1005 if(p42m.rho()>0)eopm2=m_e_emc[iim]/p42m.rho();
1008 double exoeb1= m_e_emc[iip]*
sin(m_theta_emc[iip])*
cos(m_phi_emc[iip])/beamEnergy;
1009 double eyoeb1= m_e_emc[iip]*
sin(m_theta_emc[iip])*
sin(m_phi_emc[iip])/beamEnergy;
1010 double ezoeb1=m_e_emc[iip]*
cos(m_theta_emc[iip])/beamEnergy;
1011 double etoeb1=m_e_emc[iip]*
sin(m_theta_emc[iip])/beamEnergy;
1013 double exoeb2= m_e_emc[iim]*
sin(m_theta_emc[iim])*
cos(m_phi_emc[iim])/beamEnergy;
1014 double eyoeb2= m_e_emc[iim]*
sin(m_theta_emc[iim])*
sin(m_phi_emc[iim])/beamEnergy;
1015 double ezoeb2=m_e_emc[iim]*
cos(m_theta_emc[iim])/beamEnergy;
1016 double etoeb2=m_e_emc[iim]*
sin(m_theta_emc[iim])/beamEnergy;
1018 double eoebl=m_e_emc[ilarge]/beamEnergy;
1021 if(p4lm.rho()>0)eopl=m_e_emc[ilarge]/p4lh.rho();
1023 double exoebl= m_e_emc[ilarge]*
sin(m_theta_emc[ilarge])*
cos(m_phi_emc[ilarge])/beamEnergy;
1024 double eyoebl= m_e_emc[ilarge]*
sin(m_theta_emc[ilarge])*
sin(m_phi_emc[ilarge])/beamEnergy;
1025 double ezoebl=m_e_emc[ilarge]*
cos(m_theta_emc[ilarge])/beamEnergy;
1026 double etoebl=m_e_emc[ilarge]*
sin(m_theta_emc[ilarge])/beamEnergy;
1028 int mucinfo1=(m_nhit_muc[iip]>=2&&m_nlay_muc[iip]>=2 ) ? 1 : 0;
1029 int mucinfo2=(m_nhit_muc[iim]>=2&&m_nlay_muc[iim]>=2) ? 1 : 0;
1030 int mucinfol=(m_nhit_muc[ilarge]>=2&&m_nlay_muc[ilarge]>=2) ? 1 : 0;
1031 int pidel=( e01 > e02 ) ? m_nep : m_nem;
1032 int pidmul=( e01 > e02 ) ? m_nmup : m_nmum;
1035 if(m_t_btof[iip]*m_t_btof[iim]!=0) deltatof+=fabs(m_t_btof[iip]-m_t_btof[iim]);
1036 if(m_t_etof[iip]*m_t_etof[iim]!=0) deltatof+=fabs(m_t_etof[iip]-m_t_etof[iim]);
1039 if(acollm<m_acoll_mu_cut)m_dimutag+=1;
1040 if (acoplm<m_acopl_mu_cut)m_dimutag+=10;
1041 if (fabs(m_ecms-
mpsi2s)<0.001){
1042 if((sqrt(((poeb1m-poeb2m)/0.35)*((poeb1m-poeb2m)/0.35)+((poeb1m+poeb2m-1.68)/0.125)*((poeb1m+poeb2m-1.68)/0.125))>m_tptotal_mu_cut)
1043 &&(((poeb1m>=m_tpoebh_mu_cut)&&(poeb2m>=m_tpoebl_mu_cut))
1044 ||((poeb2m>=m_tpoebh_mu_cut)&&(poeb1m>=m_tpoebl_mu_cut))))m_dimutag+=100;
1047 if((fabs(poeb1m-1)<m_poeb_mu_cut)&&(fabs(poeb2m-1)<m_poeb_mu_cut))m_dimutag+=100;
1049 if(!m_useTOF||(deltatof<m_dtof_mu_cut))m_dimutag+=1000;
1050 if(!m_useMUC||(mucinfo1==1&&mucinfo2==1))m_dimutag+=10000;
1051 if(etoeb1<m_eoeb_mu_cut&&eoeb2<m_eoeb_mu_cut)m_dimutag+=100000;
1052 if(etoeb1+etoeb2<m_etotal_mu_cut)m_dimutag+=1000000;
1053 if(!m_usePID||(m_nmup==1&&m_nmum==1))m_dimutag+=10000000;
1067 m_cos_ep=p41m.cosTheta ();
1068 m_cos_em=p42m.cosTheta ();
1069 m_mass_ee=(p41m+p42m).m();
1071 m_deltatof=deltatof;
1078 m_mucinfo1=mucinfo1;
1079 m_mucinfo2=mucinfo2;
1081 if(m_dimutag==11111111){
1083 if(m_writentuple)m_tuple1 -> write();
1089 (*itTrk1)->setPartId(2);
1090 (*itTrk2)->setPartId(2);
1098 (*itTrk1)->setQuality(0);
1099 (*itTrk2)->setQuality(0);
1103 setFilterPassed(
true);
1108 m_mumu_mass->Fill((p41m+p42m).m());
1109 m_mumu_acoll->Fill(acollm);
1110 m_mumu_eop_mup->Fill(eopm1);
1111 m_mumu_eop_mum->Fill(eopm2);
1112 m_mumu_costheta_mup->Fill(p41m.cosTheta ());
1113 m_mumu_costheta_mum->Fill(p42m.cosTheta ());
1114 m_mumu_phi_mup->Fill(p41m.phi ());
1115 m_mumu_phi_mum->Fill(p42m.phi ());
1116 m_mumu_nneu->Fill(m_nGam);
1117 m_mumu_nhit->Fill(m_nhit_muc[ilarge]);
1118 m_mumu_nlay->Fill(m_nlay_muc[ilarge]);
1121 m_mumu_eemc_mup->Fill(eemc1);
1122 m_mumu_eemc_mum->Fill(eemc2);
1124 m_mumu_x_mup->Fill(ex1);
1125 m_mumu_y_mup->Fill(ey1);
1126 m_mumu_z_mup->Fill(ez1);
1128 m_mumu_x_mum->Fill(ex2);
1129 m_mumu_y_mum->Fill(ey2);
1130 m_mumu_z_mum->Fill(ez2);
1133 m_mumu_px_mup->Fill(epx1);
1134 m_mumu_py_mup->Fill(epy1);
1135 m_mumu_pz_mup->Fill(epz1);
1136 m_mumu_p_mup->Fill(epp1);
1138 m_mumu_px_mum->Fill(epx2);
1139 m_mumu_py_mum->Fill(epy2);
1140 m_mumu_pz_mum->Fill(epz2);
1141 m_mumu_p_mum->Fill(epp2);
1143 m_mumu_deltatof->Fill(deltatof);
1145 m_mumu_pidchidedx_mup->Fill(pidchidedx1);
1146 m_mumu_pidchidedx_mum->Fill(pidchidedx2);
1147 m_mumu_pidchitof1_mup->Fill(pidchitof11);
1148 m_mumu_pidchitof1_mum->Fill(pidchitof12);
1149 m_mumu_pidchitof2_mup->Fill(pidchitof21);
1150 m_mumu_pidchitof2_mum->Fill(pidchitof22);
1163 return StatusCode::SUCCESS;
1175 MsgStream log(
msgSvc(), name());
1176 log << MSG::INFO <<
"in finalize()" << endmsg;
1177 return StatusCode::SUCCESS;
const HepLorentzVector p_cms(0.034067, 0.0, 0.0, 3.097)
HepGeom::Point3D< double > HepPoint3D
std::vector< HepLorentzVector > Vp4
EvtRecTrackCol::iterator EvtRecTrackIterator
double sin(const BesAngle a)
double cos(const BesAngle a)
************Class m_ypar INTEGER m_KeyWgt INTEGER m_nphot INTEGER m_KeyGPS INTEGER m_IsBeamPolarized INTEGER m_EvtGenInterface DOUBLE PRECISION m_Emin DOUBLE PRECISION m_sphot DOUBLE PRECISION m_Xenph DOUBLE PRECISION m_q2 DOUBLE PRECISION m_PolBeam2 DOUBLE PRECISION m_xErrPb *COMMON c_KK2f $ !CMS energy average $ !Spin Polarization vector first beam $ !Spin Polarization vector second beam $ !Beam energy spread[GeV] $ !minimum hadronization energy[GeV] $ !input READ never touch them !$ !debug facility $ !maximum weight $ !inverse alfaQED $ !minimum real photon energy
DQASelDimu(const std::string &name, ISvcLocator *pSvcLocator)
double secondMoment() const
const Hep3Vector emcPosition() const
const int emcVolumeNumber() const
static void setPidType(PidType pidType)
const double mass() const
const HepVector helix() const
......
static unsigned int barrel_ec(const Identifier &id)
Values of different levels (failure returns 0)
virtual bool isVertexValid()=0
virtual double * SigmaPrimaryVertex()=0
virtual double * PrimaryVertex()=0
int methodProbability() const
void setChiMinCut(const double chi=4)
void setRecTrack(EvtRecTrack *trk)
void setMethod(const int method)
double chiTof2(int n) const
void identify(const int pidcase)
double probElectron() const
void usePidSys(const int pidsys)
static ParticleID * instance()
bool IsPidInfoValid() const
double chiTof1(int n) const
double probProton() const
double chiDedx(int n) const
RecEmcID getShowerId() const
RecEmcEnergy getEAll() const
HepVector & getZHelixMu()
HepSymMatrix & getZErrorMu()
unsigned int layer() const
void setStatus(unsigned int status)
HepLorentzVector p() const
_EXTERN_ std::string EvtRecEvent
_EXTERN_ std::string EvtRecTrackCol