Rivet analyses referenceCLEO_2006_I691720Cross section for light hadron production at 3.671 and 3.773 GeVExperiment: CLEO (CESR) Inspire ID: 691720 Status: VALIDATED Authors:
Beam energies: ANY Run details:
Cross section for $e^+e^-\to \pi^+\pi^-\pi^0$, $\rho^0\pi^0$, $\rho^\pm\pi^\mp$, $\omega\pi^0$, $\rho^0\eta$, $\omega\eta$, $\phi\eta$, $\rho^0\eta^\prime$, $\omega\eta^\prime$, $\phi\eta^\prime$, $K^{*0}\bar{K}^{*0}$, $K^{*\pm} K^\mp$, $b_1^0\pi^0$, $b_1^\pm\pi^\mp$ at 3.671 and 3.773 GeV Source code: CLEO_2006_I691720.cc 1// -*- C++ -*-
2#include "Rivet/Analysis.hh"
3#include "Rivet/Projections/FastJets.hh"
4#include "Rivet/Projections/UnstableParticles.hh"
5
6namespace Rivet {
7
8
9 /// @brief Add a short analysis description here
10 class CLEO_2006_I691720 : public Analysis {
11 public:
12
13 /// Constructor
14 RIVET_DEFAULT_ANALYSIS_CTOR(CLEO_2006_I691720);
15
16
17 /// @name Analysis methods
18 //@{
19
20 /// Book histograms and initialise projections before the run
21 void init() {
22
23 // Initialise and register projections
24 declare(FinalState(), "FS");
25 declare(UnstableParticles(), "UFS");
26
27 // Book histograms
28 for(unsigned int ix=1;ix<18;++ix) {
29 stringstream ss;
30 ss << "TMP/n" << ix;
31 book(_nMeson[ix], ss.str());
32 }
33 }
34
35 void findChildren(const Particle & p,map<long,int> & nRes, int &ncount) {
36 for (const Particle &child : p.children()) {
37 if(child.children().empty()) {
38 nRes[child.pid()]-=1;
39 --ncount;
40 }
41 else
42 findChildren(child,nRes,ncount);
43 }
44 }
45
46 /// Perform the per-event analysis
47 void analyze(const Event& event) {
48 const FinalState& fs = apply<FinalState>(event, "FS");
49
50 map<long,int> nCount;
51 int ntotal(0);
52 for (const Particle& p : fs.particles()) {
53 nCount[p.pid()] += 1;
54 ++ntotal;
55 }
56 if(ntotal==3) {
57 if(nCount[211]==1 && nCount[-211]==1 && nCount[111]==1)
58 _nMeson[1]->fill();
59 }
60 const FinalState& ufs = apply<FinalState>(event, "UFS");
61 for(unsigned int ix=0;ix<ufs.particles().size();++ix) {
62 const Particle& p1 = ufs.particles()[ix];
63 if(p1.children().empty()) continue;
64 if(p1.pid()!=113 && abs(p1.pid())!=313) continue;
65 map<long,int> nRes = nCount;
66 int ncount = ntotal;
67 findChildren(p1,nRes,ncount);
68 if(p1.pid()==113 || p1.pid()==223 || p1.pid()==10113) {
69 if(ncount!=1) continue;
70 bool matched = true;
71 for(auto const & val : nRes) {
72 if(abs(val.first)==111 && val.second!=1) {
73 matched = false;
74 break;
75 }
76 else if(val.second!=0) {
77 matched = false;
78 break;
79 }
80 }
81 if(matched) {
82 if(p1.pid()==113) {
83 _nMeson[2]->fill();
84 _nMeson[3]->fill();
85 }
86 else if(p1.pid()==223) {
87 _nMeson[5]->fill();
88 }
89 else if(p1.pid()==10113) {
90 _nMeson[15]->fill();
91 }
92 }
93 }
94 else if(p1.pid()==abs(113) || abs(p1.pid())==10113) {
95 if(ncount!=1) continue;
96 bool matched = true;
97 int ipi = p1.pid()>0 ? -211 : 211;
98 for(auto const & val : nRes) {
99 if(abs(val.first)==ipi && val.second!=1) {
100 matched = false;
101 break;
102 }
103 else if(val.second!=0) {
104 matched = false;
105 break;
106 }
107 }
108 if(matched) {
109 if(p1.pid()==abs(113)) {
110 _nMeson[2]->fill();
111 _nMeson[4]->fill();
112 }
113 else {
114 _nMeson[15]->fill();
115 _nMeson[17]->fill();
116 }
117 }
118 }
119 else if(p1.pid()==abs(323)) {
120 if(ncount!=1) continue;
121 bool matched = true;
122 int iK = p1.pid()==323 ? -321 : 321;
123 for(auto const & val : nRes) {
124 if(abs(val.first)==iK && val.second!=1) {
125 matched = false;
126 break;
127 }
128 else if(val.second!=0) {
129 matched = false;
130 break;
131 }
132 }
133 if(matched) {
134 _nMeson[14]->fill();
135 }
136 }
137 // second unstable particle
138 if(abs(p1.pid())!=313 && p1.pid()!=113 && p1.pid()!=223 &&
139 p1.pid()!=333 && p1.pid()!=221 && p1.pid()!=331)
140 continue;
141 for(unsigned int iy=ix+1;iy<ufs.particles().size();++iy) {
142 const Particle& p2 = ufs.particles()[iy];
143 map<long,int> nRes2 = nRes;
144 int ncount2 = ncount;
145 findChildren(p2,nRes2,ncount2);
146 if(ncount!=0) continue;
147 bool matched=true;
148 for(auto const & val : nRes2) {
149 if(val.second!=0) {
150 matched = false;
151 break;
152 }
153 }
154 if(!matched) continue;
155 if( (p1.pid()==113 && p2.pid()==221) ||
156 (p2.pid()==113 && p1.pid()==221) )
157 _nMeson[7]->fill();
158 else if( (p1.pid()==223 && p2.pid()==221) ||
159 (p2.pid()==223 && p1.pid()==221) )
160 _nMeson[8]->fill();
161 else if( (p1.pid()==333 && p2.pid()==221) ||
162 (p2.pid()==333 && p1.pid()==221) )
163 _nMeson[9]->fill();
164 else if( (p1.pid()==113 && p2.pid()==331) ||
165 (p2.pid()==113 && p1.pid()==331) )
166 _nMeson[10]->fill();
167 else if( (p1.pid()==223 && p2.pid()==331) ||
168 (p2.pid()==223 && p1.pid()==331) )
169 _nMeson[11]->fill();
170 else if( (p1.pid()==333 && p2.pid()==331) ||
171 (p2.pid()==333 && p1.pid()==331) )
172 _nMeson[12]->fill();
173 else if( (p1.pid()==313 && p2.pid()==-313) ||
174 (p2.pid()==313 && p1.pid()==-313) )
175 _nMeson[13]->fill();
176 }
177 }
178 }
179
180
181 /// Normalise histograms etc., after the run
182 void finalize() {
183 for(unsigned int ix=1;ix<18;++ix) {
184 if(ix==6||ix==16) continue;
185 double sigma = _nMeson[ix]->val();
186 double error = _nMeson[ix]->err();
187 sigma *= crossSection()/ sumOfWeights() /picobarn;
188 error *= crossSection()/ sumOfWeights() /picobarn;
189 Scatter2D temphisto(refData(1, 1, ix));
190 Scatter2DPtr mult;
191 book(mult, 1, 1, ix);
192 for (size_t b = 0; b < temphisto.numPoints(); b++) {
193 const double x = temphisto.point(b).x();
194 pair<double,double> ex = temphisto.point(b).xErrs();
195 pair<double,double> ex2 = ex;
196 if(ex2.first ==0.) ex2. first=0.0001;
197 if(ex2.second==0.) ex2.second=0.0001;
198 if (inRange(sqrtS()/GeV, x-ex2.first, x+ex2.second)) {
199 mult->addPoint(x, sigma, ex, make_pair(error,error));
200 }
201 else {
202 mult->addPoint(x, 0., ex, make_pair(0.,.0));
203 }
204 }
205 }
206 }
207
208 //@}
209
210
211 /// @name Histograms
212 //@{
213 CounterPtr _nMeson[18];
214 //@}
215
216
217 };
218
219
220 // The hook for the plugin system
221 RIVET_DECLARE_PLUGIN(CLEO_2006_I691720);
222
223
224}
|