20 #include "G4LogicalVolumeStore.hh"
21 #include "G4LogicalVolume.hh"
24 #include "G4ParticleTable.hh"
35 CaloSD(name, cpv, clg, p, manager,
36 p.getParameter<edm::
ParameterSet>(
"HCalSD").getParameter<int>(
"TimeSliceUnit"),
37 p.getParameter<edm::
ParameterSet>(
"HCalSD").getParameter<bool>(
"IgnoreTrackID")),
39 showerParam(0), showerPMT(0), showerBundle(0){
55 bool testNumber = m_HC.
getParameter<
bool>(
"TestNumberingScheme");
69 LogDebug(
"HcalSim") <<
"***************************************************"
73 <<
"* Constructing a HCalSD with name " << name <<
"\n"
76 <<
"***************************************************";
78 edm::LogInfo(
"HcalSim") <<
"HCalSD:: Use of HF code is set to " << useHF
79 <<
"\nUse of shower parametrization set to "
80 << useParam <<
"\nUse of shower library is set to "
81 << useShowerLibrary <<
"\nUse PMT Hit is set to "
82 << usePMTHit <<
" with beta Threshold "<< betaThr
83 <<
"\nUSe of FibreBundle Hit set to "<<useFibreBundle
84 <<
"\n Use of Birks law is set to "
85 << useBirk <<
" with three constants kB = "
86 << birk1 <<
", C1 = " << birk2 <<
", C2 = " <<
birk3;
90 <<
" ions below " <<
kmaxIon <<
" MeV\n"
91 <<
" Threshold for storing hits in HB: "
92 << eminHitHB <<
" HE: " << eminHitHE <<
" HO: "
97 if (testNumber || forTBH2)
103 const G4LogicalVolumeStore * lvs = G4LogicalVolumeStore::GetInstance();
104 std::vector<G4LogicalVolume *>::const_iterator lvcite;
106 std::string attribute,
value;
115 attribute =
"Volume";
118 DDValue ddv0(attribute,value,0);
126 edm::LogInfo(
"HcalSim") <<
"HCalSD: Names to be tested for " << attribute
127 <<
" = " << value <<
" has " <<
hfNames.size()
129 for (
unsigned int i=0;
i<
hfNames.size();
i++) {
132 for (lvcite = lvs->begin(); lvcite != lvs->end(); lvcite++)
133 if ((*lvcite)->GetName() == namv) {
138 int level =
static_cast<int>(temp[
i]);
141 <<
" LV " <<
hfLV[
i] <<
" at level "
148 DDValue ddv1(attribute,value,0);
153 edm::LogInfo(
"HcalSim") <<
"HCalSD: Names to be tested for " << attribute
154 <<
" = " << value <<
":";
158 for (lvcite = lvs->begin(); lvcite != lvs->end(); lvcite++)
159 if ((*lvcite)->GetName() == namv) {
171 DDValue ddv3(attribute,value,0);
175 std::vector<G4String> pmtNames =
getNames(fv3);
176 edm::LogInfo(
"HcalSim") <<
"HCalSD: Names to be tested for " << attribute
177 <<
" = " << value <<
" have " << pmtNames.size()
179 for (
unsigned int i=0;
i<pmtNames.size();
i++) {
180 G4String namv = pmtNames[
i];
182 for (lvcite = lvs->begin(); lvcite != lvs->end(); lvcite++)
183 if ((*lvcite)->GetName() == namv) {
188 edm::LogInfo(
"HcalSim") <<
"HCalSD: (" <<
i <<
") " << pmtNames[
i]
194 value =
"HFFibreBundleStraight";
196 DDValue ddv4(attribute,value,0);
201 edm::LogInfo(
"HcalSim") <<
"HCalSD: Names to be tested for " << attribute
202 <<
" = " << value <<
" have " << fibreNames.size()
204 for (
unsigned int i=0;
i<fibreNames.size();
i++) {
205 G4String namv = fibreNames[
i];
207 for (lvcite = lvs->begin(); lvcite != lvs->end(); lvcite++)
208 if ((*lvcite)->GetName() == namv) {
213 edm::LogInfo(
"HcalSim") <<
"HCalSD: (" <<
i <<
") " << fibreNames[
i]
217 value =
"HFFibreBundleConical";
219 DDValue ddv5(attribute,value,0);
224 edm::LogInfo(
"HcalSim") <<
"HCalSD: Names to be tested for " << attribute
225 <<
" = " << value <<
" have " << fibreNames.size()
227 for (
unsigned int i=0;
i<fibreNames.size();
i++) {
228 G4String namv = fibreNames[
i];
230 for (lvcite = lvs->begin(); lvcite != lvs->end(); lvcite++)
231 if ((*lvcite)->GetName() == namv) {
236 edm::LogInfo(
"HcalSim") <<
"HCalSD: (" <<
i <<
") " << fibreNames[
i]
244 attribute =
"ReadOutName";
246 DDValue ddv2(attribute,name,0);
255 edm::LogInfo(
"HcalSim") <<
"HCalSD: " << layer0wt.size() <<
" Layer0Wt";
256 for (
unsigned int it=0; it<layer0wt.size(); it++)
257 edm::LogInfo(
"HcalSim") <<
"HCalSD: [" << it <<
"] " << layer0wt[it];
259 const G4MaterialTable * matTab = G4Material::GetMaterialTable();
260 std::vector<G4Material*>::const_iterator matite;
276 for (matite = matTab->begin(); matite != matTab->end(); matite++) {
277 if ((*matite)->GetName() == namx) {
288 edm::LogInfo(
"HcalSim") <<
"HCalSD: Material names for " << attribute
289 <<
" = " << name <<
":";
298 for (
int i=0;
i<9;
i++) {
306 static std::string
labels[9] = {
"HB",
"HE",
"HO",
"HF Absorber",
"HF PMT",
"HF Absorber Long",
"HF Absorber Short",
"HF PMT Long",
"HF PMT Short"};
307 char name[20],
title[60];
308 for (
int i=0;
i<9;
i++) {
309 sprintf (title,
"Hit energy in %s", labels[
i].c_str());
310 sprintf (name,
"HCalSDHit%d",
i);
312 sprintf (title,
"Energy (MeV)");
313 hit_[
i]->GetXaxis()->SetTitle(title);
314 hit_[
i]->GetYaxis()->SetTitle(
"Hits");
315 sprintf (title,
"Time of the hit in %s", labels[
i].c_str());
316 sprintf (name,
"HCalSDTime%d",
i);
318 sprintf (title,
"Time (ns)");
319 time_[
i]->GetXaxis()->SetTitle(title);
320 time_[
i]->GetYaxis()->SetTitle(
"Hits");
321 sprintf (title,
"Longitudinal profile in %s", labels[
i].c_str());
322 sprintf (name,
"HCalSDDist%d",
i);
324 sprintf (title,
"Distance (mm)");
325 dist_[
i]->GetXaxis()->SetTitle(title);
326 dist_[
i]->GetYaxis()->SetTitle(
"Hits");
350 G4LogicalVolume* lv =
351 aStep->GetPreStepPoint()->GetPhysicalVolume()->GetLogicalVolume();
352 G4String nameVolume = lv->GetName();
354 G4int parCode =aStep->GetTrack()->GetDefinition()->GetPDGEncoding();
357 LogDebug(
"HcalSim") <<
"HCalSD: Hit from parametrization in "
358 << nameVolume <<
" for Track "
359 << aStep->GetTrack()->GetTrackID()
360 <<
" (" << aStep->GetTrack()->GetDefinition()->GetParticleName() <<
")";
364 bool notaMuon =
true;
365 if (parCode ==
mupPDG || parCode ==
mumPDG ) notaMuon =
false;
368 LogDebug(
"HcalSim") <<
"HCalSD: Starts shower library from "
369 << nameVolume <<
" for Track "
370 << aStep->GetTrack()->GetTrackID()
371 <<
" (" << aStep->GetTrack()->GetDefinition()->GetParticleName() <<
")";
376 LogDebug(
"HcalSim") <<
"HCalSD: Hit at Fibre in " << nameVolume
378 << aStep->GetTrack()->GetTrackID()
379 <<
" (" << aStep->GetTrack()->GetDefinition()->GetParticleName() <<
")";
386 LogDebug(
"HcalSim") <<
"HCalSD: Hit from PMT parametrization from "
387 << nameVolume <<
" for Track "
388 << aStep->GetTrack()->GetTrackID() <<
" ("
389 << aStep->GetTrack()->GetDefinition()->GetParticleName() <<
")";
394 LogDebug(
"HcalSim") <<
"HCalSD: Hit from FibreBundle from "
395 << nameVolume <<
" for Track "
396 << aStep->GetTrack()->GetTrackID() <<
" ("
397 << aStep->GetTrack()->GetDefinition()->GetParticleName() <<
")";
403 LogDebug(
"HcalSim") <<
"HCalSD: Hit from standard path from "
404 << nameVolume <<
" for Track "
405 << aStep->GetTrack()->GetTrackID() <<
" ("
406 << aStep->GetTrack()->GetDefinition()->GetParticleName() <<
")";
411 plotProfile(aStep, aStep->GetPreStepPoint()->GetPosition(),
413 aStep->GetPostStepPoint()->GetGlobalTime(), 0);
425 double destep = aStep->GetTotalEnergyDeposit();
427 const G4VTouchable* touch = aStep->GetPreStepPoint()->GetTouchable();
428 int depth = (touch->GetReplicaNumber(0))%10;
429 int det = ((touch->GetReplicaNumber(1))/1000)-3;
430 if (depth==0 && (det==0 || det==1)) weight =
layer0wt[det];
432 int lay = (touch->GetReplicaNumber(0)/10)%100 + 1;
433 G4ThreeVector hitPoint = aStep->GetPreStepPoint()->GetPosition();
438 G4Track*
theTrack = aStep->GetTrack();
441 int pdg = theTrack->GetDefinition()->GetPDGEncoding();
443 double ke = theTrack->GetKineticEnergy()/MeV;
444 if (((pdg/1000000000 == 1 && ((pdg/10000)%100) > 0 &&
445 ((pdg/10)%100) > 0)) && (ke<
kmaxIon)) weight = 0;
446 if ((pdg == 2212) && (ke <
kmaxProton)) weight = 0;
447 if ((pdg == 2112) && (ke <
kmaxNeutron)) weight = 0;
451 << theTrack->GetTrackID() <<
" Type "
452 << theTrack->GetDefinition()->GetParticleName()
453 <<
" Kinetic Energy " << ke <<
" MeV";
462 G4Material* mat = aStep->GetPreStepPoint()->GetMaterial();
468 edm::LogInfo(
"HcalSim") <<
"HCalSD: Detector " << det+3 <<
" Depth " << depth
469 <<
" weight " << weight0 <<
" " << weight <<
" "
472 return weight*wt1*destep;
478 const G4VTouchable* touch = preStepPoint->GetTouchable();
479 G4ThreeVector hitPoint = preStepPoint->GetPosition();
481 int depth = (touch->GetReplicaNumber(0))%10 + 1;
482 int lay = (touch->GetReplicaNumber(0)/10)%100 + 1;
483 int det = (touch->GetReplicaNumber(1))/1000;
490 edm::LogInfo(
"HcalSim") <<
"HCalSD: updates numbering scheme for "
491 << GetName() <<
"\n";
499 G4ParticleTable * theParticleTable = G4ParticleTable::GetParticleTable();
500 G4String particleName;
501 mumPDG = theParticleTable->FindParticle(particleName=
"mu-")->GetPDGEncoding();
502 mupPDG = theParticleTable->FindParticle(particleName=
"mu+")->GetPDGEncoding();
505 <<
" for mu+ = " <<
mupPDG;
515 switch (theId.subdetId()) {
549 LogDebug(
"HcalSim") <<
"HCalSD:getDDDArray called for " << str;
556 const std::vector<double> & fvec = value.
doubles();
557 int nval = fvec.size();
559 edm::LogError(
"HcalSim") <<
"HCalSD : # of " << str <<
" bins " << nval
560 <<
" < 2 ==> illegal";
562 <<
"nval < 2 for array " << str <<
"\n";
567 edm::LogError(
"HcalSim") <<
"HCalSD : cannot get array " << str;
569 <<
"cannot get array " << str <<
"\n";
575 std::vector<G4String>
tmp;
580 for (
unsigned int i=0;
i<tmp.size();
i++) {
581 if (!strcmp(tmp[
i].c_str(),log.
name().
name().c_str())) {
586 if (ok) tmp.push_back(log.
name().
name());
594 const G4VTouchable* touch = aStep->GetPreStepPoint()->GetTouchable();
595 int levels = ((touch->GetHistoryDepth())+1);
596 for (
unsigned int it=0; it <
hfNames.size(); it++) {
598 G4LogicalVolume* lv = touch->GetVolume(levels-
hfLevels[it])->GetLogicalVolume();
599 if (lv ==
hfLV[it])
return true;
607 std::vector<G4String>::const_iterator it =
hfNames.begin();
608 for (; it !=
hfNames.end(); it++)
609 if (name == *it)
return true;
615 std::vector<G4LogicalVolume*>::const_iterator ite =
fibreLV.begin();
616 for (; ite !=
fibreLV.end(); ite++)
617 if (lv == *ite)
return true;
623 std::vector<G4String>::const_iterator it =
fibreNames.begin();
625 if (name == *it)
return true;
631 std::vector<G4LogicalVolume*>::const_iterator ite =
pmtLV.begin();
632 for (; ite !=
pmtLV.end(); ite++)
633 if (lv == *ite)
return true;
639 std::vector<G4LogicalVolume*>::const_iterator ite =
fibre1LV.begin();
640 for (; ite !=
fibre1LV.end(); ite++)
641 if (lv == *ite)
return true;
647 std::vector<G4LogicalVolume*>::const_iterator ite =
fibre2LV.begin();
648 for (; ite !=
fibre2LV.end(); ite++)
649 if (lv == *ite)
return true;
655 std::vector<G4Material*>::const_iterator ite =
materials.begin();
657 if (mat == *ite)
return true;
686 G4int particleCode =
theTrack->GetDefinition()->GetPDGEncoding();
694 edm::LogInfo(
"HcalSim") <<
"HCalSD::getFromLibrary " <<hits.size()
695 <<
" hits for " << GetName() <<
" of " << primaryID
696 <<
" with " <<
theTrack->GetDefinition()->GetParticleName()
700 for (
unsigned int i=0;
i<hits.size();
i++) {
701 G4ThreeVector hitPoint = hits[
i].position;
702 int depth = hits[
i].depth;
703 double time = hits[
i].time;
704 unsigned int unitID =
setDetUnitId(det, hitPoint, depth);
707 plotProfile(aStep, hitPoint, 1.0*GeV, time, depth);
720 theTrack->SetTrackStatus(fStopAndKill);
721 G4TrackVector tv = *(aStep->GetSecondary());
722 for (
unsigned int kk=0; kk<tv.size(); kk++) {
724 tv[kk]->SetTrackStatus(fStopAndKill);
738 G4int particleCode =
theTrack->GetDefinition()->GetPDGEncoding();
746 edm::LogInfo(
"HcalSim") <<
"HCalSD::hitForFibre " << hits.size()
747 <<
" hits for " << GetName() <<
" of " << primaryID
748 <<
" with " <<
theTrack->GetDefinition()->GetParticleName()
750 <<
" GeV in detector type " << det;
752 if (hits.size() > 0) {
757 unsigned int unitID =
setDetUnitId(det, hitPoint, depth);
759 for (
unsigned int i=0;
i<hits.size();
i++) {
760 double time = hits[
i].time;
763 plotProfile(aStep, hitPoint, 1.0*GeV, time, depth);
780 int nHit =
static_cast<int>(hits.size());
788 edm::LogInfo(
"HcalSim") <<
"HCalSD::getFromParam " << nHit <<
" hits for "
789 << GetName() <<
" of " << primaryID <<
" with "
790 << aStep->GetTrack()->GetDefinition()->GetParticleName()
792 <<
" GeV in detector type " << det;
794 for (
int i = 0;
i<nHit;
i++) {
795 G4ThreeVector hitPoint = hits[
i].position;
796 int depth = hits[
i].depth;
797 double time = hits[
i].time;
798 unsigned int unitID =
setDetUnitId(det, hitPoint, depth);
829 primaryID =
theTrack->GetParentID();
830 if (primaryID == 0) primaryID =
theTrack->GetTrackID();
839 double rr = (hitPoint.x()*hitPoint.x() + hitPoint.y()*hitPoint.y());
840 double phi = (rr == 0. ? 0. :atan2(hitPoint.y(),hitPoint.x()));
847 if (hitPoint.z() < 0) etaR =-etaR;
849 edm::LogInfo(
"HcalSim") <<
"HCalSD::Hit for Detector " << det <<
" etaR "
850 << etaR <<
" phi " << phi/deg <<
" depth " <<depth;
852 double time = (aStep->GetPostStepPoint()->GetGlobalTime());
864 plotProfile(aStep, hitPoint, edep*GeV, time, depth);
866 LogDebug(
"HcalSim") <<
"HCalSD::getHitPMT 1 hit for " << GetName()
867 <<
" of " << primaryID <<
" with "
868 <<
theTrack->GetDefinition()->GetParticleName()
870 <<
" GeV with velocity " << beta <<
" UnitID "
871 << std::hex << unitID << std::dec;
894 primaryID =
theTrack->GetParentID();
895 if (primaryID == 0) primaryID =
theTrack->GetTrackID();
904 double rr = (hitPoint.x()*hitPoint.x() + hitPoint.y()*hitPoint.y());
905 double phi = (rr == 0. ? 0. :atan2(hitPoint.y(),hitPoint.x()));
912 if (hitPoint.z() < 0) etaR =-etaR;
914 edm::LogInfo(
"HcalSim") <<
"HCalSD::Hit for Detector " << det <<
" etaR "
915 << etaR <<
" phi " << phi/deg <<
" depth " <<depth;
917 double time = (aStep->GetPostStepPoint()->GetGlobalTime());
930 plotProfile(aStep, hitPoint, edep*GeV, time, depth);
932 LogDebug(
"HcalSim") <<
"HCalSD::getHitFibreBundle 1 hit for " << GetName()
933 <<
" of " << primaryID <<
" with "
934 <<
theTrack->GetDefinition()->GetParticleName()
936 <<
" GeV with velocity " << beta <<
" UnitID "
937 << std::hex << unitID << std::dec;
955 if (primaryID == 0) {
957 edm::LogInfo(
"HcalSim") <<
"HCalSD: Problem with primaryID **** set by "
958 <<
"force to TkID **** " <<
theTrack->GetTrackID();
975 int det, zside, etaR,
phi, lay;
977 while (infile >> det >> zside >> etaR >> phi >> lay >> wt) {
982 edm::LogInfo(
"HcalSim") <<
"HCalSD::readWeightFromFile:Entry " << entry
983 <<
" ID " << std::hex <<
id << std::dec <<
" ("
984 << det <<
"/" << zside <<
"/1/" << etaR <<
"/"
985 << phi <<
"/" << lay <<
") Weight " << wt;
990 edm::LogInfo(
"HcalSim") <<
"HCalSD::readWeightFromFile: reads " << entry
991 <<
" weights from " << fName;
1005 std::map<uint32_t,double>::const_iterator ite =
layerWeights.find(
id);
1008 edm::LogInfo(
"HcalSim") <<
"HCalSD::layerWeight: ID " << std::hex <<
id
1009 << std::dec <<
" (" << tmp.
subdet <<
"/"
1010 << tmp.
zside <<
"/1/" << tmp.
etaR <<
"/"
1011 << tmp.
phis <<
"/" << tmp.
lay <<
") Weight " <<wt;
1018 double time,
int id) {
1020 const G4VTouchable* touch = aStep->GetPreStepPoint()->GetTouchable();
1021 static G4String modName[8] = {
"HEModule",
"HVQF",
"HBModule",
"MBAT",
"MBBT",
"MBBTC",
"MBBT_R1P",
"MBBT_R1M"};
1022 G4ThreeVector local;
1026 for (
int n=0;
n<touch->GetHistoryDepth();
n++) {
1027 G4String
name = touch->GetVolume(
n)->GetName();
1029 LogDebug(
"HcalSim") <<
"plotProfile Depth " <<
n <<
" Name " <<
name;
1031 for (
unsigned int ii=0; ii<8; ii++) {
1032 if (name == modName[ii]) {
1034 int dn = touch->GetHistoryDepth() -
n;
1035 local = touch->GetHistory()->GetTransform(dn).TransformPoint(global);
1036 if (ii == 0) {depth = local.z() - 4006.5; idx = 1;}
1037 else if (ii == 1) {depth = local.z() + 825.0; idx = 3;}
1038 else if (ii == 2) {depth = local.x() - 1775.; idx = 0;}
1039 else {depth = local.y() + 15.; idx = 2;}
1045 if (!found) depth =
std::abs(global.z()) - 11500;
1047 LogDebug(
"HcalSim") <<
"plotProfile Found " << found <<
" Global " << global <<
" Local " << local <<
" depth " << depth <<
" ID " <<
id <<
" EDEP " << edep <<
" Time " <<
time;
1049 if (
hit_[idx] != 0)
hit_[idx]->Fill(edep);
1050 if (
time_[idx] != 0)
time_[idx]->Fill(time,edep);
1051 if (
dist_[idx] != 0)
dist_[idx]->Fill(depth,edep);
1052 int jd = 2*idx +
id - 7;
1053 if (jd >= 0 && jd < 4) {
1055 if (
hit_[jd] != 0)
hit_[jd]->Fill(edep);
1056 if (
time_[jd] != 0)
time_[jd]->Fill(time,edep);
1057 if (
dist_[jd] != 0)
dist_[jd]->Fill(depth,edep);
T getParameter(std::string const &) const
std::vector< double > layer0wt
T getUntrackedParameter(std::string const &, T const &) const
HFShowerParam * showerParam
void getFromLibrary(G4Step *step)
const DDLogicalPart & logicalPart() const
The logical-part of the current node in the filtered-view.
const std::vector< double > & doubles() const
a reference to the double-valued values stored in the given instance of DDValue
std::vector< Hit > getHits(G4Step *aStep, bool &ok, bool onlyLong=false)
virtual uint32_t getUnitID(const HcalNumberingFromDDD::HcalID id)
void addFilter(const DDFilter &, log_op op=AND)
void updateHit(CaloG4Hit *)
std::vector< Hit > getHits(G4Step *aStep)
bool isItStraightBundle(G4LogicalVolume *)
virtual bool ProcessHits(G4Step *, G4TouchableHistory *)
HFShowerFibreBundle * showerBundle
std::vector< G4LogicalVolume * > fibre1LV
std::vector< G4LogicalVolume * > fibreLV
std::vector< double > getDDDArray(const std::string &, const DDsvalues_type &)
double getHits(G4Step *aStep, bool type)
virtual uint32_t setDetUnitId(G4Step *step)
int setTrackID(G4Step *step)
void setNumberingScheme(HcalNumberingScheme *)
type of data representation of DDCompactView
bool DDfetch(const DDsvalues_type *, DDValue &)
helper for retrieving DDValues from DDsvalues_type *.
const DDMaterial & material() const
Returns a reference object of the material this LogicalPart is made of.
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
static TrackerG4SimHitNumberingScheme & numberingScheme(const DDCompactView &cpv, const GeometricDet &det)
std::vector< Hit > getHits(G4Step *aStep)
bool isItConicalBundle(G4LogicalVolume *)
static uint32_t packHcalIndex(int det, int z, int depth, int eta, int phi, int lay)
std::vector< G4LogicalVolume * > pmtLV
std::vector< G4LogicalVolume * > hfLV
bool isItScintillator(G4Material *)
bool next()
set current node to the next node in the filtered tree
virtual double getEnergyDeposit(G4Step *)
std::pair< std::string, MonitorElement * > entry
std::vector< std::pair< unsigned int, DDValue > > DDsvalues_type
std::maps an index to a DDValue. The index corresponds to the index assigned to the name of the std::...
A DDLogicalPart aggregates information concerning material, solid and sensitveness ...
HcalNumberingScheme * numberingScheme
void getHitPMT(G4Step *step)
double getAttenuation(G4Step *aStep, double birk1, double birk2, double birk3)
std::vector< int > hfLevels
virtual std::vector< std::string > getNames()
void NaNTrap(G4Step *step)
virtual G4bool getStepInfo(G4Step *aStep)
bool isItPMT(G4LogicalVolume *)
void setID(uint32_t unitID, double timeSlice, int trackID, uint16_t depth=0)
G4StepPoint * preStepPoint
static const G4LogicalVolume * GetVolume(const std::string &name)
Log< T >::type log(const T &t)
void readWeightFromFile(std::string)
void plotProfile(G4Step *step, G4ThreeVector pos, double edep, double time, int id)
void getHitFibreBundle(G4Step *step, bool type)
DDsvalues_type mergedSpecifics() const
void hitForFibre(G4Step *step)
double getHits(G4Step *aStep)
void initRun(G4ParticleTable *theParticleTable)
HcalNumberingFromDDD * numberingFromDDD
std::vector< std::vector< double > > tmp
double getResponseWt(G4Track *)
void initRun(G4ParticleTable *)
std::vector< G4String > fibreNames
bool firstChild()
set the current node to the first child ...
std::vector< G4Material * > materials
virtual bool filterHit(CaloG4Hit *, double)
T * make() const
make new ROOT object
void setCriteria(const DDValue &nameVal, comp_op, log_op l=AND, bool asString=true, bool merged=true)
double layerWeight(int, G4ThreeVector, int, int)
std::vector< G4String > hfNames
void resetForNewPrimary(G4ThreeVector, double)
std::map< uint32_t, double > layerWeights
HcalID unitID(int det, CLHEP::Hep3Vector pos, int depth, int lay=-1) const
uint32_t getUnitID() const
HCalSD(G4String, const DDCompactView &, SensitiveDetectorCatalog &, edm::ParameterSet const &, const SimTrackManager *)
HFShowerLibrary * showerLibrary
std::vector< G4LogicalVolume * > fibre2LV
const std::string & name() const
Returns the name.
void getFromParam(G4Step *step)
CaloG4Hit * createNewHit()
std::vector< G4String > matNames
bool isItFibre(G4LogicalVolume *)
double getEnergyDeposit() const
The DDGenericFilter is a runtime-parametrized Filter looking on DDSpecifcs.