Changeset 135 in Idarraga


Ignore:
Timestamp:
Apr 15, 2011, 8:15:23 AM (13 years ago)
Author:
benoit
Message:

Added proper energy to TOT function, with option to switch between FEI3 and FEI4 with the FEIX switch

File:
1 edited

Legend:

Unmodified
Added
Removed
  • allpix/src/AllPixFEI3StandardDigitizer.cc

    r134 r135  
    113113        doFullField = false;
    114114        FEIX = 3;
     115
     116        switch (FEIX) {
     117
     118        case 3 :
     119                MipTOT=60;
     120                MipCharge=22000;
     121                CounterDepth=255;
     122        case 4 :
     123                MipTOT=5;
     124                MipCharge=22000;
     125                CounterDepth=15;
     126        default :
     127                MipTOT=60;
     128                MipCharge=22000;
     129                CounterDepth=255;
     130
     131        }
     132
     133
     134
     135
    115136}
    116137
     
    544565{
    545566
    546         switch()
    547 
    548         const G4double dEdt = (22000.*elec- threshold)/(60*25.*ns);
     567        G4double dEdt = (MipCharge*elec- threshold)/(MipTOT*25.*ns);
    549568        G4int TOT = TMath::FloorInt((Energy-threshold)/(dEdt*25.*ns));
    550569        if(Energy<threshold) TOT=0;
    551570        if (TOT<0) TOT=0;
    552         if (TOT>256) TOT=256;
     571        if (TOT>CounterDepth) TOT=CounterDepth;
    553572
    554573        return TOT;
Note: See TracChangeset for help on using the changeset viewer.