23.11.2011 Kamil Sedlak
Three major changes in the photon simulation: 1) Added timeC1 ... timeC20 2) Added odet_nPhotPrim[odet_n] (number of primary photons) 3) Added all individual photons: phot_time[nOptPhotDet] Documentation has not been updated yet.
This commit is contained in:
@ -31,32 +31,55 @@
|
||||
class G4Step;
|
||||
class G4HCofThisEvent;
|
||||
|
||||
class APDidClass {
|
||||
public:
|
||||
APDidClass(G4int xAPDcellID, G4int xAPDcellNphot) {
|
||||
APDcellID = xAPDcellID;
|
||||
APDcellNphot = xAPDcellNphot;
|
||||
}
|
||||
~APDidClass() {}
|
||||
G4int GetAPDcellID() const {return APDcellID;}
|
||||
G4int GetAPDcellNphot() const {return APDcellNphot;}
|
||||
void IncreaseAPDcellNphot() {APDcellNphot++;}
|
||||
|
||||
private:
|
||||
G4int APDcellID;
|
||||
G4int APDcellNphot;
|
||||
};
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class signalInfo {
|
||||
public:
|
||||
signalInfo(G4int id, G4int nP, G4double tFirst, G4double tSecond, G4double tThird,
|
||||
signalInfo(G4int id, G4int nP, G4int nPprim, G4double tFirst, G4double tSecond, G4double tThird,
|
||||
G4double tA, G4double tB, G4double tC, G4double tD, G4double tE, G4double tLast,
|
||||
G4double tCFD, G4double aCFD, G4double tCFDarray[1000])
|
||||
G4double tCFD, G4double aCFD, G4double tCFDarray[1000], G4double tOPSAC1array[21])
|
||||
{
|
||||
detID=id; nPhot=nP; timeFirst=tFirst; timeSecond=tSecond; timeThird=tThird;
|
||||
detID=id; nPhot=nP; nPhotPrim=nPprim; timeFirst=tFirst; timeSecond=tSecond; timeThird=tThird;
|
||||
timeA=tA; timeB=tB; timeC=tC; timeD=tD; timeE=tE; timeLast=tLast;
|
||||
timeCFD=tCFD; amplCFD=aCFD;
|
||||
if (musrRootOutput::store_odet_timeCFDarray) {for(int i=0;i<1000;i++) {timeCFDarray[i]=tCFDarray[i];}}
|
||||
if (musrRootOutput::store_odet_timeC1) {for(int i=1;i<21;i++) {timeC1array[i] =tOPSAC1array[i];}}
|
||||
}
|
||||
~signalInfo() {}
|
||||
void transferDataToRoot(musrRootOutput* myRootOut, G4int nn) {
|
||||
myRootOut->SetOPSAinfo(nn,detID,nPhot,timeFirst,timeSecond,timeThird,
|
||||
myRootOut->SetOPSAinfo(nn,detID,nPhot,nPhotPrim,timeFirst,timeSecond,timeThird,
|
||||
timeA,timeB,timeC,timeD,timeE,timeLast,timeCFD,amplCFD);
|
||||
for (Int_t kk=0; kk<13; kk++) {
|
||||
for (Int_t ll=0; ll<5; ll++) {
|
||||
int index = (ll+1)*100+kk;
|
||||
myRootOut -> SetCFDSpecialInfo(index,timeCFDarray[index]);
|
||||
if (musrRootOutput::store_odet_timeCFDarray) {
|
||||
for (Int_t kk=0; kk<13; kk++) {
|
||||
for (Int_t ll=0; ll<5; ll++) {
|
||||
int index = (ll+1)*100+kk;
|
||||
myRootOut -> SetCFDSpecialInfo(index,timeCFDarray[index]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (musrRootOutput::store_odet_timeC1) myRootOut -> SetTimeC1SpecialInfo(timeC1array);
|
||||
}
|
||||
|
||||
private:
|
||||
G4int detID;
|
||||
G4int nPhot;
|
||||
G4int nPhotPrim;
|
||||
G4int nPhot_abs;
|
||||
G4int nPhot_refl;
|
||||
G4int nPhot_other;
|
||||
@ -72,6 +95,7 @@ class signalInfo {
|
||||
G4double timeCFD;
|
||||
G4double amplCFD;
|
||||
G4double timeCFDarray[1000];
|
||||
G4double timeC1array[1000];
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@ -135,7 +159,8 @@ class musrScintSD : public G4VSensitiveDetector
|
||||
musrRootOutput* myRootOutput;
|
||||
|
||||
// for optical photon counting
|
||||
typedef std::multimap<G4double,Int_t> optHitDetectorMapType;
|
||||
// typedef std::multimap<G4double,Int_t> optHitDetectorMapType;
|
||||
typedef std::multimap<G4double,APDidClass> optHitDetectorMapType;
|
||||
typedef std::map<Int_t,optHitDetectorMapType*> optHitMapType;
|
||||
optHitMapType optHitMap;
|
||||
// for optical photon signal analysis (OPSA)
|
||||
@ -175,8 +200,28 @@ class musrScintSD : public G4VSensitiveDetector
|
||||
G4bool APDcrossTalkRequested;
|
||||
G4double APDcrossTalkProb;
|
||||
|
||||
void FireAPDcell(optHitDetectorMapType* optHitDetectorMap, G4int APDcellID, G4double time);
|
||||
void FireAPDcell(optHitDetectorMapType* optHitDetectorMap, G4int APDcellID, G4double time, G4int nTruePhe);
|
||||
|
||||
static const G4double OPSA_C1_threshold;
|
||||
static const G4double OPSA_C2_threshold;
|
||||
static const G4double OPSA_C3_threshold;
|
||||
static const G4double OPSA_C4_threshold;
|
||||
static const G4double OPSA_C5_threshold;
|
||||
static const G4double OPSA_C6_threshold;
|
||||
static const G4double OPSA_C7_threshold;
|
||||
static const G4double OPSA_C8_threshold;
|
||||
static const G4double OPSA_C9_threshold;
|
||||
static const G4double OPSA_C10_threshold;
|
||||
static const G4double OPSA_C11_threshold;
|
||||
static const G4double OPSA_C12_threshold;
|
||||
static const G4double OPSA_C13_threshold;
|
||||
static const G4double OPSA_C14_threshold;
|
||||
static const G4double OPSA_C15_threshold;
|
||||
static const G4double OPSA_C16_threshold;
|
||||
static const G4double OPSA_C17_threshold;
|
||||
static const G4double OPSA_C18_threshold;
|
||||
static const G4double OPSA_C19_threshold;
|
||||
static const G4double OPSA_C20_threshold;
|
||||
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user