|
|
Go to the documentation of this file.
24 #include "G4VProcess.hh"
26 #include "G4SystemOfUnits.hh"
39 :
CaloSD(
name, clg,
p, manager), hcalTB02Parameters_(es) {
49 if (
name ==
"EcalHitsEB") {
52 }
else if (
name ==
"HcalHits") {
62 edm::LogVerbatim(
"HcalTBSim") <<
"***************************************************\n"
64 <<
"* Constructing a HcalTB02SD with name " << GetName() <<
"\n"
66 <<
"***************************************************";
68 <<
" with three constants kB = " <<
birk1_ <<
", C1 = " <<
birk2_
80 auto const preStepPoint = aStep->GetPreStepPoint();
81 std::string nameVolume = static_cast<std::string>(preStepPoint->GetPhysicalVolume()->GetName());
89 double edep = aStep->GetTotalEnergyDeposit() *
weight;
91 edm::LogVerbatim(
"HcalTBSim") <<
"HcalTB02SD:: " << nameVolume <<
" Light Collection Efficiency " <<
weight
92 <<
" Weighted Energy Deposit " << edep /
CLHEP::MeV <<
" MeV";
103 edm::LogVerbatim(
"HcalTBSim") <<
"HcalTB02SD: updates numbering scheme for " << GetName();
110 G4ThreeVector localPoint =
setToLocal(stepPoint->GetPosition(), stepPoint->GetTouchable());
112 double dapd = 0.5 * crlength - localPoint.z();
113 if (dapd >= -0.1 || dapd <= crlength + 0.1) {
115 weight = 1.05 - dapd * 0.0005;
117 edm::LogWarning(
"HcalTBSim") <<
"HcalTB02SD: light coll curve : wrong "
118 <<
"distance to APD " << dapd <<
" crlength = " << crlength
119 <<
" crystal name = " << nameVolume <<
" z of localPoint = " << localPoint.z()
120 <<
" take weight = " <<
weight;
123 edm::LogVerbatim(
"HcalTBSim") <<
"HcalTB02SD, light coll curve : " << dapd <<
" crlength = " << crlength
124 <<
" crystal name = " << nameVolume <<
" z of localPoint = " << localPoint.z()
125 <<
" take weight = " <<
weight;
131 double length = 230.;
std::unique_ptr< HcalTB02NumberingScheme > numberingScheme_
double getAttenuation(const G4Step *aStep, double birk1, double birk2, double birk3) const
T getUntrackedParameter(std::string const &, T const &) const
Log< level::Warning, false > LogWarning
void setNumberingScheme(HcalTB02NumberingScheme *scheme)
G4ThreeVector setToLocal(const G4ThreeVector &, const G4VTouchable *) const
const HcalTB02Parameters * hcalTB02Parameters_
double getEnergyDeposit(const G4Step *) override
std::map< std::string, double > lengthMap_
uint32_t setDetUnitId(const G4Step *step) override
double curve_LY(const std::string &, const G4StepPoint *)
Log< level::Info, true > LogVerbatim
HcalTB02SD(const std::string &, const HcalTB02Parameters *, const SensitiveDetectorCatalog &, edm::ParameterSet const &, const SimTrackManager *)
double crystalLength(const std::string &)
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e g