66 std::cout <<
"EcalSimple2007H4TBAnalyzer: fetching hitCollection: " <<
hitCollection_.c_str() <<
" produced by "
112 h_ampltdc =
new TH2F(
"h_ampltdc",
"Max Amplitude vs TDC offset", 100, 0., 1., 1000, 0., 4000.);
115 h_tableIsMoving =
new TH1F(
"h_tableIsMoving",
"TableIsMoving", 100000, 0., 100000.);
117 h_e1x1 =
new TH1F(
"h_e1x1",
"E1x1 energy", 1000, 0., 4000.);
118 h_e3x3 =
new TH1F(
"h_e3x3",
"E3x3 energy", 1000, 0., 4000.);
119 h_e5x5 =
new TH1F(
"h_e5x5",
"E5x5 energy", 1000, 0., 4000.);
121 h_e1x1_center =
new TH1F(
"h_e1x1_center",
"E1x1 energy", 1000, 0., 4000.);
122 h_e3x3_center =
new TH1F(
"h_e3x3_center",
"E3x3 energy", 1000, 0., 4000.);
123 h_e5x5_center =
new TH1F(
"h_e5x5_center",
"E5x5 energy", 1000, 0., 4000.);
125 h_e1e9 =
new TH1F(
"h_e1e9",
"E1/E9 ratio", 600, 0., 1.2);
126 h_e1e25 =
new TH1F(
"h_e1e25",
"E1/E25 ratio", 600, 0., 1.2);
127 h_e9e25 =
new TH1F(
"h_e9e25",
"E9/E25 ratio", 600, 0., 1.2);
129 h_S6 =
new TH1F(
"h_S6",
"Amplitude S6", 1000, 0., 4000.);
131 h_bprofx =
new TH1F(
"h_bprofx",
"Beam Profile X", 100, -20., 20.);
132 h_bprofy =
new TH1F(
"h_bprofy",
"Beam Profile Y", 100, -20., 20.);
134 h_qualx =
new TH1F(
"h_qualx",
"Beam Quality X", 5000, 0., 5.);
135 h_qualy =
new TH1F(
"h_qualy",
"Beam Quality X", 5000, 0., 5.);
137 h_slopex =
new TH1F(
"h_slopex",
"Beam Slope X", 500, -5
e-4, 5
e-4);
138 h_slopey =
new TH1F(
"h_slopey",
"Beam Slope Y", 500, -5
e-4, 5
e-4);
142 for (
unsigned int icry = 0; icry < 25; icry++) {
143 sprintf(hname,
"h_mapx_%d", icry);
144 sprintf(htitle,
"Max Amplitude vs X %d", icry);
145 h_mapx[icry] =
new TH2F(hname, htitle, 80, -20, 20, 1000, 0., 4000.);
146 sprintf(hname,
"h_mapy_%d", icry);
147 sprintf(htitle,
"Max Amplitude vs Y %d", icry);
148 h_mapy[icry] =
new TH2F(hname, htitle, 80, -20, 20, 1000, 0., 4000.);
151 h_e1e9_mapx =
new TH2F(
"h_e1e9_mapx",
"E1/E9 vs X", 80, -20, 20, 600, 0., 1.2);
152 h_e1e9_mapy =
new TH2F(
"h_e1e9_mapy",
"E1/E9 vs Y", 80, -20, 20, 600, 0., 1.2);
154 h_e1e25_mapx =
new TH2F(
"h_e1e25_mapx",
"E1/E25 vs X", 80, -20, 20, 600, 0., 1.2);
155 h_e1e25_mapy =
new TH2F(
"h_e1e25_mapy",
"E1/E25 vs Y", 80, -20, 20, 600, 0., 1.2);
157 h_e9e25_mapx =
new TH2F(
"h_e9e25_mapx",
"E9/E25 vs X", 80, -20, 20, 600, 0., 1.2);
158 h_e9e25_mapy =
new TH2F(
"h_e9e25_mapy",
"E9/E25 vs Y", 80, -20, 20, 600, 0., 1.2);
160 h_Shape_ =
new TH2F(
"h_Shape_",
"Xtal in Beam Shape", 250, 0, 10, 350, 0, 3500);
197 for (
unsigned int icry = 0; icry < 25; icry++) {
275 evtHeader = pEventHeader.
product();
330 for (
unsigned int icry = 0; icry < 25; icry++) {
331 unsigned int row = icry / 5;
332 unsigned int column = icry % 5;
337 if (tempId.ix() < 16 || tempId.ix() > 35 || tempId.iy() < 51 || tempId.iy() > 75)
344 std::cout <<
"** Xtal in the matrix **** row " << row <<
", column " << column <<
", xtal " <<
Xtals5x5[icry]
345 <<
" Position " << cell->getPosition(0.) << std::endl;
354 std::cout <<
"Table is moving" << std::endl;
362 if (ithit->amplitude() >=
maxHit) {
363 maxHit = ithit->amplitude();
364 maxHitId = ithit->id();
368 std::cout <<
"No maxHit found" << std::endl;
373 double samples_save[10];
374 for (
int i = 0;
i < 10; ++
i)
375 samples_save[
i] = 0.0;
385 samples_save[
sample] = analogSample;
387 if (
eMax < analogSample) {
394 for (
int i = 0;
i < 10; ++
i)
399 double amplitude3x3 = 0;
400 double amplitude5x5 = 0;
401 for (
unsigned int icry = 0; icry < 25; icry++) {
406 if (icry == 6 || icry == 7 || icry == 8 || icry == 11 || icry == 12 || icry == 13 || icry == 16 || icry == 17 ||
415 h_e3x3->Fill(amplitude3x3);
416 h_e5x5->Fill(amplitude5x5);
420 h_e9e25->Fill(amplitude3x3 / amplitude5x5);
428 float x = recHodo->
posX();
429 float y = recHodo->
posY();
430 float xslope = recHodo->
slopeX();
431 float yslope = recHodo->
slopeY();
432 float xqual = recHodo->
qualX();
433 float yqual = recHodo->
qualY();
445 if (fabs(
x + 2.5) < 2.5 && fabs(
y + 0.5) < 2.5) {
451 for (
unsigned int icry = 0; icry < 25; icry++) {