Invisible3.hh
Go to the documentation of this file.
1 #pragma once
2 
3 // *********************************************************************************
4 // WIMPMASS
5 // version 1.00
6 //
7 // Authors: Hsin-Chia Cheng, John Gunion, Zhenyu Han, Bob McElrath, Dalit Engelhardt
8 //
9 // *********************************************************************************
10 // This package contains two C++ subroutines useful for event
11 // reconstruction in events with missing particles. The references
12 // are arXiv: 0707.0030 and arXiv: 0802.4290.
13 //
14 // The two functions are given in "topology22.cpp" and "topology33.cpp"
15 // in the "src/" directory. See the header of the source file for usage.
16 // "ROOT" (http://root.cern.ch/drupal/) is required for compiling
17 // topology33.cpp. The directory "examples/" contains a couple of examples
18 // calling these subroutines. You need to modify the Makefile in the "src"
19 // directory and "examples" directory to point to the correct ROOT location.
20 
21 namespace wimpmass{
22 
23 struct event33 {
24  double p3[4], p4[4], p5[4], p6[4], p7[4], p8[4];
25  double pmiss[4];
26 };
27 
28 void solve33(event33& evt1, event33& evt2, int& nsols, double p1[][4], double p2[][4], double q1[][4], double q2[][4]);
29 
30 }
31 
32 // int main()
33 // {
34 // //read a data file in the lhe format
35 // //squark pair production, 4 lepton + 2 jet decay channel
36 // //each squark decays squark->neutralni2-> slepton->neutralino 1, giving 4 lepton + 2 jet per event
37 //
38 // ifstream datafile("sqsq_pythia_events.lhe");
39 // event33 evt[10000];
40 //
41 // int ievent;
42 // int MAXEVENT = 2;
43 // for( ievent = 0; ievent < MAXEVENT; ievent ++ )
44 // {
45 //
46 //
47 // //find the line containing <event>
48 // int i = 0;
49 // char line [1000];
50 // while( i == 0 )
51 // {
52 // datafile.getline( line, 999 );
53 // if( datafile.eof() ) break;
54 // if( strstr(line, "<event>") ) i = 1;
55 // }
56 //
57 //
58 // if(datafile.eof()) break;
59 //
60 //
61 // int npar, itemp;
62 // double dtemp1, dtemp2, dtemp3, dtemp4;
63 //
64 // //read the first line of an event
65 //
66 // datafile >> npar >> itemp >> dtemp1 >> dtemp2 >> dtemp3 >> dtemp4;
67 //
68 // //read npar lines
69 // int ic1, ic2, ic3, ic4, ic5, ic6;
70 // double ic7;
71 // double p[6];
72 // int njet = 0;
73 // int nlep = 0;
74 // for (int j=0;j<npar;j++)
75 // {
76 //
77 // datafile >> ic1 >> ic6 >> ic2 >> ic3 >> ic4 >> ic5 >>
78 // p[1] >> p[2] >> p[3] >> p[0] >> p[4] >> p[5] >> ic7;
79 //
80 // //ic1 is particle ID
81 // //ic6=1, stable
82 // p[0]=sqrt(p[1]*p[1]+p[2]*p[2]+p[3]*p[3]+p[4]*p[4]);
83 //
84 // //if ( ic6 != 1 ) continue;
85 //
86 // if ( abs(ic1) == 2 && ic6 == 2 )
87 // {
88 // if ( ic2 == 3 )
89 // {
90 // for (int i = 0; i < 4; i ++)
91 // evt[ievent].p7[i] = p[i];
92 // }
93 // else if( ic2 == 4 )
94 // {
95 // for (int i = 0; i < 4; i ++)
96 // evt[ievent].p8[i] = p[i];
97 // }
98 // njet ++;
99 // }
100 //
101 // if (abs(ic1) == 11 || abs(ic1) == 13)
102 // {
103 // if ( nlep == 0 )
104 // {
105 // for (int i = 0; i < 4; i ++)
106 // evt[ievent].p5[i] = p[i];
107 // }
108 // else if( nlep == 1 )
109 // {
110 // for (int i = 0; i < 4; i ++)
111 // evt[ievent].p3[i] = p[i];
112 // }
113 // else if( nlep == 2 )
114 // {
115 // for (int i = 0; i < 4; i ++)
116 // evt[ievent].p6[i] = p[i];
117 // }
118 // else if( nlep == 3 )
119 // {
120 // for (int i = 0; i < 4; i ++)
121 // evt[ievent].p4[i] = p[i];
122 // }
123 // nlep ++;
124 // }
125 //
126 // if (abs(ic1) == 12)
127 // {
128 // for (int i = 0; i < 4; i ++)
129 // evt[ievent].pmiss[i] = p[i];
130 //
131 // }
132 // }
133 // }
134 //
135 // int nevent = ievent;
136 // cout << "Read from data file: sqsq_pythia_events.lhe" << '\n';
137 // cout << "Number of events = " << nevent << '\n';
138 // datafile.close();
139 //
140 // //test the first pair of events by solve33
141 // cout << '\n' << "Now test the 33 algorithm." << '\n';
142 // cout << "Test the first pair of events." << '\n';
143 // cout << '\n';
144 // //loop over events
145 // nevent = 2;
146 // for (int ievent1 = 0; ievent1 < nevent -1; ievent1 ++)
147 // for (int ievent2 = ievent + 1; ievent1 < nevent; ievent2 ++)
148 // {
149 //
150 // cout << "Visible momenta and the missing transverse momentum:" << '\n' << '\n';
151 // cout << "event 0" << '\n';
152 // ievent = ievent1;
153 // cout << "p3 = " << evt[ievent].p3[0] << " " << evt[ievent].p3[1] << " "
154 // << evt[ievent].p3[2] << " " << evt[ievent].p3[3] << '\n';
155 // cout << "p4 = " << evt[ievent].p4[0] << " " << evt[ievent].p4[1] << " "
156 // << evt[ievent].p4[2] << " " << evt[ievent].p4[3] << '\n';
157 // cout << "p5 = " << evt[ievent].p5[0] << " " << evt[ievent].p5[1] << " "
158 // << evt[ievent].p5[2] << " " << evt[ievent].p5[3] << '\n';
159 // cout << "p6 = " << evt[ievent].p6[0] << " " << evt[ievent].p6[1] << " "
160 // << evt[ievent].p6[2] << " " << evt[ievent].p6[3] << '\n';
161 // cout << "p7 = " << evt[ievent].p7[0] << " " << evt[ievent].p7[1] << " "
162 // << evt[ievent].p7[2] << " " << evt[ievent].p7[3] << '\n';
163 // cout << "p8 = " << evt[ievent].p8[0] << " " << evt[ievent].p8[1] << " "
164 // << evt[ievent].p8[2] << " " << evt[ievent].p8[3] << '\n';
165 // cout << "pmiss x,y = " << " " << evt[ievent].pmiss[1] << " " << evt[ievent].pmiss[2] << '\n';
166 // cout << "event 1" << '\n';
167 // ievent = ievent2;
168 // cout << "q3 = " << evt[ievent].p3[0] << " " << evt[ievent].p3[1] << " "
169 // << evt[ievent].p3[2] << " " << evt[ievent].p3[3] << '\n';
170 // cout << "q4 = " << evt[ievent].p4[0] << " " << evt[ievent].p4[1] << " "
171 // << evt[ievent].p4[2] << " " << evt[ievent].p4[3] << '\n';
172 // cout << "q5 = " << evt[ievent].p5[0] << " " << evt[ievent].p5[1] << " "
173 // << evt[ievent].p5[2] << " " << evt[ievent].p5[3] << '\n';
174 // cout << "q6 = " << evt[ievent].p6[0] << " " << evt[ievent].p6[1] << " "
175 // << evt[ievent].p6[2] << " " << evt[ievent].p6[3] << '\n';
176 // cout << "q7 = " << evt[ievent].p7[0] << " " << evt[ievent].p7[1] << " "
177 // << evt[ievent].p7[2] << " " << evt[ievent].p7[3] << '\n';
178 // cout << "q8 = " << evt[ievent].p8[0] << " " << evt[ievent].p6[1] << " "
179 // << evt[ievent].p8[2] << " " << evt[ievent].p8[3] << '\n';
180 // cout << "qmiss x,y = " << " " << evt[ievent].pmiss[1] << " " << evt[ievent].pmiss[2] << '\n';
181 //
182 // double P1[9][4], P2[9][4], Q1[9][4], Q2[9][4];
183 // int nsols;
184 // solve33(evt[0], evt[1], nsols, P1, P2, Q1, Q2);
185 // cout << '\n' << "number of solutions = " << nsols << '\n';
186 // for (int isol = 0; isol < nsols; isol ++)
187 // {
188 // cout << '\n' <<"solution " << isol << '\n';
189 //
190 // cout << "p1 = " << P1[isol][0] << " " << P1[isol][1]<< " "
191 // << P1[isol][2] << " " << P1[isol][3] << '\n';
192 // cout << "p2 = " << P2[isol][0] << " " << P2[isol][1]<< " "
193 // << P2[isol][2] << " " << P2[isol][3] << '\n';
194 // cout << "q1 = " << Q1[isol][0] << " " << Q1[isol][1]<< " "
195 // << Q1[isol][2] << " " << Q1[isol][3] << '\n';
196 // cout << "q2 = " << Q2[isol][0] << " " << Q2[isol][1]<< " "
197 // << Q2[isol][2] << " " << Q2[isol][3] << '\n';
198 // double mn, mx, my, mz;
199 //
200 // double p31[4], p531[4], p7531[4];
201 // for (int i = 0; i < 4; i ++)
202 // {
203 // p31[i] = P1[isol][i] + evt[0].p3[i];
204 // p531[i] = p31[i] + evt[0].p5[i];
205 // p7531[i] = p531[i] + evt[0].p7[i];
206 // }
207 // mn = sqrt(dot(P1[isol], P1[isol]));
208 // mx = sqrt(dot(p31, p31));
209 // my = sqrt(dot(p531, p531));
210 // mz = sqrt(dot(p7531, p7531));
211 // cout << "mn = " << mn << " mx = " << mx << " my = " << my << " mz = " << mz << '\n';
212 // }
213 // }
214 // }
double p3[4]
Definition: Invisible3.hh:24
void solve33(event33 &evt1, event33 &evt2, int &nsols, double p1[][4], double p2[][4], double q1[][4], double q2[][4])
Definition: Invisible3.cpp:67
double p6[4]
Definition: Invisible3.hh:24
double pmiss[4]
Definition: Invisible3.hh:25
double p7[4]
Definition: Invisible3.hh:24
Wimpmass contains a few packages useful for determining the mass of the dark matter particle at the L...
Definition: Invisible2.cpp:51
Definition: Invisible3.hh:23
double p4[4]
Definition: Invisible3.hh:24
double p5[4]
Definition: Invisible3.hh:24
double p8[4]
Definition: Invisible3.hh:24