]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PYTHIA8/pythia8170/htmldoc/ExternalDecays.html
Update to pythi8.170
[u/mrichter/AliRoot.git] / PYTHIA8 / pythia8170 / htmldoc / ExternalDecays.html
1 <html>
2 <head>
3 <title>External Decays</title>
4 <link rel="stylesheet" type="text/css" href="pythia.css"/>
5 <link rel="shortcut icon" href="pythia32.gif"/>
6 </head>
7 <body>
8
9 <h2>External Decays</h2>
10
11 <code>DecayHandler</code> is a base class for the external handling of 
12 decays. It is intended for normal particle decays, primarily 
13 <i>B</i> mesons and <i>tau</i>, and cannot be used to redirect
14 decays of heavy resonances like <i>t</i> or <i>Z^0</i>.  
15 The user-written derived class is called if a pointer to it has
16 been given with the 
17 <code><a href="ProgramFlow.html" target="page">pythia.decayPtr()</a></code> 
18 method, where it also is specified which particles it will be called for. 
19 This particle information is accessible with the
20 <code><a href="ParticleDataScheme.html" target="page">doExternalDecay()</a></code>
21 method. 
22
23 <p/>
24 There is only one pure virtual method in <code>DecayHandler</code>, 
25 to do the decay: 
26 <a name="method1"></a>
27 <p/><strong>virtual bool DecayHandler::decay(vector&lt;int&gt;&amp; idProd, vector&lt;double&gt;&amp; mProd, vector&lt;Vec4&gt;&amp; pProd, int iDec, const Event&amp; event) &nbsp;</strong> <br/>
28 where 
29 <br/><code>argument</code><strong> idProd </strong>  :  is a list of particle PDG identity codes,
30   
31 <br/><code>argument</code><strong> mProd </strong>  :  is a list of their respective masses (in GeV), and
32   
33 <br/><code>argument</code><strong> pProd </strong>  :  is a list of their respective four-momenta.
34   
35   
36
37 <p/>
38 At input, these vectors each have size one, so that <code>idProd[0]</code>, 
39 <code>mProd[0]</code> and <code>pProd[0]</code> contain information on the 
40 particle that is to be decayed. At output, the vectors should have 
41 increased by the addition of all the decay products. Even if initially 
42 defined in the rest frame of the mother, the products should have been 
43 boosted so that their four-momenta add up to the <code>pProd[0]</code> of 
44 the decaying particle. 
45
46 <p/>
47 Should it be of interest to know the prehistory of the decaying 
48 particle, e.g. to set some helicity information affecting the 
49 decay angular distribution, the full event record is available 
50 read-only, with info in which slot <code>iDec</code> the decaying particle 
51 is stored.
52
53 <p/>
54 The routine should return <code>true</code> if it managed the decay and 
55 <code>false</code> otherwise, in which case <code>Pythia</code> will try 
56 to do the decay itself. This e.g. means you can choose to do some decay 
57 channels yourself, and leave others to <code>Pythia</code>. To avoid
58 doublecounting, the channels you want to handle should be switched off
59 in the <code>Pythia</code> particle database. In the beginning of the  
60 external <code>decay</code> method you should then return 
61 <code>false</code> with a probability given by the sum of the branching
62 ratios for those channels you do not want to handle yourself.   
63
64 <p/>
65 Note that the decay vertex is always set by <code>Pythia</code>, and that 
66 <i>B-Bbar</i> oscillations have already been taken into account, 
67 if they were switched on. Thus <code>idProd[0]</code> may be the opposite 
68 of <code>event[iDec].id()</code>, where the latter provides the code at 
69 production.
70
71 <p/>
72 A sample test program is available in <code>main17.cc</code>, providing 
73 a simple example of how to use this facility.
74
75 </body>
76 </html>
77
78 <!-- Copyright (C) 2012 Torbjorn Sjostrand -->