188 {
189 bool debug=0;
191 if(p->
getId()!=myvpho) {std::cout<<
"Parent particle is required to be vpho for Phokhara model"<<std::endl;abort();}
193 std::cout<<"PHOKHARA : Lambda anti-Lambda mode "<<std::endl;
194 }
196 if(debug)cout<<"init_evt works!"<<endl;
197 }
198
199 if(debug) {
200 std::cout<<"flags :ph0,nlo,pion,fsr,fsrnlo,ivac,FF_pion,f0_model,FF_kaon,narr_res,FF_pp,chi_sw,chi_pion,FF_Pgg,nlo2 "<<std::endl;
201 std::cout<<
"= "<<
flags_.ph0<<
","<<
flags_.nlo<<
","<<
flags_.pion<<
","<<
flags_.fsr<<
","<<
flags_.fsrnlo<<
","<<
flags_.ivac<<
","<<
flags_.FF_pion<<
","<<
flags_.f0_model<<
","<<
flags_.FF_kaon<<
","<<
flags_.narr_res<<
","<<
flags_.FF_pp<<
","<<
flags_.chi_sw<<
","<<
flags_.be_r<<
","<<
flags_.FF_Pgg<<
","<<
flags_.nlo2<<std::endl;
202 std::cout<<
"ctes: Sp = "<<
ctes_.Sp<<std::endl;
203 std::cout<<
"cuts : w,q2min,q2_min_c,gmin,phot1cut,phot2cut,pi1cut,pi2cut"<<std::endl<<
"= "<<
cuts_.w<<
","<<
cuts_.q2min<<
","<<
cuts_.q2_min_c<<
","<<
cuts_.gmin<<
","<<
cuts_.phot1cut<<
","<<
cuts_.phot2cut<<
","<<
cuts_.pi1cut<<
","<<
cuts_.pi2cut<<std::endl;
204 }
205
206
207
209 int ntrials = 0;
210 int tr_old[3];
211 tr_old[0] = (int)
maxima_.tr[0];
212 tr_old[1] = (int)
maxima_.tr[1];
213 tr_old[2] = (int)
maxima_.tr[2];
214
215 while( ntrials < 1000000)
216 {
217 ievent++;
219 Ar[1] = Ar_r[0];
220
224 }else
227 GEN_1PH(2,qqmin,qqmax,cos1min,cos1max,cos3min,cos3max);
228 }
229 else {
231 GEN_2PH(2,qqmin,cos1min,cos1max,cos2min,cos2max,cos3min,cos3max);
232 }
233
235 {
236 goto storedEvents;
237 }
238 ntrials ++;
239 }
240 std::cout <<"FATAL: Could not satisfy cuts after " << ntrials << "trials. Terminate." <<std::endl;
241
242 storedEvents:
243 int more=0;
244 int numstable=0;
245 int numparton=0;
246 EvtId evtnumstable[100];
248
249
251
254 numstable++;
255
258 numstable++;
259 }
261
264 numstable++;
265
268 numstable++;
269 }
271
274 numstable++;
275
278 numstable++;
279
282 numstable++;
283
286 numstable++;
287 }
289
292 numstable++;
293
296 numstable++;
297
300 numstable++;
301
304 numstable++;
305 }
307
310 numstable++;
311
314 numstable++;
315 }
317
320 numstable++;
321
324 numstable++;
325 }
327
330 numstable++;
331
334 numstable++;
335 }
337
340 numstable++;
341
344 numstable++;
345 }
347
350 numstable++;
351
354 numstable++;
355
358 numstable++;
359 }
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378 int LambdaDaus=0;
379 EvtId LambdaMode[100];
383
385
388 if (debug)std::cout<<
"Phokhara_Lambda: anti-Lambda0 p4[numstable] = "<<
p4[numstable]<<std::endl;
389 numstable++;
390
393 if (debug) std::cout<<
"Phokhara_Lambda: Lambda0 p4[numstable] = "<<
p4[numstable]<<std::endl;
394 numstable++;
395
396
399 if (debug) std::cout<<"Phokhara_Lambda: Pi+ p4[numstable] = "<<Lambdap4[LambdaDaus]<<std::endl;
400
401
402 tmp.
set(
p4[0].get(0),-
p4[0].get(1),-
p4[0].get(2),-
p4[0].get(3));
403 Lambdap4[LambdaDaus] =
boostTo(Lambdap4[LambdaDaus],tmp);
404 if (debug) std::cout<<"Phokhara_Lambda:Boosted Pi+ p4[numstable] = "<<Lambdap4[LambdaDaus]<<std::endl;
405 LambdaDaus++;
406
409 if (debug) std::cout<<"Phokhara_Lambda: pbar p4[numstable] = "<<Lambdap4[LambdaDaus]<<std::endl;
410
411
412
413 tmp.
set(
p4[0].get(0),-
p4[0].get(1),-
p4[0].get(2),-
p4[0].get(3));
414 Lambdap4[LambdaDaus] =
boostTo(Lambdap4[LambdaDaus],tmp);
415 if (debug) std::cout<<"Phokhara_Lambda:Boosted pbar p4[numstable] = "<<Lambdap4[LambdaDaus]<<std::endl;
416 LambdaDaus++;
417
420 if (debug) std::cout<<"Phokhara_Lambda: pi- p4[numstable] = "<<Lambdap4[LambdaDaus]<<std::endl;
421
422
423
424 tmp.
set(
p4[1].get(0),-
p4[1].get(1),-
p4[1].get(2),-
p4[1].get(3));
425 Lambdap4[LambdaDaus] =
boostTo(Lambdap4[LambdaDaus],tmp);
426 if (debug) std::cout<<"Phokhara_Lambda:Boosted pi- p4[numstable] = "<<Lambdap4[LambdaDaus]<<std::endl;
427 LambdaDaus++;
428
430 Lambdap4[LambdaDaus].
set(
ctes_.momenta[0][10],
ctes_.momenta[1][10],
ctes_.momenta[2][10],
ctes_.momenta[3][10]);
431 if (debug) std::cout<<"Phokhara_Lambda: p p4[numstable] = "<<Lambdap4[LambdaDaus]<<std::endl;
432
433
434
435 tmp.
set(
p4[1].get(0),-
p4[1].get(1),-
p4[1].get(2),-
p4[1].get(3));
436 Lambdap4[LambdaDaus] =
boostTo(Lambdap4[LambdaDaus],tmp);
437 if (debug) std::cout<<"Phokhara_Lambda:Boosted p p4[numstable] = "<<Lambdap4[LambdaDaus]<<std::endl;
438 LambdaDaus++;
439 }
440
441
444 if (debug) std::cout<<
"Phokhara_Lambda: first gamma p4[numstable] = "<<
p4[numstable]<<std::endl;
445 numstable++;
446 if(
ctes_.momenta[0][3] != 0 )
447 {
450 if (debug) std::cout<<
"Phokhara_Lambda: second gamma p4[numstable] = "<<
p4[numstable]<<std::endl;
451 numstable++;
452 }
453
455 more=(channel!=-1);
456 if(more) {std::cout<<"EvtPhokhara_Lambda:Existence of mode "<<channel<<" in exclusive decay list has the same final state as this one"<<std::endl;abort(); }
457
459
461
463 for(int i = 0; i< LambdaDaus;i++){
466 }
467 }
468 int ndaugFound=0;
470 for(int i=0;i<numstable;i++){
472 ndaugFound++;
473 }
474 if ( ndaugFound == 0 ) {
475 report(
ERROR,
"EvtGen") <<
"Phokhara has failed to do a decay ";
477 assert(0);
478 }
479 if (debug) std::cout<<
"EvtPhokhara_Lambda SUMMARY: part p4"<<p->
getP4Lab()<<std::endl;
480 if (debug) std::cout<<
"EvtPhokhara_Lambda SUMMARY: Daug0 p4"<<p->
getDaug(0)->
getP4Lab()<<std::endl;
481 if (debug) std::cout<<
"EvtPhokhara_Lambda SUMMARY: Daug1 p4"<<p->
getDaug(1)->
getP4Lab()<<std::endl;
482 if (debug) std::cout<<
"EvtPhokhara_Lambda SUMMARY: Daug2 p4"<<p->
getDaug(2)->
getP4Lab()<<std::endl;
483
484 nevtgen++;
485 return ;
486
487}
EvtDiracSpinor boostTo(const EvtDiracSpinor &sp, const EvtVector4R p4)
#define GEN_1PH(I, QQMIN, QQMAX, COS1MIN, COS1MAX, COS3MIN, COS3MAX)
#define GEN_0PH(I, QQMIN, SP, COS3MIN, COS3MAX)
#define GEN_2PH(I, QQMIN, COS1MIN, COS1MAX, COS2MIN, COS2MAX, COS3MIN, COS3MAX)
static int inChannelList(EvtId parent, int ndaug, EvtId *daugs)
static int getStdHep(EvtId id)
static EvtId evtIdFromStdHep(int stdhep)
static std::string name(EvtId i)
static EvtId getId(const std::string &name)
void makeDaughters(int ndaug, EvtId *id)
virtual void init(EvtId part_n, const EvtVector4R &p4)=0
static EvtId _NextLevelId[20]
static int _NextLevelDauNum
EvtParticle * getDaug(int i)
static EvtVector4R _NextLevelP4[20]
void init_evt(EvtParticle *p)
void init_mode(EvtParticle *p)
void set(int i, double d)
double double double * p4