BOSS 7.0.5
BESIII Offline Software System
Loading...
Searching...
No Matches
Sing.cxx
Go to the documentation of this file.
1//
2// Sing.cxx is the code to take care of some variables for anti-D0 tags for each single D0 tag mode.
3// It transfers these variables into a Class or Memmory, from which one can get these variables
4// for doing double tag analysis for study of the D0 meson decays. Sing.cxx was transfered
5// from the Fortran routine "Sing.f" which was orignally used for study of the D0D0-bar production
6// and D0 meson decays at the BES-II experiment during the time period from 2002 to 2008.
7//
8// The orignal Fortran routine "Sing.f" used at the BES-II experiment was coded by G. Rong in 2001.
9//
10// Sing.cxx was transfered by G. Rong and J. Liu in December, 2005.
11//
12// Since 2008, G. Rong and L.L. Jiang have been working on developing this code to analyze of
13// the data taken at 3.773 GeV with the BES-III detector at the BEPC-II collider.
14//
15// During developing this code, many People made significant contributions to this code. These are
16// G. Rong, L.L. Jiang, J. Liu, H.L. Ma, J.C. Chen, D.H. Zhang,
17// M.G. Zhao, B. Zheng, L. Li, Y. Fang, Z.Y. Yi, H.H. Liu, Z.Q. Liu et al.
18//
19// By G. Rong and L.L. Jiang
20// March, 2009
21//
22// ==========================================================================================
23//
24#include "SD0TagAlg/Sing.h"
25#include "SD0TagAlg/Kpi.h"
26#include "SD0TagAlg/Kpipi0.h"
27#include "SD0TagAlg/K3pi.h"
28#include "SD0TagAlg/K0pipi.h"
29#include "SD0TagAlg/K0pipipi0.h"
30#include "SD0TagAlg/K0pi0.h"
31#include "SD0TagAlg/Pipipi0.h"
32#include "SD0TagAlg/Kk.h"
33#include "SD0TagAlg/Pipi.h"
34#include "SD0TagAlg/Kkpipi.h"
35#include "SD0TagAlg/K0kpi.h"
36#include "SD0TagAlg/K0kk.h"
37#include "SD0TagAlg/Kkpi0.h"
38#include "SD0TagAlg/K3pipi0.h"
39#include "SD0TagAlg/Kpipi0pi0.h"
40// --------------------------------------------
41
42#include "SD0TagAlg/SingleBase.h"
43
44
46{}
47
49{}
50
51void Sing::Mdset(double event,SmartDataPtr<EvtRecTrackCol> evtRecTrkCol, Vint iGood,Vint iGam, int mdset, double Ebeam, int PID_flag, int Charge_candidate_D)
52{
53 oktg=false;
54
55 if(mdset==1) {
56 // ---- mode 11 ----- D0-->KPi ---------
57 Kpi kpi;
58 kpi.MTotal(event,evtRecTrkCol, iGood,iGam,Ebeam, PID_flag,Charge_candidate_D);
59 bool kpimd=kpi.Getkpimd();
60
61 if(kpimd) {
62 tagmd_temp=kpi.Gettagmd();
64 cqtm_temp = kpi.GetCQtm();
68 ptag_temp=kpi.Gettagp1();
69
70 oktg=true;
71
72 }
73 }
74
75 if(mdset==2) {
76 // ---- mode 12 ----- D0 --> KPiPi0---------
77 Kpipi0 kpipi0;
78 kpipi0.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
79 bool kpipi0md=kpipi0.Getkpipi0md();
80 if(kpipi0md) {
81 tagmd_temp=kpipi0.Gettagmd();
83 iGamtag_temp=kpipi0.GettagGam1();
84 ptag_temp=kpipi0.Gettagp1();
86 mass_bc_temp=kpipi0.Getmass_bc();
87 cqtm_temp = kpipi0.GetCQtm();
88
89 oktg=true;
90 }
91 }
92
93 if(mdset==4) {
94 // ---- mode 13 ----- D0-->K3Pi ---------
95 K3pi k3pi;
96 k3pi.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
97 bool k3pimd=k3pi.Getk3pimd();
98 if(k3pimd) {
99 tagmd_temp=k3pi.Gettagmd();
102 ptag_temp=k3pi.Gettagp1();
105 cqtm_temp = k3pi.GetCQtm();
106
107 oktg=true;
108 }
109 }
110
111 if(mdset==8) {
112 // ---- mode 14-----D0-->K0PiPi ---------
113 K0pipi k0pipi;
114 k0pipi.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
115 bool k0pipimd=k0pipi.Getk0pipimd();
116 if(k0pipimd) {
117 tagmd_temp=k0pipi.Gettagmd();
118 iGoodtag_temp=k0pipi.Gettagtrk1();
119 iGamtag_temp=k0pipi.GettagGam1();
120 ptag_temp=k0pipi.Gettagp1();
121 delE_tag_temp=k0pipi.GetdelE_tag();
122 mass_bc_temp=k0pipi.Getmass_bc();
123 cqtm_temp = k0pipi.GetCQtm();
124
125 oktg=true;
126 }
127 }
128
129 if(mdset==16) {
130 // ---- mode 15 ----- D0-->KK ---------
131 Kk kk;
132 kk.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
133 bool kkmd=kk.Getkkmd();
134 if(kkmd) {
135 tagmd_temp=kk.Gettagmd();
138 ptag_temp=kk.Gettagp1();
141 cqtm_temp = kk.GetCQtm();
142
143 oktg=true;
144 }
145 }
146
147 if(mdset==32) {
148 // ---- mode 16 ----- D0-->PiPiPi0 ---------
149 Pipipi0 pipipi0;
150 pipipi0.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
151 bool pipipi0md=pipipi0.GetPipipi0md();
152 if(pipipi0md) {
153 tagmd_temp=pipipi0.Gettagmd();
154 iGoodtag_temp=pipipi0.Gettagtrk1();
155 iGamtag_temp=pipipi0.GettagGam1();
156 ptag_temp=pipipi0.Gettagp1();
157 delE_tag_temp=pipipi0.GetdelE_tag();
158 mass_bc_temp=pipipi0.Getmass_bc();
159 cqtm_temp = pipipi0.GetCQtm();
160
161 oktg=true;
162 }
163 }
164
165
166
167 if(mdset==64) {
168 // ---- mode 17 ----- D0-->K0PiPiPi0 ---------
169 K0pipipi0 k0pipipi0;
170 k0pipipi0.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
171 bool k0pipipi0md=k0pipipi0.GetK0pipipi0md();
172 if(k0pipipi0md) {
173 tagmd_temp=k0pipipi0.Gettagmd();
174 iGoodtag_temp=k0pipipi0.Gettagtrk1();
175 iGamtag_temp=k0pipipi0.GettagGam1();
176 ptag_temp=k0pipipi0.Gettagp1();
177 delE_tag_temp=k0pipipi0.GetdelE_tag();
178 mass_bc_temp=k0pipipi0.Getmass_bc();
179 cqtm_temp = k0pipipi0.GetCQtm();
180
181 oktg=true;
182 }
183 }
184
185
186
187 if(mdset==128) {
188 // ---- mode 18 ----- D0-->K0Pi0 ---------
189 K0pi0 k0pi0;
190 k0pi0.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
191 bool k0pi0md=k0pi0.GetK0pi0md();
192 if(k0pi0md) {
193 tagmd_temp=k0pi0.Gettagmd();
195 iGamtag_temp=k0pi0.GettagGam1();
196 ptag_temp=k0pi0.Gettagp1();
198 mass_bc_temp=k0pi0.Getmass_bc();
199 cqtm_temp = k0pi0.GetCQtm();
200
201 oktg=true;
202 }
203 }
204
205
206 if(mdset==256)
207 {
208 // ---- mode 19 ----- D0-->Pi+Pi- mode -----
209 Pipi pipi;
210 pipi.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
211 bool pipimd = pipi.GetPipimd();
212 if(pipimd) {
213 tagmd_temp = pipi.Gettagmd();
214 iGoodtag_temp = pipi.Gettagtrk1();
216 ptag_temp = pipi.Gettagp1();
217 delE_tag_temp = pipi.GetdelE_tag();
218 mass_bc_temp = pipi.Getmass_bc();
219 cqtm_temp = pipi.GetCQtm();
220
221 oktg=true;
222 }
223 }
224
225 if(mdset==512)
226 {
227 // ---- mode 20 ----- D0-->K+K-Pi+Pi- mode -----
228 Kkpipi kkpipi;
229 kkpipi.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
230 bool kkpipimd = kkpipi.Getkkpipimd();
231 if(kkpipimd) {
232 tagmd_temp = kkpipi.Gettagmd();
233 iGoodtag_temp = kkpipi.Gettagtrk1();
234 iGamtag_temp=kkpipi.GettagGam1();
235 ptag_temp = kkpipi.Gettagp1();
236 delE_tag_temp = kkpipi.GetdelE_tag();
237 mass_bc_temp = kkpipi.Getmass_bc();
238 cqtm_temp = kkpipi.GetCQtm();
239
240 oktg=true;
241 }
242 }
243
244 if(mdset==1024)
245 {
246 // ---- mode 21 ----- D0-->K0K+Pi- mode -----
247 K0kpi k0kpi;
248 k0kpi.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
249 bool k0kpimd = k0kpi.Getk0kpimd();
250 if(k0kpimd) {
251 tagmd_temp = k0kpi.Gettagmd();
252 iGoodtag_temp = k0kpi.Gettagtrk1();
253 iGamtag_temp=k0kpi.GettagGam1();
254 ptag_temp = k0kpi.Gettagp1();
255 delE_tag_temp = k0kpi.GetdelE_tag();
256 mass_bc_temp = k0kpi.Getmass_bc();
257 cqtm_temp = k0kpi.GetCQtm();
258
259 oktg=true;
260 }
261 }
262
263 if(mdset==2048)
264 {
265 // ---- mode 22 ----- D0-->K0K+K- mode -----
266 K0kk k0kk;
267 k0kk.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
268 bool k0kkmd = k0kk.Getk0kkmd();
269 if(k0kkmd) {
270 tagmd_temp = k0kk.Gettagmd();
271 iGoodtag_temp = k0kk.Gettagtrk1();
273 ptag_temp = k0kk.Gettagp1();
274 delE_tag_temp = k0kk.GetdelE_tag();
275 mass_bc_temp = k0kk.Getmass_bc();
276 cqtm_temp = k0kk.GetCQtm();
277
278 oktg=true;
279 }
280 }
281
282 if(mdset==4096)
283 {
284 // ---- mode 23 ----- D0-->K-K+Pi0 mode -----
285 Kkpi0 kkpi0;
286 kkpi0.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
287 bool kkpi0md = kkpi0.Getkkpi0md();
288 if(kkpi0md) {
289 tagmd_temp = kkpi0.Gettagmd();
290 iGoodtag_temp = kkpi0.Gettagtrk1();
291 iGamtag_temp=kkpi0.GettagGam1();
292 ptag_temp = kkpi0.Gettagp1();
293 delE_tag_temp = kkpi0.GetdelE_tag();
294 mass_bc_temp = kkpi0.Getmass_bc();
295 cqtm_temp = kkpi0.GetCQtm();
296
297 oktg=true;
298 }
299 }
300
301 if(mdset==8192)
302 {
303 // ---- mode 24 ----- D0-->K-PiPiPiPi0 mode -----
304 K3pipi0 k3pipi0;
305 k3pipi0.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
306 bool k3pipi0md = k3pipi0.Getk3pipi0md();
307 if(k3pipi0md) {
308 tagmd_temp = k3pipi0.Gettagmd();
309 iGoodtag_temp = k3pipi0.Gettagtrk1();
310 iGamtag_temp = k3pipi0.GettagGam1();
311 ptag_temp = k3pipi0.Gettagp1();
312 delE_tag_temp = k3pipi0.GetdelE_tag();
313 mass_bc_temp = k3pipi0.Getmass_bc();
314 cqtm_temp = k3pipi0.GetCQtm();
315 oktg=true;
316 }
317 }
318
319 if(mdset==16384)
320 {
321 // ----mode 25 ----- D0-->K-PiPi0Pi0 mode -----
322 Kpipi0pi0 kpipi0pi0;
323 kpipi0pi0.MTotal(event,evtRecTrkCol, iGood,iGam, Ebeam, PID_flag,Charge_candidate_D);
324 bool kpipi0pi0md = kpipi0pi0.Getkpipi0pi0md();
325 if(kpipi0pi0md) {
326 tagmd_temp = kpipi0pi0.Gettagmd();
327 iGoodtag_temp = kpipi0pi0.Gettagtrk1();
328 iGamtag_temp = kpipi0pi0.GettagGam1();
329 ptag_temp = kpipi0pi0.Gettagp1();
330 delE_tag_temp = kpipi0pi0.GetdelE_tag();
331 mass_bc_temp = kpipi0pi0.Getmass_bc();
332 cqtm_temp = kpipi0pi0.GetCQtm();
333 oktg=true;
334 }
335 }
336
337 return;
338
339}
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: K0kk.cxx:33
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: K0kpi.cxx:34
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: K0pi0.cxx:34
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: K0pipi.cxx:34
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: K0pipipi0.cxx:34
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: K3pi.cxx:33
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: K3pipi0.cxx:33
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: Kk.cxx:32
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: Kkpi0.cxx:35
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: Kkpipi.cxx:33
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: Kpi.cxx:33
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: Kpipi0.cxx:33
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: Kpipi0pi0.cxx:36
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: Pipi.cxx:35
void MTotal(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: Pipipi0.cxx:35
void Mdset(double event, SmartDataPtr< EvtRecTrackCol > evtRecTrkCol, Vint iGood, Vint iGam, int mdset, double Ebeam, int PID_flag, int Charge_candidate_D)
Definition: Sing.cxx:51
Sing()
Definition: Sing.cxx:45
~Sing()
Definition: Sing.cxx:48