Skip to content
Snippets Groups Projects
Commit eef51f28 authored by audrey.chatillon's avatar audrey.chatillon
Browse files

[Epic] ON-GOING need to have one input per TrackID for 1s history data

parent f681b8b1
No related branches found
No related tags found
No related merge requests found
Pipeline #384256 passed
...@@ -52,8 +52,6 @@ void TEpicData::Dump() const { ...@@ -52,8 +52,6 @@ void TEpicData::Dump() const {
for (size_t i = 0 ; i < mysize ; i++){ for (size_t i = 0 ; i < mysize ; i++){
cout << "AnodeNbr: " << GetAnodeNbr(i) cout << "AnodeNbr: " << GetAnodeNbr(i)
<< " Q1: " << GetQ1(i) << " Q1: " << GetQ1(i)
<< " Q2: " << GetQ2(i)
<< " Qmax: " << GetQmax(i)
<< " Time: " << GetTime(i) << endl; << " Time: " << GetTime(i) << endl;
} }
} }
...@@ -36,15 +36,9 @@ class TEpicData : public TObject { ...@@ -36,15 +36,9 @@ class TEpicData : public TObject {
struct EpicAnodeData { struct EpicAnodeData {
UShort_t AnodeNbr; UShort_t AnodeNbr;
Double_t Q1; Double_t Q1;
Double_t Q2;
Double_t Qmax;
Double_t Time; Double_t Time;
Double_t Time_HF;
Double_t ToF;
Bool_t isFakeFission;
// vector of {Zstep, DEstep, DTstep} // vector of {Zstep, DEstep, DTstep}
std::vector<string> ParticleName; std::vector<string> ParticleName;
std::vector<int> ParentID;
std::vector<int> TrackID; std::vector<int> TrackID;
std::vector<Double_t> PosZ; std::vector<Double_t> PosZ;
std::vector<Double_t> DE; std::vector<Double_t> DE;
...@@ -53,14 +47,8 @@ class TEpicData : public TObject { ...@@ -53,14 +47,8 @@ class TEpicData : public TObject {
// Getters // Getters
UShort_t GetAnodeNbr() const { return AnodeNbr; } UShort_t GetAnodeNbr() const { return AnodeNbr; }
Double_t GetQ1() const { return Q1; } Double_t GetQ1() const { return Q1; }
Double_t GetQ2() const { return Q2; }
Double_t GetQmax() const { return Qmax; }
Double_t GetTime() const { return Time; } Double_t GetTime() const { return Time; }
Double_t GetTimeHF() const { return Time_HF; }
Double_t GetToF() const { return ToF; }
Bool_t IsFakeFission() const { return isFakeFission; }
const std::vector<string>& GetParticleName() const { return ParticleName; } const std::vector<string>& GetParticleName() const { return ParticleName; }
const std::vector<int>& GetParentID() const { return ParentID; }
const std::vector<int>& GetTrackID() const { return TrackID; } const std::vector<int>& GetTrackID() const { return TrackID; }
const std::vector<Double_t>& GetPosZ() const { return PosZ; } const std::vector<Double_t>& GetPosZ() const { return PosZ; }
const std::vector<Double_t>& GetDE() const { return DE; } const std::vector<Double_t>& GetDE() const { return DE; }
...@@ -95,11 +83,11 @@ class TEpicData : public TObject { ...@@ -95,11 +83,11 @@ class TEpicData : public TObject {
// add //! to avoid ROOT creating dictionnary for the methods // add //! to avoid ROOT creating dictionnary for the methods
public: public:
////////////////////// SETTERS //////////////////////// ////////////////////// SETTERS ////////////////////////
void Set(const UShort_t& n, const Double_t& q1, const Double_t& q2, const Double_t& qmax, void Set(const UShort_t& n, const Double_t& q1, const Double_t& t,
const Double_t& t, const Double_t& thf, const Double_t& tof, const Bool_t& fake, const std::vector<string>& name, const std::vector<int>& tid,
const std::vector<string>& name, const std::vector<int>& pid, const std::vector<int>& tid, const std::vector<double>& z, const std::vector<double>& de,
const std::vector<double>& z, const std::vector<double>& de, const std::vector<double>& dt) { const std::vector<double>& dt) {
fEpic_Data.push_back({n, q1, q2, qmax, t, thf, tof, fake, name, pid, tid, z, de, dt}); fEpic_Data.push_back({n, q1, t, name, tid, z, de, dt});
} }
const EpicAnodeData& operator[](const unsigned int& i) const {return fEpic_Data[i];} const EpicAnodeData& operator[](const unsigned int& i) const {return fEpic_Data[i];}
...@@ -107,14 +95,8 @@ class TEpicData : public TObject { ...@@ -107,14 +95,8 @@ class TEpicData : public TObject {
inline UShort_t GetMultiplicity() const {return fEpic_Data.size();} inline UShort_t GetMultiplicity() const {return fEpic_Data.size();}
UShort_t GetAnodeNbr(const unsigned short& i) const { return fEpic_Data[i].AnodeNbr; } UShort_t GetAnodeNbr(const unsigned short& i) const { return fEpic_Data[i].AnodeNbr; }
Double_t GetQ1(const unsigned int& i) const { return fEpic_Data[i].Q1; } Double_t GetQ1(const unsigned int& i) const { return fEpic_Data[i].Q1; }
Double_t GetQ2(const unsigned int& i) const { return fEpic_Data[i].Q2; }
Double_t GetQmax(const unsigned int& i) const { return fEpic_Data[i].Qmax; }
Double_t GetTime(const unsigned int& i) const { return fEpic_Data[i].Time; } Double_t GetTime(const unsigned int& i) const { return fEpic_Data[i].Time; }
Double_t GetTimeHF(const unsigned int& i) const { return fEpic_Data[i].Time_HF; }
Double_t GetToF(const unsigned int& i) const { return fEpic_Data[i].ToF; }
Bool_t GetFakeFissionStatus(const unsigned int& i) const { return fEpic_Data[i].isFakeFission; }
const std::vector<string>& GetParticleName(const unsigned int& i) const { return fEpic_Data[i].ParticleName; } const std::vector<string>& GetParticleName(const unsigned int& i) const { return fEpic_Data[i].ParticleName; }
const std::vector<int>& GetParentID(const unsigned int& i) const { return fEpic_Data[i].ParentID; }
const std::vector<int>& GetTrackID(const unsigned int& i) const { return fEpic_Data[i].TrackID; } const std::vector<int>& GetTrackID(const unsigned int& i) const { return fEpic_Data[i].TrackID; }
const std::vector<Double_t>& GetPosZ(const unsigned int& i) const { return fEpic_Data[i].PosZ; } const std::vector<Double_t>& GetPosZ(const unsigned int& i) const { return fEpic_Data[i].PosZ; }
const std::vector<Double_t>& GetDE(const unsigned int& i) const { return fEpic_Data[i].DE; } const std::vector<Double_t>& GetDE(const unsigned int& i) const { return fEpic_Data[i].DE; }
......
...@@ -88,13 +88,8 @@ void TEpicPhysics::BuildPhysicalEvent() { ...@@ -88,13 +88,8 @@ void TEpicPhysics::BuildPhysicalEvent() {
int A = m_EventData->GetAnodeNbr(e); int A = m_EventData->GetAnodeNbr(e);
AnodeNumber.push_back(m_PreTreatedData->GetAnodeNbr(e)); AnodeNumber.push_back(m_PreTreatedData->GetAnodeNbr(e));
Q1.push_back(m_PreTreatedData->GetQ1(e)); Q1.push_back(m_PreTreatedData->GetQ1(e));
Q2.push_back(m_PreTreatedData->GetQ2(e));
Qmax.push_back(m_PreTreatedData->GetQmax(e));
Time.push_back(m_PreTreatedData->GetTime(e)); Time.push_back(m_PreTreatedData->GetTime(e));
isFakeFission.push_back(m_PreTreatedData->GetFakeFissionStatus(e));
Time_HF.push_back(m_PreTreatedData->GetTimeHF(e));
ToF.push_back(m_PreTreatedData->GetToF(e));
} }
} }
...@@ -118,18 +113,8 @@ void TEpicPhysics::PreTreat() { ...@@ -118,18 +113,8 @@ void TEpicPhysics::PreTreat() {
double TimeOffset = 0; double TimeOffset = 0;
TimeOffset = Cal->GetValue("Epic/ANODE"+NPL::itoa(AnodeNumber)+"_TIMEOFFSET",0); TimeOffset = Cal->GetValue("Epic/ANODE"+NPL::itoa(AnodeNumber)+"_TIMEOFFSET",0);
double Time = m_EventData->GetTime(i); double Time = m_EventData->GetTime(i);
double TimeHF = m_EventData->GetTimeHF(i); m_PreTreatedData->Set(AnodeNumber, Q1, Time,
double tof = Time - TimeHF - TimeOffset;
if(tof < 0){
tof += Cal->GetValue("Epic/PULSE_TIMEOFFSET",0) ;
}
m_PreTreatedData->Set(AnodeNumber, Q1,
m_EventData->GetQ2(i),
m_EventData->GetQmax(i),
Time, TimeHF, tof,
m_EventData->GetFakeFissionStatus(i),
m_EventData->GetParticleName(i), m_EventData->GetParticleName(i),
m_EventData->GetParentID(i),
m_EventData->GetTrackID(i), m_EventData->GetTrackID(i),
m_EventData->GetPosZ(i), m_EventData->GetPosZ(i),
m_EventData->GetDE(i), m_EventData->GetDE(i),
......
...@@ -360,6 +360,8 @@ G4AssemblyVolume* Epic::BuildEpic(){ ...@@ -360,6 +360,8 @@ G4AssemblyVolume* Epic::BuildEpic(){
double posZ_first_cathode = posZ_anode - 0.5*thickness_A*mm - m_Distance_AK*mm - 0.5*m_Thickness_K*mm; double posZ_first_cathode = posZ_anode - 0.5*thickness_A*mm - m_Distance_AK*mm - 0.5*m_Thickness_K*mm;
// build the stack of cathodes / actinide samples / anodes to do build sensitive gas // build the stack of cathodes / actinide samples / anodes to do build sensitive gas
//double step_length_limit = m_Distance_AK*mm / 100.;
//G4UserLimits * user_limits = new G4UserLimits(step_length_limit*mm, 33.*mm, 1.*us, 0, 0);
G4UserLimits * user_limits = new G4UserLimits(25.*um, 33.*mm, 1.*us, 0, 0); G4UserLimits * user_limits = new G4UserLimits(25.*um, 33.*mm, 1.*us, 0, 0);
for(int i=0; i<m_nA; i++){ for(int i=0; i<m_nA; i++){
...@@ -535,60 +537,75 @@ void Epic::ReadSensitive(const G4Event* ){ ...@@ -535,60 +537,75 @@ void Epic::ReadSensitive(const G4Event* ){
// GaseousDetector scorer // GaseousDetector scorer
GaseousDetectorScorers::PS_GaseousDetector* Scorer= (GaseousDetectorScorers::PS_GaseousDetector*) m_EpicScorer->GetPrimitive(0); GaseousDetectorScorers::PS_GaseousDetector* Scorer= (GaseousDetectorScorers::PS_GaseousDetector*) m_EpicScorer->GetPrimitive(0);
int previous_trackID = -1;
unsigned int size = Scorer->GetMult(); unsigned int size = Scorer->GetMult();
cout << endl << " ================= Epic::ReadSensitive() Scorer size = " << size << endl;
for(unsigned int i = 0 ; i < size ; i++){ for(unsigned int i = 0 ; i < size ; i++){
vector<unsigned int> level = Scorer->GetLevel(i); vector<unsigned int> level = Scorer->GetLevel(i);
//double Time = RandGauss::shoot(Scorer->GetTime(i),Epic_NS::ResoTime);
//double Energy = RandGauss::shoot(Scorer->GetEnergy(i),Epic_NS::ResoEnergy); //double Energy = RandGauss::shoot(Scorer->GetEnergy(i),Epic_NS::ResoEnergy);
double Energy = Scorer->GetEnergy(i); // Attention Energy of all particles (FF, alpha, e-, ...) double Energy = Scorer->GetEnergy(i); // Attention Energy of all particles (FF, alpha, e-, ...)
vector<string> step_name = Scorer->GetParticleName(i); vector<string> step_name = Scorer->GetParticleName(i);
vector<int> step_parentid = Scorer->GetParentID(i); vector<int> step_trackID = Scorer->GetTrackID(i);
vector<int> step_trackid = Scorer->GetTrackID(i);
vector<double> step_posZ = Scorer->GetStepPosZ(i); vector<double> step_posZ = Scorer->GetStepPosZ(i);
vector<double> step_DE = Scorer->GetEnergyLossPerStep(i); vector<double> step_DE = Scorer->GetEnergyLossPerStep(i);
vector<double> step_time = Scorer->GetStepTime(i); vector<double> step_time = Scorer->GetStepTime(i);
double influence = 0 ; int Anode = level[0];
if(Energy>Epic_NS::EnergyThreshold){ double thickness_A = 2*Epic_NS::Cu_Thickness*mm + Epic_NS::Kapton_Thickness*mm;
double Time = RandGauss::shoot(Scorer->GetTime(i),Epic_NS::ResoTime); double posZ_anode = (1-m_nA)*(m_Distance_AK*mm + m_Thickness_K*mm) - std::trunc(0.5*m_nA)*(m_InterDistance_KK*mm + thickness_A);
int Anode = level[0]; posZ_anode += m_mapping_A[Anode] * (2. * (m_Distance_AK*mm + m_Thickness_K*mm) + m_InterDistance_KK*mm + thickness_A) ;
double thickness_A = 2*Epic_NS::Cu_Thickness*mm + Epic_NS::Kapton_Thickness*mm; //// FIXME : need a fixed binning in dz of 25*um
double posZ_anode = (1-m_nA)*(m_Distance_AK*mm + m_Thickness_K*mm) - std::trunc(0.5*m_nA)*(m_InterDistance_KK*mm + thickness_A); //// FIXME : one input per TrackID -> change the TEpicData TrackID and name should not be a vector anymore
posZ_anode += m_mapping_A[Anode] * (2. * (m_Distance_AK*mm + m_Thickness_K*mm) + m_InterDistance_KK*mm + thickness_A) ; //vector<string> name;
vector<string> name; //vector<int> trackID;
vector<int> parentid; //vector<double> dz;
vector<int> trackid; //vector<double> de;
vector<double> z; //vector<double> dt;
vector<double> de;
vector<double> dt; //double influence_pertrackID = 0 ;
//bool end_of_new_trackID = false ;
for(int j=0; j<step_name.size(); j++){ //cout << "step_name.size() = " << step_name.size() << endl;
//cout << "step #" << j << " , particle name = " << step_name.at(j) << " , z = " << step_posZ.at(j) << " , dE = " << step_DE.at(j) << " , t = " << step_time.at(j) << endl; //for(int j=0; j<step_name.size(); j++){
if(step_name.at(j)=="e-" || step_name.at(j)=="anti_nu_e") { // cout << "j = " << j << " : TrackID = " << step_trackID.at(j) << " [previous is " << previous_trackID << "]. Particle = " << step_name.at(j) << " Actual m_Event mult : " << m_Event->GetMultiplicity() << endl;
continue; // if(step_name.at(j)!="e-" || step_name.at(j)=="anti_nu_e"){
} // continue;
else{ // FF or alpha // }
//cout << "[FF or alpha]step #" << j << " , particle name = " << step_name.at(j) << ", z = " << step_posZ.at(j) << " , dE = " << step_DE.at(j) << " , t = " << step_time.at(j) << endl; // else if(step_name.at(j)=="alpha"){ // FF or alpha // to be fixed !
influence += step_DE.at(j) * TMath::Abs(step_posZ.at(j) - posZ_anode); //
name.push_back(step_name.at(j)); // cout << "j = " << j << " : TrackID = " << step_trackID.at(j) << " [previous is " << previous_trackID << "]. Particle = " << step_name.at(j) << " Actual m_Event mult : " << m_Event->GetMultiplicity() << endl;
parentid.push_back(step_parentid.at(j)); //
trackid.push_back(step_trackid.at(j)); // if(step_trackID.at(j) != previous_trackID){
z.push_back(step_posZ.at(j)); // //if(m_Event->GetMultiplicity()>0) end_of_new_trackID = true;
de.push_back(step_DE.at(j)); // if(previous_trackID != -1) end_of_new_trackID = true;
dt.push_back(step_time.at(j)); // previous_trackID = step_trackID.at(j) ;
} // }
} //
m_Event->Set(m_mapping_A[Anode], // set anode number // if(end_of_new_trackID == true) {
influence / m_Distance_AK*mm, // set Q1 FF or alpha only // m_Event->Set(m_mapping_A[Anode], // set anode number
Energy, // set Q2 // influence_pertrackID, // set Q1 FF or alpha only
Energy, // set Qmax // step_time.at(j), // set Time
Time, // set Time // name,trackID, dz, de, dt);
0., // set TimeHF // name.clear();
0., // set ToF // trackID.clear();
0, // status FakeFission // dz.clear();
name,parentid,trackid,z, de, dt); // de.clear();
} // dt.clear();
} // end_of_new_trackID = false;
// }
// double dz_anode = TMath::Abs(step_posZ.at(j) - posZ_anode) - 0.5*thickness_A ; // need to remove half thickness of Anode
// influence_pertrackID += (step_DE.at(j) * dz_anode) / m_Distance_AK*mm;
//
// name.push_back(step_name.at(j));
// trackID.push_back(step_trackID.at(j));
// dz.push_back(dz_anode);
// de.push_back(step_DE.at(j));
// dt.push_back(step_time.at(j));
// }// end of else
//}// end of loop over j
}// end of loop over i
} }
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
......
...@@ -48,10 +48,10 @@ vector<GaseousDetectorData>::iterator ...@@ -48,10 +48,10 @@ vector<GaseousDetectorData>::iterator
GaseousDetectorDataVector::find(const unsigned int& index) { GaseousDetectorDataVector::find(const unsigned int& index) {
for (vector<GaseousDetectorData>::iterator it = m_Data.begin(); for (vector<GaseousDetectorData>::iterator it = m_Data.begin();
it != m_Data.end(); it++) { it != m_Data.end(); it++) {
if ((*it).GetIndex() == index) if ((*it).GetIndex() == index) // comparison of the current index with the argument index
return it; return it; // return immediatly the iterator
} }
return m_Data.end(); return m_Data.end(); // return m_Data.end() if index is not found
} }
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
...@@ -73,46 +73,45 @@ G4bool PS_GaseousDetector::ProcessHits(G4Step* aStep, G4TouchableHistory*) { ...@@ -73,46 +73,45 @@ G4bool PS_GaseousDetector::ProcessHits(G4Step* aStep, G4TouchableHistory*) {
// Contain Particle Id, Energy, Time and as many copy number as nested volume // Contain Particle Id, Energy, Time and as many copy number as nested volume
unsigned int mysize = m_NestingLevel.size(); unsigned int mysize = m_NestingLevel.size();
string particlename = aStep->GetTrack()->GetParticleDefinition()->GetParticleName(); string particlename = aStep->GetTrack()->GetParticleDefinition()->GetParticleName();
int parentID = aStep->GetTrack()->GetParentID(); //if (particlename != "alpha") return TRUE;
int trackID = aStep->GetTrack()->GetTrackID(); int trackID = aStep->GetTrack()->GetTrackID();
double step_posZ = aStep->GetPreStepPoint()->GetPosition().z(); double step_posZ = aStep->GetPreStepPoint()->GetPosition().z();
t_Energy = aStep->GetTotalEnergyDeposit(); t_Energy = aStep->GetTotalEnergyDeposit();
t_Time = aStep->GetPreStepPoint()->GetGlobalTime(); // DeltaT [ns] since the begining of the simulated event up to the begining of the step t_Time = aStep->GetPreStepPoint()->GetGlobalTime(); // DeltaT [ns] since the begining of the simulated event up to the begining of the step
t_ParticleName.push_back(particlename); t_ParticleName.push_back(particlename);
t_ParentID.push_back(parentID);
t_TrackID.push_back(trackID); t_TrackID.push_back(trackID);
t_StepPosZ.push_back(step_posZ); t_StepPosZ.push_back(step_posZ);
t_EnergyLossPerStep.push_back(t_Energy); t_EnergyLossPerStep.push_back(t_Energy);
t_StepTime.push_back(t_Time); t_StepTime.push_back(t_Time);
t_Level.clear(); t_Level.clear();
for (unsigned int i = 0; i < mysize; i++) { for (unsigned int i = 0; i < mysize; i++) {
t_Level.push_back( t_Level.push_back(
aStep->GetPreStepPoint()->GetTouchableHandle()->GetCopyNumber( aStep->GetPreStepPoint()->GetTouchableHandle()->GetCopyNumber(
m_NestingLevel[i])); m_NestingLevel[i]));
} }
// Check if the particle has interact before, if yes, add up the energies and update the track // Check if the particle has interact before, if yes, add up the energies and update the track
vector<GaseousDetectorData>::iterator it; vector<GaseousDetectorData>::iterator it;
it = m_Data.find(GaseousDetectorData::CalculateIndex(t_Level)); it = m_Data.find(GaseousDetectorData::CalculateIndex(t_Level));
if (it != m_Data.end()) { if (it != m_Data.end()) {
// update the m_Data vector at each step // update the m_Data vector at each step corresponding at the same sensitive volume
it->Add(t_Energy); it->Add(t_Energy);
it->SetParticleName(particlename); it->SetParticleName(particlename);
it->SetParentID(parentID);
it->SetTrackID(trackID); it->SetTrackID(trackID);
it->SetStepPosZ(step_posZ); it->SetStepPosZ(step_posZ);
it->SetEnergyLossPerStep(t_Energy); it->SetEnergyLossPerStep(t_Energy);
it->SetStepTime(t_Time); it->SetStepTime(t_Time);
} }
else { else {
// first step: initialize a new m_Data vector // first step: initialize a new m_Data vector<GaseousDetectorData>
// t_Time [ns] is the time at first step // t_Time [ns] is the time at first step
m_Data.Set(t_Energy, t_Time, t_Level, t_ParticleName, t_ParentID, t_TrackID, t_StepPosZ, t_EnergyLossPerStep, t_StepTime); m_Data.Set(t_Energy, t_Time, t_Level, t_ParticleName, t_TrackID, t_StepPosZ, t_EnergyLossPerStep, t_StepTime);
} }
return TRUE; return TRUE;
} }
...@@ -127,7 +126,6 @@ void PS_GaseousDetector::clear() { ...@@ -127,7 +126,6 @@ void PS_GaseousDetector::clear() {
m_Data.clear(); m_Data.clear();
t_Level.clear(); t_Level.clear();
t_ParticleName.clear(); t_ParticleName.clear();
t_ParentID.clear();
t_TrackID.clear(); t_TrackID.clear();
t_StepPosZ.clear(); t_StepPosZ.clear();
t_EnergyLossPerStep.clear(); t_EnergyLossPerStep.clear();
......
...@@ -39,7 +39,6 @@ namespace GaseousDetectorScorers { ...@@ -39,7 +39,6 @@ namespace GaseousDetectorScorers {
const double& Time, const double& Time,
const vector<unsigned int>& Nesting, const vector<unsigned int>& Nesting,
const vector<string>& name, const vector<string>& name,
const vector<int>& pID,
const vector<int>& tID, const vector<int>& tID,
const vector<double>& posZ, const vector<double>& posZ,
const vector<double>& DE, const vector<double>& DE,
...@@ -49,7 +48,6 @@ namespace GaseousDetectorScorers { ...@@ -49,7 +48,6 @@ namespace GaseousDetectorScorers {
m_Energy=Energy; m_Energy=Energy;
m_Time=Time; m_Time=Time;
m_ParticleName=name; m_ParticleName=name;
m_ParentID=pID;
m_TrackID=tID; m_TrackID=tID;
m_StepPosZ=posZ; m_StepPosZ=posZ;
m_EnergyLossPerStep=DE; m_EnergyLossPerStep=DE;
...@@ -63,7 +61,6 @@ namespace GaseousDetectorScorers { ...@@ -63,7 +61,6 @@ namespace GaseousDetectorScorers {
double m_Energy; double m_Energy;
double m_Time; double m_Time;
vector<string> m_ParticleName; vector<string> m_ParticleName;
vector<int> m_ParentID;
vector<int> m_TrackID; vector<int> m_TrackID;
vector<double> m_StepPosZ; vector<double> m_StepPosZ;
vector<double> m_EnergyLossPerStep; vector<double> m_EnergyLossPerStep;
...@@ -78,7 +75,6 @@ namespace GaseousDetectorScorers { ...@@ -78,7 +75,6 @@ namespace GaseousDetectorScorers {
inline double GetEnergy() const {return m_Energy;} inline double GetEnergy() const {return m_Energy;}
inline double GetTime() const {return m_Time;} inline double GetTime() const {return m_Time;}
inline vector<string> GetParticleName() const {return m_ParticleName;} inline vector<string> GetParticleName() const {return m_ParticleName;}
inline vector<int> GetParentID() const {return m_ParentID;}
inline vector<int> GetTrackID() const {return m_TrackID;} inline vector<int> GetTrackID() const {return m_TrackID;}
inline vector<double> GetStepPosZ() const {return m_StepPosZ;} inline vector<double> GetStepPosZ() const {return m_StepPosZ;}
inline vector<double> GetEnergyLossPerStep() const {return m_EnergyLossPerStep;} inline vector<double> GetEnergyLossPerStep() const {return m_EnergyLossPerStep;}
...@@ -91,7 +87,6 @@ namespace GaseousDetectorScorers { ...@@ -91,7 +87,6 @@ namespace GaseousDetectorScorers {
void Add(const double& DE) {m_Energy+=DE;}; void Add(const double& DE) {m_Energy+=DE;};
// add specific information at each step // add specific information at each step
inline void SetParticleName(const string& name){m_ParticleName.push_back(name);} inline void SetParticleName(const string& name){m_ParticleName.push_back(name);}
inline void SetParentID(const int& id){m_ParentID.push_back(id);}
inline void SetTrackID(const int& id){m_TrackID.push_back(id);} inline void SetTrackID(const int& id){m_TrackID.push_back(id);}
inline void SetStepPosZ(const double& z){m_StepPosZ.push_back(z);} inline void SetStepPosZ(const double& z){m_StepPosZ.push_back(z);}
inline void SetEnergyLossPerStep(const double& DE){m_EnergyLossPerStep.push_back(DE);} inline void SetEnergyLossPerStep(const double& DE){m_EnergyLossPerStep.push_back(DE);}
...@@ -120,12 +115,11 @@ namespace GaseousDetectorScorers { ...@@ -120,12 +115,11 @@ namespace GaseousDetectorScorers {
const double& Time, const double& Time,
const vector<unsigned int>& Nesting, const vector<unsigned int>& Nesting,
const vector<string>& name, const vector<string>& name,
const vector<int>& pID,
const vector<int>& tID, const vector<int>& tID,
const vector<double>& z, const vector<double>& z,
const vector<double>& DE, const vector<double>& DE,
const vector<double>& t) { const vector<double>& t) {
m_Data.push_back(GaseousDetectorData(Energy,Time,Nesting,name,pID,tID,z,DE,t)); m_Data.push_back(GaseousDetectorData(Energy,Time,Nesting,name,tID,z,DE,t));
}; };
const GaseousDetectorData* operator[](const unsigned int& i) const {return &m_Data[i];}; const GaseousDetectorData* operator[](const unsigned int& i) const {return &m_Data[i];};
}; };
...@@ -161,7 +155,6 @@ namespace GaseousDetectorScorers { ...@@ -161,7 +155,6 @@ namespace GaseousDetectorScorers {
double t_Time; // time at first step double t_Time; // time at first step
// all these vectors are used to accumulate info at each step // all these vectors are used to accumulate info at each step
vector<string> t_ParticleName; vector<string> t_ParticleName;
vector<int> t_ParentID;
vector<int> t_TrackID; vector<int> t_TrackID;
vector<double> t_StepPosZ; vector<double> t_StepPosZ;
vector<double> t_EnergyLossPerStep; vector<double> t_EnergyLossPerStep;
...@@ -173,7 +166,6 @@ namespace GaseousDetectorScorers { ...@@ -173,7 +166,6 @@ namespace GaseousDetectorScorers {
inline double GetEnergy(const unsigned int& i) {return m_Data[i]->GetEnergy();}; inline double GetEnergy(const unsigned int& i) {return m_Data[i]->GetEnergy();};
inline double GetTime(const unsigned int& i) {return m_Data[i]->GetTime();}; inline double GetTime(const unsigned int& i) {return m_Data[i]->GetTime();};
inline vector<string> GetParticleName(const unsigned int& i) const {return m_Data[i]->GetParticleName();} inline vector<string> GetParticleName(const unsigned int& i) const {return m_Data[i]->GetParticleName();}
inline vector<int> GetParentID(const unsigned int& i) const {return m_Data[i]->GetParentID();}
inline vector<int> GetTrackID(const unsigned int& i) const {return m_Data[i]->GetTrackID();} inline vector<int> GetTrackID(const unsigned int& i) const {return m_Data[i]->GetTrackID();}
inline vector<double> GetStepPosZ(const unsigned int& i) const {return m_Data[i]->GetStepPosZ();} inline vector<double> GetStepPosZ(const unsigned int& i) const {return m_Data[i]->GetStepPosZ();}
inline vector<double> GetEnergyLossPerStep(const unsigned int& i) const {return m_Data[i]->GetEnergyLossPerStep();} inline vector<double> GetEnergyLossPerStep(const unsigned int& i) const {return m_Data[i]->GetEnergyLossPerStep();}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment