3 #include <TGraphAsymmErrors.h>
4 #include <TGraphErrors.h>
14 #include "SaveCanvas.C"
15 #include "sPhenixStyle.C"
24 const TString
infile =
"/phenix/u/jinhuang/links/sPHENIX_work/Fluence/AuAu200_25k_Iter4_FTFP/AuAu200_25k_Iter4_FTFP_SUM.xml_g4score.root",
25 const TString
config =
"FTFP_BERT_HP",
26 const TString disc =
"Au+Au #sqrt{s_{NN}}=200 GeV, sHIJING 0-20fm" ,
27 const double nTarget = 1.5e12 ,
28 const TString projection_desc =
"5-year run plan (1.5 Trillion Collisions)"
49 gStyle->SetOptStat(0);
50 gStyle->SetOptFit(1111);
51 TVirtualFitter::SetDefaultFitter(
"Minuit2");
64 const double normalization = nTarget / nEvent;
68 FullCyl(normalization, projection_desc);
82 void VertexCyl(
const double normalization,
const TString projection_desc)
86 TCanvas *c1 =
new TCanvas(
"VertexCyl",
"VertexCyl", 1900, 960);
91 p = (TPad *) c1->cd(idx++);
95 p->SetRightMargin(.15);
100 TH2 *hScore_VertexCylinder_edep_zy = hScore_VertexCylinder_edep->Project3D(
"zy")->DrawClone(
"colz");
101 hScore_VertexCylinder_edep_zy->Scale(normalization);
102 hScore_VertexCylinder_edep_zy->GetZaxis()->SetRangeUser(1e4, 1e12);
104 TLegend *
leg =
new TLegend(-.1, .85, .9, .99);
106 leg->AddEntry(
"",
"Total energy deposition [MeV] for " + projection_desc,
"");
109 p = (TPad *) c1->cd(idx++);
112 p->SetRightMargin(.15);
113 p->SetTopMargin(.15);
115 TH2 *hScore_VertexCylinder_dose_zy = hScore_VertexCylinder_dose->Project3D(
"zy")->DrawClone(
"colz");
116 hScore_VertexCylinder_dose_zy->Scale(normalization / hScore_VertexCylinder_dose->GetNbinsX() * 100.);
117 hScore_VertexCylinder_dose_zy->GetZaxis()->SetRangeUser(1
e-2, 1e5);
118 hScore_VertexCylinder_dose_zy->GetYaxis()->SetRangeUser(20, 200);
120 TLegend *leg =
new TLegend(-.1, .85, .9, .99);
122 leg->AddEntry(
"",
"Radiation dose [rad] for " + projection_desc,
"");
125 p = (TPad *) c1->cd(idx++);
129 p->DrawFrame(25, 5e2, 200, 1e6,
";R index;Radiation dose [rad]");
131 TH1 *hScore_VertexCylinder_dose_z =
132 hScore_VertexCylinder_dose_zy->ProjectionY()->DrawClone(
"same");
133 const int n_rebin_hScore_VertexCylinder_dose_z = 5;
134 hScore_VertexCylinder_dose_z->Rebin(n_rebin_hScore_VertexCylinder_dose_z);
135 hScore_VertexCylinder_dose_z->Scale(1. / hScore_VertexCylinder_dose_zy->GetNbinsX() / n_rebin_hScore_VertexCylinder_dose_z);
137 TLegend *leg =
new TLegend(.2, .6, .9, .9);
138 leg->AddEntry(
"",
"#it{#bf{sPHENIX}} Simulation, "+
configuration+
"",
"");
140 leg->AddEntry(
"", projection_desc,
"");
141 leg->AddEntry(hScore_VertexCylinder_dose_z,
"Radiation dose",
"l");
144 p = (TPad *) c1->cd(idx++);
147 p->SetRightMargin(.15);
148 p->SetTopMargin(.15);
150 TH2 *hScore_VertexCylinder_flux_charged_zy = hScore_VertexCylinder_flux_charged->Project3D(
"zy");
151 hScore_VertexCylinder_flux_charged_zy->Scale(normalization / hScore_VertexCylinder_flux_charged->GetNbinsX());
153 TH2 *hScore_VertexCylinder_flux_charged_EkMin1MeV_zy = hScore_VertexCylinder_flux_charged_EkMin1MeV->Project3D(
"zy")->DrawClone(
"colz");
154 hScore_VertexCylinder_flux_charged_EkMin1MeV_zy->Scale(normalization / hScore_VertexCylinder_flux_charged_EkMin1MeV->GetNbinsX());
155 hScore_VertexCylinder_flux_charged_EkMin1MeV_zy->GetZaxis()->SetRangeUser(1e5, 1e12);
156 hScore_VertexCylinder_flux_charged_EkMin1MeV_zy->GetYaxis()->SetRangeUser(20, 200);
158 TLegend *leg =
new TLegend(-.1, .85, .9, .99);
160 leg->AddEntry(
"",
"Min-1-MeV Charged particle fluence [N_{ch}/cm^{2}] for " + projection_desc,
"");
179 p = (TPad *) c1->cd(idx++);
182 p->SetRightMargin(.15);
183 p->SetTopMargin(.15);
185 TH2 *hScore_VertexCylinder_flux_neutron_EkMin100keV_zy = hScore_VertexCylinder_flux_neutron_EkMin100keV->Project3D(
"zy")->DrawClone(
"colz");
186 hScore_VertexCylinder_flux_neutron_EkMin100keV_zy->Scale(normalization / hScore_VertexCylinder_flux_neutron_EkMin100keV->GetNbinsX());
187 hScore_VertexCylinder_flux_neutron_EkMin100keV_zy->GetZaxis()->SetRangeUser(1e5, 1e12);
188 hScore_VertexCylinder_flux_neutron_EkMin100keV_zy->GetYaxis()->SetRangeUser(20, 200);
190 TH2 *hScore_VertexCylinder_flux_neutron_zy = hScore_VertexCylinder_flux_neutron->Project3D(
"zy");
191 hScore_VertexCylinder_flux_neutron_zy->Scale(normalization / hScore_VertexCylinder_flux_neutron->GetNbinsX());
193 TLegend *leg =
new TLegend(-.1, .85, .9, .99);
195 leg->AddEntry(
"",
"Min-100-keV Neutron fluence [n/cm^{2}] for " + projection_desc,
"");
198 p = (TPad *) c1->cd(idx++);
202 p->DrawFrame(20, 1e9, 200, 1e14,
";R index;Fluence [N/cm^{2}]");
204 TH1 *hScore_VertexCylinder_flux_neutron_EkMin100keV_z =
205 hScore_VertexCylinder_flux_neutron_EkMin100keV_zy->ProjectionY()->DrawClone(
"same");
206 hScore_VertexCylinder_flux_neutron_EkMin100keV_z->Scale(1. / hScore_VertexCylinder_flux_neutron_EkMin100keV_zy->GetNbinsX());
208 TH1 *hScore_VertexCylinder_flux_neutron_z =
209 hScore_VertexCylinder_flux_neutron_zy->ProjectionY()->DrawClone(
"same");
210 hScore_VertexCylinder_flux_neutron_z->Scale(1. / hScore_VertexCylinder_flux_neutron_zy->GetNbinsX());
212 TH1 *hScore_VertexCylinder_flux_charged_EkMin1MeV_z =
213 hScore_VertexCylinder_flux_charged_EkMin1MeV_zy->ProjectionY()->DrawClone(
"same");
214 hScore_VertexCylinder_flux_charged_EkMin1MeV_z->Scale(1. / hScore_VertexCylinder_flux_charged_EkMin1MeV_zy->GetNbinsX());
216 TH1 *hScore_VertexCylinder_flux_charged_z =
217 hScore_VertexCylinder_flux_charged_zy->ProjectionY()->DrawClone(
"same");
218 hScore_VertexCylinder_flux_charged_z->Scale(1. / hScore_VertexCylinder_flux_charged_zy->GetNbinsX());
220 hScore_VertexCylinder_flux_neutron_EkMin100keV_z->SetLineColor(kRed + 2);
221 hScore_VertexCylinder_flux_neutron_z->SetLineColor(kPink - 2);
222 hScore_VertexCylinder_flux_charged_EkMin1MeV_z->SetLineColor(kBlue + 2);
223 hScore_VertexCylinder_flux_charged_z->SetLineColor(kCyan - 2);
225 TLegend *leg =
new TLegend(.3, .6, .9, .9);
226 leg->AddEntry(
"",
"#it{#bf{sPHENIX}} Simulation, "+
configuration+
"",
"");
228 leg->AddEntry(
"", projection_desc,
"");
229 leg->AddEntry(hScore_VertexCylinder_flux_neutron_EkMin100keV_z,
"Min-100-keV Neutron",
"l");
230 leg->AddEntry(hScore_VertexCylinder_flux_neutron_z,
"All neutron",
"l");
231 leg->AddEntry(hScore_VertexCylinder_flux_charged_EkMin1MeV_z,
"Min-1-MeV Charged particle",
"l");
232 leg->AddEntry(hScore_VertexCylinder_flux_charged_z,
"All charged particle",
"l");
238 void FullCyl(
const double normalization,
const TString projection_desc)
242 TCanvas *c1 =
new TCanvas(
"FullCyl",
"FullCyl", 1900, 960);
247 p = (TPad *) c1->cd(idx++);
250 p->SetRightMargin(.15);
251 p->SetTopMargin(.15);
253 TH2 *hScore_FullCylinder_edep_zx = hScore_FullCylinder_edep->Project3D(
"zx")->DrawClone(
"colz");
254 hScore_FullCylinder_edep_zx->Scale(normalization);
255 hScore_FullCylinder_edep_zx->GetZaxis()->SetRangeUser(1e8, 1e14);
256 hScore_FullCylinder_edep_zx->GetXaxis()->SetRangeUser(-380, 380);
258 TLegend *
leg =
new TLegend(-.1, .85, .9, .99);
260 leg->AddEntry(
"",
"Total energy deposition [MeV] for " + projection_desc,
"");
263 p = (TPad *) c1->cd(idx++);
266 p->SetRightMargin(.15);
267 p->SetTopMargin(.15);
269 TH2 *hScore_FullCylinder_flux_charged_EkMin1MeV_zx = hScore_FullCylinder_flux_charged_EkMin1MeV->Project3D(
"zx")->DrawClone(
"colz");
270 hScore_FullCylinder_flux_charged_EkMin1MeV_zx->Scale(normalization / hScore_FullCylinder_flux_charged_EkMin1MeV->GetNbinsY());
271 hScore_FullCylinder_flux_charged_EkMin1MeV_zx->GetZaxis()->SetRangeUser(1e5, 1e12);
272 hScore_FullCylinder_flux_charged_EkMin1MeV_zx->GetYaxis()->SetRangeUser(2, 300);
273 hScore_FullCylinder_flux_charged_EkMin1MeV_zx->GetXaxis()->SetRangeUser(-380, 380);
275 TLegend *leg =
new TLegend(-.1, .85, .9, .99);
277 leg->AddEntry(
"",
"Min-1-MeV Charged particle fluence [N_{ch}/cm^{2}] for " + projection_desc,
"");
280 p = (TPad *) c1->cd(idx++);
283 p->SetRightMargin(.15);
284 p->SetTopMargin(.15);
286 TH2 *hScore_FullCylinder_dose_zx = hScore_FullCylinder_dose->Project3D(
"zx")->DrawClone(
"colz");
287 hScore_FullCylinder_dose_zx->Scale(normalization / hScore_FullCylinder_dose->GetNbinsY() * 100.);
288 hScore_FullCylinder_dose_zx->GetZaxis()->SetRangeUser(.1, 1e5);
289 hScore_FullCylinder_dose_zx->GetYaxis()->SetRangeUser(2, 300);
290 hScore_FullCylinder_dose_zx->GetXaxis()->SetRangeUser(-380, 380);
292 TLegend *leg =
new TLegend(-.1, .85, .9, .99);
294 leg->AddEntry(
"",
"Radiation dose [rad] for " + projection_desc,
"");
313 p = (TPad *) c1->cd(idx++);
316 p->SetRightMargin(.15);
317 p->SetTopMargin(.15);
319 TH2 *hScore_FullCylinder_flux_neutron_EkMin100keV_zx = hScore_FullCylinder_flux_neutron_EkMin100keV->Project3D(
"zx")->DrawClone(
"colz");
320 hScore_FullCylinder_flux_neutron_EkMin100keV_zx->Scale(normalization / hScore_FullCylinder_flux_neutron_EkMin100keV->GetNbinsY());
321 hScore_FullCylinder_flux_neutron_EkMin100keV_zx->GetZaxis()->SetRangeUser(1e5, 1e12);
322 hScore_FullCylinder_flux_neutron_EkMin100keV_zx->GetYaxis()->SetRangeUser(2, 300);
323 hScore_FullCylinder_flux_neutron_EkMin100keV_zx->GetXaxis()->SetRangeUser(-380, 380);
325 TLegend *leg =
new TLegend(-.1, .85, .9, .99);
327 leg->AddEntry(
"",
"Min-100-keV Neutron fluence [n/cm^{2}] for " + projection_desc,
"");
333 void FullCylEIC(
const double normalization,
const TString projection_desc)
337 TCanvas *c1 =
new TCanvas(
"FullCylEIC",
"FullCylEIC", 1900, 860);
342 p = (TPad *) c1->cd(idx++);
345 p->SetRightMargin(.15);
346 p->SetTopMargin(.15);
348 TH2 *hScore_FullCylinder_edep_zx = hScore_FullCylinder_edep->Project3D(
"zx")->DrawClone(
"colz");
349 hScore_FullCylinder_edep_zx->Scale(normalization);
350 hScore_FullCylinder_edep_zx->GetZaxis()->SetRangeUser(1e4, 1e12);
353 TLegend *
leg =
new TLegend(-.1, .85, .9, .99);
354 leg->AddEntry(
"",
"#it{#bf{sPHENIX-EIC}} Simulation, Collision only, " +
description,
"");
355 leg->AddEntry(
"",
"Total energy deposition [MeV] for " + projection_desc,
"");
358 p = (TPad *) c1->cd(idx++);
361 p->SetRightMargin(.15);
362 p->SetTopMargin(.15);
364 TH2 *hScore_FullCylinder_flux_charged_EkMin1MeV_zx = hScore_FullCylinder_flux_charged_EkMin1MeV->Project3D(
"zx")->DrawClone(
"colz");
365 hScore_FullCylinder_flux_charged_EkMin1MeV_zx->Scale(normalization / hScore_FullCylinder_flux_charged_EkMin1MeV->GetNbinsY());
366 hScore_FullCylinder_flux_charged_EkMin1MeV_zx->GetZaxis()->SetRangeUser(1, 1e11);
367 hScore_FullCylinder_flux_charged_EkMin1MeV_zx->GetYaxis()->SetRangeUser(2, 300);
370 TLegend *leg =
new TLegend(-.1, .85, .9, .99);
371 leg->AddEntry(
"",
"#it{#bf{sPHENIX-EIC}} Simulation, Collision only, " +
description,
"");
372 leg->AddEntry(
"",
"Min-1-MeV Charged particle fluence [N_{ch}/cm^{2}] for " + projection_desc,
"");
375 p = (TPad *) c1->cd(idx++);
378 p->SetRightMargin(.15);
379 p->SetTopMargin(.15);
381 TH2 *hScore_FullCylinder_dose_zx = hScore_FullCylinder_dose->Project3D(
"zx")->DrawClone(
"colz");
382 hScore_FullCylinder_dose_zx->Scale(normalization / hScore_FullCylinder_dose->GetNbinsY() * 100.);
383 hScore_FullCylinder_dose_zx->GetZaxis()->SetRangeUser(1
e-6, 1e5);
384 hScore_FullCylinder_dose_zx->GetYaxis()->SetRangeUser(2, 300);
387 TLegend *leg =
new TLegend(-.1, .85, .9, .99);
388 leg->AddEntry(
"",
"#it{#bf{sPHENIX-EIC}} Simulation, Collision only, " +
description,
"");
389 leg->AddEntry(
"",
"Radiation dose [rad] for " + projection_desc,
"");
408 p = (TPad *) c1->cd(idx++);
411 p->SetRightMargin(.15);
412 p->SetTopMargin(.15);
414 TH2 *hScore_FullCylinder_flux_neutron_EkMin100keV_zx = hScore_FullCylinder_flux_neutron_EkMin100keV->Project3D(
"zx")->DrawClone(
"colz");
415 hScore_FullCylinder_flux_neutron_EkMin100keV_zx->Scale(normalization / hScore_FullCylinder_flux_neutron_EkMin100keV->GetNbinsY());
416 hScore_FullCylinder_flux_neutron_EkMin100keV_zx->GetZaxis()->SetRangeUser(1, 1e11);
417 hScore_FullCylinder_flux_neutron_EkMin100keV_zx->GetYaxis()->SetRangeUser(2, 300);
420 TLegend *leg =
new TLegend(-.1, .85, .9, .99);
421 leg->AddEntry(
"",
"#it{#bf{sPHENIX-EIC}} Simulation, Collision only, " +
description,
"");
422 leg->AddEntry(
"",
"Min-100-keV Neutron fluence [n/cm^{2}] for " + projection_desc,
"");
428 void FullCylRProj(
const double normalization,
const TString projection_desc,
const double z_range = 100)
433 const double vertical_scale = isEIC ? 1
e-3 : 1;
436 cout <<
"FullCylRProj - use vertical scale for EIC = " << vertical_scale << endl;
438 TString CanvasName = Form(
"FullCylRProj_%d", (
int) (z_range));
440 TCanvas *c1 =
new TCanvas(CanvasName, CanvasName, 1900, 960);
445 p = (TPad *) c1->cd(idx++);
449 p->DrawFrame(0, 1
e-3 * vertical_scale, 280, 1e6 * vertical_scale,
";R [cm];Radiation dose [rad]");
451 TH1 *hScore_FullCylinder_dose_z =
GetZProjection(hScore_FullCylinder_dose, -z_range, z_range, normalization * 100 );
453 hScore_FullCylinder_dose_z->SetBinContent(2, 0);
454 hScore_FullCylinder_dose_z->Draw(
"same");
456 TLegend *
leg =
new TLegend(.2, .7, .9, .9);
457 leg->AddEntry(
"", isEIC ?
"#it{#bf{sPHENIX-EIC}} Simulation, Collision only" :
"#it{#bf{sPHENIX}} Simulation, "+
configuration+
"",
"");
459 leg->AddEntry(
"", projection_desc,
"");
460 leg->AddEntry(
"", Form(
"Averaged over |z|<%.0f cm, R>4 cm", z_range),
"");
461 leg->AddEntry(hScore_FullCylinder_dose_z,
"Radiation dose",
"l");
464 p = (TPad *) c1->cd(idx++);
468 p->DrawFrame(0, 1e6 * vertical_scale, 280, 1e17 * vertical_scale,
";R [cm];Fluence [N/cm^{2}]");
470 TH1 *hScore_FullCylinder_flux_neutron_EkMin100keV_z =
GetZProjection(hScore_FullCylinder_flux_neutron_EkMin100keV, -z_range, z_range, normalization);
471 TH1 *hScore_FullCylinder_flux_neutron_EkMin1MeV_z =
GetZProjection(hScore_FullCylinder_flux_neutron_EkMin1MeV, -z_range, z_range, normalization);
472 TH1 *hScore_FullCylinder_flux_neutron_z =
GetZProjection(hScore_FullCylinder_flux_neutron, -z_range, z_range, normalization);
474 TH1 *hScore_FullCylinder_flux_charged_EkMin20MeV_z =
GetZProjection(hScore_FullCylinder_flux_charged_EkMin20MeV, -z_range, z_range, normalization);
475 TH1 *hScore_FullCylinder_flux_charged_EkMin1MeV_z =
GetZProjection(hScore_FullCylinder_flux_charged_EkMin1MeV, -z_range, z_range, normalization);
476 TH1 *hScore_FullCylinder_flux_charged_z =
GetZProjection(hScore_FullCylinder_flux_charged, -z_range, z_range, normalization);
478 hScore_FullCylinder_flux_neutron_EkMin1MeV_z->SetLineColor(kOrange - 3);
479 hScore_FullCylinder_flux_neutron_EkMin1MeV_z->SetLineStyle(kDashed);
480 hScore_FullCylinder_flux_neutron_EkMin100keV_z->SetLineColor(kRed + 2);
481 hScore_FullCylinder_flux_neutron_EkMin100keV_z->SetLineStyle(kDotted);
482 hScore_FullCylinder_flux_neutron_z->SetLineColor(kPink + 8);
484 hScore_FullCylinder_flux_charged_EkMin20MeV_z->SetLineColor(kBlue + 2);
485 hScore_FullCylinder_flux_charged_EkMin20MeV_z->SetLineStyle(kDashed);
486 hScore_FullCylinder_flux_charged_EkMin1MeV_z->SetLineColor(kAzure);
487 hScore_FullCylinder_flux_charged_EkMin1MeV_z->SetLineStyle(kDotted);
488 hScore_FullCylinder_flux_charged_z->SetLineColor(kCyan - 2);
490 hScore_FullCylinder_flux_neutron_EkMin1MeV_z->Draw(
"same");
491 hScore_FullCylinder_flux_neutron_EkMin100keV_z->Draw(
"same");
492 hScore_FullCylinder_flux_neutron_z->Draw(
"same");
494 hScore_FullCylinder_flux_charged_EkMin20MeV_z->Draw(
"same");
495 hScore_FullCylinder_flux_charged_EkMin1MeV_z->Draw(
"same");
496 hScore_FullCylinder_flux_charged_z->Draw(
"same");
498 TLegend *leg =
new TLegend(.3, .55, .9, .9);
499 leg->AddEntry(
"", isEIC ?
"#it{#bf{sPHENIX-EIC}} Simulation, Collision only" :
"#it{#bf{sPHENIX}} Simulation, "+
configuration+
"",
"");
501 leg->AddEntry(
"", projection_desc,
"");
502 leg->AddEntry(
"", Form(
"Averaged over |z|<%.0f cm, R>2 cm", z_range),
"");
504 leg->AddEntry(hScore_FullCylinder_flux_charged_z,
"All charged particle",
"l");
505 leg->AddEntry(hScore_FullCylinder_flux_charged_EkMin1MeV_z,
"Min-1-MeV Charged particle",
"l");
506 leg->AddEntry(hScore_FullCylinder_flux_charged_EkMin20MeV_z,
"Min-20-MeV Charged particle",
"l");
508 leg->AddEntry(hScore_FullCylinder_flux_neutron_z,
"All neutron",
"l");
509 leg->AddEntry(hScore_FullCylinder_flux_neutron_EkMin100keV_z,
"Min-100-keV Neutron",
"l");
510 leg->AddEntry(hScore_FullCylinder_flux_neutron_EkMin1MeV_z,
"Min-1-MeV Neutron",
"l");
521 const double z_range = 39;
526 const double vertical_scale = isEIC ? 1
e-3 : 1;
528 TString CanvasName = Form(
"FullCylRProjPHENIXComparison_z%dcm",
int(z_range));
530 TCanvas *c1 =
new TCanvas(CanvasName, CanvasName, 1900, 960);
535 p = (TPad *) c1->cd(idx++);
539 p->DrawFrame(0, 200 * vertical_scale, 28, 1e6 * vertical_scale,
";R [cm];Radiation dose [rad]");
541 TH1 *hScore_FullCylinder_dose_z =
GetZProjection(hScore_FullCylinder_dose, z_range, z_range, normalization * 100 );
543 hScore_FullCylinder_dose_z->SetBinContent(2, 0);
544 hScore_FullCylinder_dose_z->Draw(
"same");
547 gPHENIXDose->SetMarkerStyle(kFullCross);
548 gPHENIXDose->SetMarkerSize(4);
549 gPHENIXDose->Draw(
"p");
551 TLegend *
leg =
new TLegend(.25, .7, .9, .9);
552 leg->AddEntry(
"", isEIC ?
"#it{#bf{sPHENIX-EIC}} Simulation, Collision only" :
"#it{#bf{sPHENIX}} Simulation, "+
configuration+
"",
"");
554 leg->AddEntry(
"", projection_desc,
"");
555 leg->AddEntry(
"", Form(
"z around %.0f cm", z_range),
"");
556 leg->AddEntry(hScore_FullCylinder_dose_z,
"Simulated radiation dose",
"l");
557 leg->AddEntry(gPHENIXDose,
"PHENIX TID data",
"p");
560 p = (TPad *) c1->cd(idx++);
564 p->DrawFrame(0, 1e9 * vertical_scale, 50, 1e17 * vertical_scale,
";R [cm];Fluence [N/cm^{2}]");
566 TH1 *hScore_FullCylinder_flux_neutron_EkMin100keV_z =
GetZProjection(hScore_FullCylinder_flux_neutron_EkMin100keV, z_range, z_range, normalization);
567 TH1 *hScore_FullCylinder_flux_neutron_EkMin1MeV_z =
GetZProjection(hScore_FullCylinder_flux_neutron_EkMin1MeV, z_range, z_range, normalization);
568 TH1 *hScore_FullCylinder_flux_neutron_z =
GetZProjection(hScore_FullCylinder_flux_neutron, z_range, z_range, normalization);
571 gPHENIXNeutron->SetMarkerStyle(kFullCross);
572 gPHENIXNeutron->SetMarkerSize(4);
573 gPHENIXNeutron->SetMarkerColor(kRed + 2);
574 gPHENIXNeutron->Draw(
"p");
580 hScore_FullCylinder_flux_neutron_EkMin1MeV_z->SetLineColor(kOrange - 3);
581 hScore_FullCylinder_flux_neutron_EkMin1MeV_z->SetLineStyle(kDashed);
582 hScore_FullCylinder_flux_neutron_EkMin100keV_z->SetLineColor(kRed + 2);
583 hScore_FullCylinder_flux_neutron_EkMin100keV_z->SetLineStyle(kDotted);
584 hScore_FullCylinder_flux_neutron_z->SetLineColor(kPink + 8);
592 hScore_FullCylinder_flux_neutron_EkMin1MeV_z->Draw(
"same");
593 hScore_FullCylinder_flux_neutron_EkMin100keV_z->Draw(
"same");
594 hScore_FullCylinder_flux_neutron_z->Draw(
"same");
600 TLegend *leg =
new TLegend(.3, .55, .9, .9);
601 leg->AddEntry(
"", isEIC ?
"#it{#bf{sPHENIX-EIC}} Simulation, Collision only" :
"#it{#bf{sPHENIX}} Simulation, "+
configuration+
"",
"");
603 leg->AddEntry(
"", projection_desc,
"");
604 leg->AddEntry(
"", Form(
"z around %.0f cm", z_range),
"");
610 leg->AddEntry(hScore_FullCylinder_flux_neutron_z,
"Simulated all neutron",
"l");
611 leg->AddEntry(hScore_FullCylinder_flux_neutron_EkMin100keV_z,
"Simulated min-100-keV Neutron",
"l");
612 leg->AddEntry(hScore_FullCylinder_flux_neutron_EkMin1MeV_z,
"Simulated min-1-MeV Neutron",
"l");
613 leg->AddEntry(gPHENIXNeutron,
"Measured TID neutron fluence",
"p");
661 const double r_cm[] = {16.2, 3.5, 8.5};
662 const double doseAuAu_rad[] =
668 TGraph *
g =
new TGraph(3, r_cm, doseAuAu_rad);
700 const double r_cm[] = {16.2, 3.5, 8.5};
701 const double fluenceAuAu_icm2[] =
704 (0.16 - 0.01) * 1e12,
705 (0.16 - 0.01) * 1e12};
707 TGraph *
g =
new TGraph(3, r_cm, fluenceAuAu_icm2);
712 void FullCylZProj(
const double normalization,
const TString projection_desc,
const int r_bin = 2)
717 const double vertical_scale = isEIC ? 1
e-3 : 1;
720 cout <<
"FullCylZProj - use vertical scale for EIC = " << vertical_scale << endl;
722 const double r_min = hScore_FullCylinder_dose->GetZaxis()->GetBinLowEdge(r_bin);
723 const double r_max = hScore_FullCylinder_dose->GetZaxis()->GetBinUpEdge(r_bin);
725 TString CanvasName = Form(
"FullCylZProj_%d", (
int) (r_bin));
727 TCanvas *c1 =
new TCanvas(CanvasName, CanvasName, 1900, 800);
732 p = (TPad *) c1->cd(idx++);
736 p->DrawFrame(-450, 1e2 * vertical_scale, 450, 1e9 * vertical_scale,
";z [cm];Radiation dose [rad]");
738 TH1 *hScore_FullCylinder_dose_z =
GetRProjection(hScore_FullCylinder_dose, r_bin, normalization * 100 );
740 hScore_FullCylinder_dose_z->SetBinContent(2, 0);
741 hScore_FullCylinder_dose_z->Draw(
"same");
743 TLegend *
leg =
new TLegend(.2, .7, .9, .9);
744 leg->AddEntry(
"", isEIC ?
"#it{#bf{sPHENIX-EIC}} Simulation, Collision only" :
"#it{#bf{sPHENIX}} Simulation, "+
configuration+
"",
"");
746 leg->AddEntry(
"", projection_desc,
"");
747 leg->AddEntry(
"", Form(
"Averaged over %.1f<R<%.1f cm", r_min, r_max),
"");
748 leg->AddEntry(hScore_FullCylinder_dose_z,
"Radiation dose",
"l");
751 p = (TPad *) c1->cd(idx++);
755 p->DrawFrame(-450, 1e8 * vertical_scale, 450, 1e18 * vertical_scale,
";z [cm];Fluence [N/cm^{2}]");
757 TH1 *hScore_FullCylinder_flux_neutron_EkMin100keV_z =
GetRProjection(hScore_FullCylinder_flux_neutron_EkMin100keV, r_bin, normalization);
758 TH1 *hScore_FullCylinder_flux_neutron_EkMin1MeV_z =
GetRProjection(hScore_FullCylinder_flux_neutron_EkMin1MeV, r_bin, normalization);
759 TH1 *hScore_FullCylinder_flux_neutron_z =
GetRProjection(hScore_FullCylinder_flux_neutron, r_bin, normalization);
761 TH1 *hScore_FullCylinder_flux_charged_EkMin20MeV_z =
GetRProjection(hScore_FullCylinder_flux_charged_EkMin20MeV, r_bin, normalization);
762 TH1 *hScore_FullCylinder_flux_charged_EkMin1MeV_z =
GetRProjection(hScore_FullCylinder_flux_charged_EkMin1MeV, r_bin, normalization);
763 TH1 *hScore_FullCylinder_flux_charged_z =
GetRProjection(hScore_FullCylinder_flux_charged, r_bin, normalization);
765 hScore_FullCylinder_flux_neutron_EkMin1MeV_z->SetLineColor(kOrange - 3);
766 hScore_FullCylinder_flux_neutron_EkMin1MeV_z->SetLineStyle(kDashed);
767 hScore_FullCylinder_flux_neutron_EkMin100keV_z->SetLineColor(kRed + 2);
768 hScore_FullCylinder_flux_neutron_EkMin100keV_z->SetLineStyle(kDotted);
769 hScore_FullCylinder_flux_neutron_z->SetLineColor(kPink + 8);
771 hScore_FullCylinder_flux_charged_EkMin20MeV_z->SetLineColor(kBlue + 2);
772 hScore_FullCylinder_flux_charged_EkMin20MeV_z->SetLineStyle(kDashed);
773 hScore_FullCylinder_flux_charged_EkMin1MeV_z->SetLineColor(kAzure);
774 hScore_FullCylinder_flux_charged_EkMin1MeV_z->SetLineStyle(kDotted);
775 hScore_FullCylinder_flux_charged_z->SetLineColor(kCyan - 2);
777 hScore_FullCylinder_flux_neutron_EkMin1MeV_z->Draw(
"same");
778 hScore_FullCylinder_flux_neutron_EkMin100keV_z->Draw(
"same");
779 hScore_FullCylinder_flux_neutron_z->Draw(
"same");
781 hScore_FullCylinder_flux_charged_EkMin20MeV_z->Draw(
"same");
782 hScore_FullCylinder_flux_charged_EkMin1MeV_z->Draw(
"same");
783 hScore_FullCylinder_flux_charged_z->Draw(
"same");
785 TLegend *leg =
new TLegend(.3, .58, .9, .93);
786 leg->AddEntry(
"", isEIC ?
"#it{#bf{sPHENIX-EIC}} Simulation, Collision only" :
"#it{#bf{sPHENIX}} Simulation, "+
configuration+
"",
"");
788 leg->AddEntry(
"", projection_desc,
"");
789 leg->AddEntry(
"", Form(
"Averaged over %.1f<R<%.1f cm", r_min, r_max),
"");
791 leg->AddEntry(hScore_FullCylinder_flux_charged_z,
"All charged particle",
"l");
792 leg->AddEntry(hScore_FullCylinder_flux_charged_EkMin1MeV_z,
"Min-1-MeV Charged particle",
"l");
793 leg->AddEntry(hScore_FullCylinder_flux_charged_EkMin20MeV_z,
"Min-20-MeV Charged particle",
"l");
795 leg->AddEntry(hScore_FullCylinder_flux_neutron_z,
"All neutron",
"l");
796 leg->AddEntry(hScore_FullCylinder_flux_neutron_EkMin100keV_z,
"Min-100-keV Neutron",
"l");
797 leg->AddEntry(hScore_FullCylinder_flux_neutron_EkMin1MeV_z,
"Min-1-MeV Neutron",
"l");
808 TCanvas *c1 =
new TCanvas(
"dNchdEta",
"dNchdEta", 1000, 960);
814 p = (TPad *) c1->cd(idx++);
818 TH1 *hNChEta = (TH1 *)
_file0->GetObjectChecked(
"hNChEta",
"TH1");
821 hNChEta = (TH1 *) (hNChEta->DrawClone());
825 hNChEta->Scale(1. / hNChEta->GetBinWidth(1) / nEvent);
826 hNChEta->GetYaxis()->SetTitle(
"dN_{Ch}/d#eta");
834 TCanvas *c1 =
new TCanvas(
"Check",
"Check", 1900, 960);
839 p = (TPad *) c1->cd(idx++);
846 double nEvent = hNormalization->GetBinContent(1);
848 hNormalization->DrawClone();
850 p = (TPad *) c1->cd(idx++);
854 TH1 *hVertexZ = (TH1 *)
_file0->GetObjectChecked(
"hVertexZ",
"TH1");
857 hVertexZ = (TH1 *) (hVertexZ->DrawClone());
864 p = (TPad *) c1->cd(idx++);
867 p->SetRightMargin(.15);
869 TH2 *hScore_FullCylinder_edep_zx = hScore_FullCylinder_edep->Project3D(
"zx")->DrawClone(
"colz");
871 p = (TPad *) c1->cd(idx++);
874 p->SetRightMargin(.15);
876 TH2 *hScore_FullCylinder_edep_zy = hScore_FullCylinder_edep->Project3D(
"zy")->DrawClone(
"colz");
882 TH1 *
GetZProjection(
const TH3 *h3,
const double z_range_min,
const double z_range_max,
const double normalization)
884 TH2 *h_Rz = h3->Project3D(
"zx");
885 h_Rz->Scale(normalization / h3->GetNbinsY());
887 const int bin1 = h_Rz->GetXaxis()->FindBin(z_range_min);
888 const int bin2 = h_Rz->GetXaxis()->FindBin(z_range_max);
889 const int nbins = bin2 - bin1 + 1;
892 cout <<
"GetZProjection - " << h3->GetName() <<
": z " << bin1 <<
", " << bin2 << endl;
895 h_Rz->ProjectionY(Form(
"%s_ProjR_z_%d_%d",
896 h3->GetName(), bin1, bin2),
898 h_R->Scale(1. / nbins);
900 h_R->SetBinContent(1, 0);
903 h_R->SetLineWidth(3);
910 TH2 *h_Rz = h3->Project3D(
"zx");
911 h_Rz->Scale(normalization / h3->GetNbinsY());
915 cout <<
"GetRProjection - " << h3->GetName() <<
": r_bin " << r_bin << endl;
918 h_Rz->ProjectionX(Form(
"%s_ProjR_r_%d",
919 h3->GetName(), r_bin),
922 h_R->SetLineWidth(3);