@@ -179,7 +179,8 @@ InitStatus R3BAlpideOnlineSpectra::Init()
179179 }
180180 mainfol->Add (calfol);
181181
182- fh1_Calmult_total = R3B ::root_owned<TH1F >(" fh1_mulcal_sensor_total" , " Cal_mult for all sensors" , 70 , 0 , 70 );
182+ fh1_Calmult_total =
183+ R3B ::root_owned<TH1F >(" fh1_mulcal_sensor_total" , " Cal_mult for all sensors" , 70 , -0.5 , 69.5 );
183184 fh1_Calmult_total->GetXaxis ()->SetTitle (" Pixel multiplicity" );
184185 fh1_Calmult_total->GetYaxis ()->SetTitle (" Counts" );
185186 fh1_Calmult_total->GetYaxis ()->SetTitleOffset (1.1 );
@@ -231,7 +232,7 @@ InitStatus R3BAlpideOnlineSpectra::Init()
231232 cHit->Divide (2 , 1 );
232233 sprintf (Name1, " fh2_pos_hit_sensor_%d" , s + 1 );
233234 sprintf (Name2, " Hit-position for sensor: %d" , s + 1 );
234- fh2_PosHit[s] = R3B ::root_owned<TH2F >(Name1, Name2, 200 , - 15. 0 , 15.0 , 100 , - 7.5 , 7.5 );
235+ fh2_PosHit[s] = R3B ::root_owned<TH2F >(Name1, Name2, 200 , 0 , 30 . , 100 , 0 , 15 . );
235236 fh2_PosHit[s]->GetXaxis ()->SetTitle (" Posl [mm]" );
236237 fh2_PosHit[s]->GetYaxis ()->SetTitle (" Post [mm]" );
237238 fh2_PosHit[s]->GetYaxis ()->SetTitleOffset (1.1 );
@@ -270,6 +271,34 @@ InitStatus R3BAlpideOnlineSpectra::Init()
270271 fh1_Clustermult[s]->Draw ();
271272 hitfol->Add (cHitm);
272273 }
274+
275+ auto cHitmTot = new TCanvas (" Cluster_multiplicity_total" , " mult hit info" , 10 , 10 , 500 , 500 );
276+ fh1_Clustermult_total =
277+ R3B ::root_owned<TH1F >(" Cluster_multiplicity_total" , " Total cluster multiplicity" , 60 , 0 , 60 );
278+ fh1_Clustermult_total->GetXaxis ()->SetTitle (" Cluster multiplicity" );
279+ fh1_Clustermult_total->GetYaxis ()->SetTitle (" Counts" );
280+ fh1_Clustermult_total->GetYaxis ()->SetTitleOffset (1.1 );
281+ fh1_Clustermult_total->GetXaxis ()->CenterTitle (true );
282+ fh1_Clustermult_total->GetYaxis ()->CenterTitle (true );
283+ fh1_Clustermult_total->SetLineColor (1 );
284+ fh1_Clustermult_total->SetFillColor (31 );
285+ cHitmTot->cd ();
286+ fh1_Clustermult_total->Draw ();
287+ hitfol->Add (cHitmTot);
288+
289+ auto cSizemTot = new TCanvas (" Size_multiplicity_total" , " size hit info" , 10 , 10 , 500 , 500 );
290+ fh1_Clustersize_total = R3B ::root_owned<TH1F >(" Size_multiplicity_total" , " Total size multiplicity" , 60 , 0 , 60 );
291+ fh1_Clustersize_total->GetXaxis ()->SetTitle (" Size multiplicity" );
292+ fh1_Clustersize_total->GetYaxis ()->SetTitle (" Counts" );
293+ fh1_Clustersize_total->GetYaxis ()->SetTitleOffset (1.1 );
294+ fh1_Clustersize_total->GetXaxis ()->CenterTitle (true );
295+ fh1_Clustersize_total->GetYaxis ()->CenterTitle (true );
296+ fh1_Clustersize_total->SetLineColor (1 );
297+ fh1_Clustersize_total->SetFillColor (31 );
298+ cSizemTot->cd ();
299+ fh1_Clustersize_total->Draw ();
300+ hitfol->Add (cSizemTot);
301+
273302 mainfol->Add (hitfol);
274303
275304 cHit_angcor = new TCanvas (" Theta_vs_Phi" , " Correlation theta vs phi" , 10 , 10 , 500 , 500 );
@@ -458,8 +487,16 @@ void R3BAlpideOnlineSpectra::Reset_Histo()
458487 {
459488 hist->Reset ();
460489 }
490+
461491 fh2_theta_phi->Reset ();
462492 fh2_max_clusters->Reset ();
493+
494+ for (auto & hist : fh2_y_x)
495+ {
496+ hist->Reset ();
497+ }
498+ fh1_Clustermult_total->Reset ();
499+ fh1_Clustersize_total->Reset ();
463500 }
464501
465502 return ;
@@ -539,6 +576,7 @@ void R3BAlpideOnlineSpectra::Exec(Option_t* /*option*/)
539576 std::vector<double > y_max (2 , NAN );
540577 std::vector<int > cls_size (2 , 0 );
541578
579+ fh1_Clustermult_total->Fill (nHits);
542580 for (size_t ihit = 0 ; ihit < nHits; ihit++)
543581 {
544582 auto hit = dynamic_cast <R3BAlpideHitData*>(fHitItems ->At (ihit));
@@ -547,6 +585,7 @@ void R3BAlpideOnlineSpectra::Exec(Option_t* /*option*/)
547585 auto senid = hit->GetSensorId () - 1 ;
548586 fh1_Clustersize[senid]->Fill (hit->GetClusterSize ());
549587 fh2_PosHit[senid]->Fill (hit->GetPosl (), hit->GetPost ());
588+ fh1_Clustersize_total->Fill (hit->GetClusterSize ());
550589 if (fMap_Par ->GetGeoVersion () == 202505 )
551590 {
552591 fh2_theta_phi->Fill (hit->GetPhi () * TMath::RadToDeg (), hit->GetTheta () * TMath::RadToDeg ());
@@ -575,6 +614,7 @@ void R3BAlpideOnlineSpectra::Exec(Option_t* /*option*/)
575614 }
576615 }
577616 }
617+
578618 mult[senid]++;
579619 }
580620 for (size_t s = 0 ; s < fNbSensors ; s++)
@@ -585,12 +625,16 @@ void R3BAlpideOnlineSpectra::Exec(Option_t* /*option*/)
585625 {
586626 if (std::isfinite (x_max[0 ]) && std::isfinite (x_max[1 ]))
587627 fh2_y_x_cor_det[0 ]->Fill (x_max[0 ], x_max[1 ]);
628+
588629 if (std::isfinite (y_max[0 ]) && std::isfinite (y_max[1 ]))
589630 fh2_y_x_cor_det[1 ]->Fill (y_max[0 ], y_max[1 ]);
631+
590632 if (std::isfinite (x_max[0 ]) && std::isfinite (y_max[1 ]))
591633 fh2_y_x_cor_det[2 ]->Fill (x_max[0 ], y_max[1 ]);
592- if (std::isfinite (x_max[2 ]) && std::isfinite (y_max[0 ]))
634+
635+ if (std::isfinite (x_max[1 ]) && std::isfinite (y_max[0 ]))
593636 fh2_y_x_cor_det[3 ]->Fill (x_max[1 ], y_max[0 ]);
637+
594638 if (cls_size[0 ] > 0 && cls_size[1 ] > 0 )
595639 fh2_max_clusters->Fill (cls_size[0 ], cls_size[1 ]);
596640 }
@@ -639,6 +683,7 @@ void R3BAlpideOnlineSpectra::FinishTask()
639683 if (fHitItems )
640684 {
641685 fh2_theta_phi->Write ();
686+
642687 fh2_max_clusters->Write ();
643688 for (const auto & hist : fh2_y_x)
644689 {
@@ -648,6 +693,9 @@ void R3BAlpideOnlineSpectra::FinishTask()
648693 {
649694 hist->Write ();
650695 }
696+
697+ fh1_Clustermult_total->Write ();
698+ fh1_Clustersize_total->Write ();
651699 }
652700}
653701ClassImp (R3BAlpideOnlineSpectra)
0 commit comments