Skip to content

Commit e1e0d6d

Browse files
authored
Merge pull request cms-sw#42517 from fabiocos/fc-etlmatbdg
MTD Validation: add histograms for detailed material budget vs eta study
2 parents 197396b + 2782c36 commit e1e0d6d

File tree

2 files changed

+42
-20
lines changed

2 files changed

+42
-20
lines changed

Validation/Geometry/src/MaterialBudgetMtdHistos.cc

Lines changed: 37 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,18 @@ void MaterialBudgetMtdHistos::book() {
2020
static constexpr double maxPhi = 3.1416;
2121
static constexpr int nbinEta = 250;
2222
static constexpr int nbinPhi = 180;
23-
#ifdef MTD_DETAIL
24-
static constexpr double minEtaZoom = 0.;
25-
static constexpr double maxEtaZoom = 0.087;
26-
static constexpr double minPhiZoom = 0.;
27-
static constexpr double maxPhiZoom = 0.35;
28-
static constexpr int nbinEtaZoom = 64;
29-
static constexpr int nbinPhiZoom = 20;
30-
#endif
23+
24+
static constexpr double minEtaBTLZoom = 0.;
25+
static constexpr double maxEtaBTLZoom = 0.087;
26+
static constexpr double minPhiBTLZoom = 0.;
27+
static constexpr double maxPhiBTLZoom = 0.35;
28+
static constexpr int nbinEtaBTLZoom = 64;
29+
static constexpr int nbinPhiBTLZoom = 20;
30+
31+
static constexpr double minMB = 0.;
32+
static constexpr double maxMBetl = 0.025;
33+
static constexpr double maxMBbtl = 0.5;
34+
static constexpr int nbinMB = 25;
3135

3236
// Material budget: radiation length
3337
// total X0
@@ -55,16 +59,22 @@ void MaterialBudgetMtdHistos::book() {
5559
hmgr->addHisto1(new TH1F("221", "Phi [Sensitive]", nbinPhi, minPhi, maxPhi));
5660
hmgr->addHistoProf2(new TProfile2D(
5761
"230", "MB prof Eta Phi [Sensitive];#eta;#varphi;x/X_{0}", nbinEta, minEta, maxEta, nbinPhi, minPhi, maxPhi));
58-
#ifdef MTD_DETAIL
62+
5963
hmgr->addHistoProf2(new TProfile2D("10230",
6064
"MB prof Eta Phi [Sensitive];#eta;#varphi;x/X_{0}",
61-
nbinEtaZoom,
62-
minEtaZoom,
63-
maxEtaZoom,
64-
nbinPhiZoom,
65-
minPhiZoom,
66-
maxPhiZoom));
67-
#endif
65+
nbinEtaBTLZoom,
66+
minEtaBTLZoom,
67+
maxEtaBTLZoom,
68+
nbinPhiBTLZoom,
69+
minPhiBTLZoom,
70+
maxPhiBTLZoom));
71+
hmgr->addHisto2(
72+
new TH2F("10234", "MB vs Eta [Sensitive];#eta;x/X_{0}", nbinEta, minEta, maxEta, nbinMB, minMB, maxMBetl));
73+
hmgr->addHisto2(new TH2F(
74+
"20234", "MB along z vs Eta [Sensitive];#eta;x/X_{0}", nbinEta, minEta, maxEta, nbinMB, minMB, maxMBetl));
75+
hmgr->addHisto2(
76+
new TH2F("10235", "MB vs Eta [Sensitive];#eta;x/X_{0}", nbinEta, minEta, maxEta, nbinMB, minMB, maxMBbtl));
77+
6878
hmgr->addHisto2(new TH2F("231", "Eta vs Phi [Sensitive]", nbinEta, minEta, maxEta, nbinPhi, minPhi, maxPhi));
6979

7080
// Cables
@@ -252,9 +262,17 @@ void MaterialBudgetMtdHistos::fillEndTrack() {
252262
hmgr->getHistoProf1(210)->Fill(theData->getEta(), theData->getSensitiveMB());
253263
hmgr->getHistoProf1(220)->Fill(theData->getPhi(), theData->getSensitiveMB());
254264
hmgr->getHistoProf2(230)->Fill(theData->getEta(), theData->getPhi(), theData->getSensitiveMB());
255-
#ifdef MTD_DETAIL
256-
hmgr->getHistoProf2(10230)->Fill(theData->getEta(), theData->getPhi(), theData->getSensitiveMB());
257-
#endif
265+
266+
static constexpr double bfTransitionEta = 1.55;
267+
268+
if (std::abs(theData->getEta()) > bfTransitionEta) {
269+
hmgr->getHisto2(10234)->Fill(theData->getEta(), theData->getSensitiveMB());
270+
double norma = std::tanh(std::abs(theData->getEta()));
271+
hmgr->getHisto2(20234)->Fill(theData->getEta(), theData->getSensitiveMB() * norma);
272+
} else {
273+
hmgr->getHistoProf2(10230)->Fill(theData->getEta(), theData->getPhi(), theData->getSensitiveMB());
274+
hmgr->getHisto2(10235)->Fill(theData->getEta(), theData->getSensitiveMB());
275+
}
258276

259277
// Cables
260278
hmgr->getHisto1(311)->Fill(theData->getEta());

Validation/Geometry/test/runP_Mtd_cfg.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,10 @@
3434
FwkJob = cms.untracked.PSet( ## but FwkJob category - those unlimitted
3535
limit = cms.untracked.int32(-1)
3636
),
37+
FwkReport = cms.untracked.PSet(
38+
reportEvery = cms.untracked.int32(1000),
39+
limit = cms.untracked.int32(0)
40+
),
3741
MaterialBudget = cms.untracked.PSet(
3842
limit = cms.untracked.int32(-1)
3943
),
@@ -44,7 +48,7 @@
4448
limit = cms.untracked.int32(-1)
4549
),
4650
),
47-
categories = cms.untracked.vstring('FwkJob','MaterialBudget','G4cout','G4cerr'),
51+
categories = cms.untracked.vstring('FwkJob','FwkReport','MaterialBudget','G4cout','G4cerr'),
4852
debugModules = cms.untracked.vstring('g4SimHits'),
4953
destinations = cms.untracked.vstring('cout')
5054
)

0 commit comments

Comments
 (0)