11 std::stringstream str;
13 std::cout << str.str();
15 }
else if(slot == 0) {
16 std::stringstream str;
17 str <<
DRED <<
"No ppg provided, can't fill cycle spectra!" <<
RESET_COLOR << std::endl;
18 std::cout << str.str();
22 int energyBins = 10000;
23 double lowEnergy = 0.;
24 double highEnergy = 2000.;
26 fH2[slot][
"zdsMultGriffinMult"] =
new TH2I(
"zdsMultGriffinMult",
"ZDS multiplicity vs. GRIFFIN multiplicity (unsuppressed)", 65, -0.5, 64.5, 10, -0.5, 9.5);
29 fH1[slot][
"griffinE"] =
new TH1F(
"griffinE", Form(
"Unsuppressed griffin energy;energy [keV];counts/%.1f keV", (highEnergy - lowEnergy) / energyBins), energyBins, lowEnergy, highEnergy);
31 fH1[slot][
"griffinESupp"] =
new TH1F(
"griffinESupp", Form(
"Suppressed griffin energy;energy [keV];counts/%.1f keV", (highEnergy - lowEnergy) / energyBins), energyBins, lowEnergy, highEnergy);
33 fH1[slot][
"griffinEAddback"] =
new TH1F(
"griffinEAddback", Form(
"Unsuppressed griffin addback energy;energy [keV];counts/%.1f keV", (highEnergy - lowEnergy) / energyBins), energyBins, lowEnergy, highEnergy);
35 fH1[slot][
"griffinESuppAddback"] =
new TH1F(
"griffinESuppAddback", Form(
"Suppressed griffin addback energy;energy [keV];counts/%.1f keV", (highEnergy - lowEnergy) / energyBins), energyBins, lowEnergy, highEnergy);
36 fH1[slot][
"griffinESuppAddbackBeta"] =
new TH1F(
"griffinESuppAddbackBeta", Form(
"Suppressed griffin addback energy w/ #beta-tag;energy [keV];counts/%.1f keV", (highEnergy - lowEnergy) / energyBins), energyBins, lowEnergy, highEnergy);
37 fH2[slot][
"griffinESuppAddbackMatrixBeta"] =
new TH2F(
"griffinESuppAddbackMatrixBeta",
"Suppressed griffin addback energy matrix w/ #beta-tag;energy [keV];energy [keV]", energyBins / 5, lowEnergy, highEnergy, energyBins / 5, lowEnergy, highEnergy);
38 fH2[slot][
"griffinESuppAddbackMatrixBetaBg"] =
new TH2F(
"griffinESuppAddbackMatrixBetaBg",
"Suppressed griffin addback energy matrix w/ #beta-tag (time random BG);energy [keV];energy [keV]", energyBins / 5, lowEnergy, highEnergy, energyBins / 5, lowEnergy, highEnergy);
41 fH2[slot][
"griffinZdsTS"] =
new TH2F(
"griffinZdsTS",
"GRIFFIN crystal vs. GRIFFIN-ZDS timestamp difference (suppressed addback);#DeltaTS_{GRIFFIN-ZDS}", 200, -1000., 1000., 64, 0.5, 64.5);
42 fH2[slot][
"griffinZdsTime"] =
new TH2F(
"griffinZdsTime",
"GRIFFIN crystal vs. GRIFFIN-ZDS timing (suppressed addback);#Deltat_{GRIFFIN-ZDS}", 2000, -1000., 1000., 64, 0.5, 64.5);
43 fH2[slot][
"griffinGriffinTS"] =
new TH2F(
"griffinGriffinTS",
"GRIFFIN crystal vs. GRIFFIN-GRIFFIN timestamp difference (suppressed addback);#DeltaTS_{GRIFFIN-GRIFFIN}", 2000, -1000., 1000., 64, 0.5, 64.5);
44 fH2[slot][
"griffinGriffinTime"] =
new TH2F(
"griffinGriffinTime",
"GRIFFIN crystal vs. GRIFFIN-GRIFFIN timing (suppressed addback);#Deltat_{GRIFFIN-GRIFFIN}", 2000, -1000., 1000., 64, 0.5, 64.5);
48 fH2[slot][
"griffinCycle"] =
new TH2F(
"griffinCycle",
"GRIFFIN suppressed addback energy w/ #beta-tag vs. time in cycle;time in cycle [s];energy [keV]", 100 *
fCycleLength / 1e6, 0.,
fCycleLength / 1e6, energyBins / 5, lowEnergy, highEnergy);
49 fH1[slot][
"zdsCycle"] =
new TH1F(
"zdsCycle",
"ZDS hits in cycle;time in cycle [s]", 100 *
fCycleLength / 1e6, 0.,
fCycleLength / 1e6);
83 fH1[slot].at(
"griffinE")->Fill(grif1->GetEnergy());
89 fH1[slot].at(
"griffinESupp")->Fill(grif1->GetEnergy());
95 fH1[slot].at(
"griffinEAddback")->Fill(grif1->GetEnergy());
101 fH1[slot].at(
"griffinESuppAddback")->Fill(grif1->GetEnergy());
105 bool promptBeta =
false;
108 fH2[slot].at(
"griffinZdsTS")->Fill(grif1->GetTimeStampNs() - zds1->GetTimeStampNs(), grif1->GetArrayNumber());
109 fH2[slot].at(
"griffinZdsTime")->Fill(grif1->GetTime() - zds1->GetTime(), grif1->GetArrayNumber());
113 fH1[slot].at(
"griffinESuppAddbackBeta")->Fill(grif1->GetEnergy());
115 fH2[slot].at(
"griffinCycle")->Fill(std::fmod(grif1->GetTime(),
fCycleLength), grif1->GetEnergy());
119 fH2[slot].at(
"griffinGriffinTS")->Fill(grif1->GetTimeStampNs() - grif2->GetTimeStampNs(), grif1->GetArrayNumber());
120 fH2[slot].at(
"griffinGriffinTime")->Fill(grif1->GetTime() - grif2->GetTime(), grif1->GetArrayNumber());
123 fH2[slot].at(
"griffinESuppAddbackMatrixBeta")->Fill(grif1->GetEnergy(), grif2->GetEnergy());
124 fH2[slot].at(
"griffinESuppAddbackMatrixBeta")->Fill(grif2->GetEnergy(), grif1->GetEnergy());
127 fH2[slot].at(
"griffinESuppAddbackMatrixBetaBg")->Fill(grif1->GetEnergy(), grif2->GetEnergy());
128 fH2[slot].at(
"griffinESuppAddbackMatrixBetaBg")->Fill(grif2->GetEnergy(), grif1->GetEnergy());
136 fH1[slot].at(
"zdsCycle")->Fill(std::fmod(zds1->GetTime(),
fCycleLength));