EMTiming Simulation Instructions
 (Resolution and Simulation for EMTiming - CDF Note 7928)



The EMTiming system is simulated using a Monte Carlo (MC) that is run, independently, after event generation(e.g. PYTHIA) and detector simulation(cdfSim). It is compatible with cdfsoft release 6.1.2 or later. The simulation is unusual in that it is not part of CdfSim and a parameterized simulation. Its purpose is mainly to reproduce the time of arrival of single particles, it handles all MC particle types that hit the detector. Of particular interest, however, are high energy electrons and photons that allow for the study of prompt decays like W->e&nu and searches for long-lived particles that decay to photons. The output are filled EMTD_StorableBank which are the TDC readout banks as in real data.


 
Monte Carlo Generation and Reconstruction

The process of turning MC events into TDC readout is done in 7 steps (described in more detail in CDF Note 7928):
    1. Calculate the true arrival time for a particle at the calorimeter face from the OBSV_StorableBank and correct for the time of flight (TOF) and vertex time.
The simulated arrival time, tarrival, for a particle at the calorimeter must take into account the true collision time, the travel time of any parent particles, their decay time and position, and final-state particle TOF. All this information is stored in the OBSV_StorableBank. It can be expressed as follows:

tarrival  =    tvert +    |xf - xvert|
|vpart|
(1)

where vpart is the velocity of the final-state particle, xvert and tvert the position and time of its parent-particles decay (or the collision time/position if it is promptly produced), and xf is the position where the final-state particle interacts with the central(CES) and plug(PES) shower maximum subdetectors. For example, for a neutralino decaying into a photon and a gravitino, tvert is the time the neutralino decays. To get the TDC times we will essentially run the slewing calibration in reverse. Since these calibrations assume that particles come from the center of the detector, xevent = 0 and tevent = 0 ns, tarrival is corrected for the TOF of the particle that it would have if it came from 0. The corrected arrival time, tcorrarrival , is then:

tcorrarrival  =    tarrival -    |xf|
c
(2)

It is this number that is used to get the TDC time after smearing for the various effects.
    2. Check to see if it hits an EMTiming-instrumented part of the detector
Next particles that do not deposit energy in the EM calorimeter or that have a decay vertex outside the detector volume are filtered out.
    3. Smear the corrected arrival time for the intrinsic resolution.
If particle passes the above requirements the intrinsic EMTiming resolution is implemented as a Gaussian smearing of tcorrarrival and is varied according to its energy-dependence derived from jet data. (see Section 3 D and Fig. 6 in CDF Note 7928)
 
Coding and tcl details: Monte Carlo Framework and Modules

  • The EMTiming MC modules are located in the CalorTimeMods package.
  • The executable part is test/McTiming.cc.
  • The library part is src/EMTDBankSimModule.cc and CalorTimeMods/EMTDBankSimModule.hh.
  • The binary is run after MC files are generated independently with cdfSim.
  • As with real data the EMTiming information is filled in the EMTD_StorableBank.
  • Both reconstructed particle information from CalData and true information from OBSV_StorableBank and OBSP_StorableBank are used as input.
  • We quote results using PYTHIA with the default settings in the cdfSim framework and the default MC production settings of cdfsoft release 6.1.2.
  • Here is a code snipit of tcl file (test/run_McTiming.tcl):
    • include files yourproduction.dst #this is a input file for a test (In the tcl file run_MCTiming.tcl, an input file "root://txpc11:5151//data11/wagnp/CdfSim_longlived/output/gmsb/40/test/prod_output_1.dst" was specified in the DHInput module. Users must replace this file with /cdf/scratch/elee/Wenu/prod_output_1.dst in fcdflnx8.fnal.gov) , which is W->e&nu MC sample
      module talk EMTDBankSimModule
      debug set f
      verbose set f
      genericCast set f # this only adds the emtd bank but doesn't fill anything
      fillDetector set CEM PEM # add timing information to particles that traverse these detectors
      smearTime set t # if this is true then the generated arrival time is randomly varied by a Gaussian with a sigma that is set by "timeSigma" to simulate the intrinsic timing resolution
      timeSigma set 0.505 #see above
      useEffCalibs set t #use the calibration tables to estimate the efficiency as a function of energy
      dbName set TEXT #use the slewing calibration data of the local calibration tables at the location "calibDirName"
      calibDirName set yourcalibraiontalbe # see above, you must use /cdf/home/elee/CalibTables/v2/ in fcdflnx8.fnal.gov more information about calibration table
      algorithm set 2 #slewing calibration algorithm
      show
      exit


      The following applies the calibration modules on the raw time as for real data

      module disable CalorimetryModule
      module enable EMTDBankSimModule
      module enable CalqModule
      path create TimingPath ManagerSequence
      path append TimingPath HepRootManager Prereq CalqModule CalorimetryModule EMTDBankSimModule
      path disable AllPath
      path enable TimingPath


     
    How to Run

    We will have a binary executable file, bin/Linux2_SL-GCC_3_4/McTiming, to run test/run_McTiming.tcl.

      1. source ~cdfsoft/cdf2.cshrc
      2. setup cdfsoft2 6.1.4
      3. newrel -t 6.1.4 MC_Timing
      4. cd MC_Timing
      5. addpkg CalorTimeMods
      6. gmake CalorTimeMods.lib
      7. gmake CalorTimeMods.tbin
      8. bin/Linux2_SL-GCC_3_4/McTiming CalorTimeMods/test/run_McTiming.tcl

     
    Example Results for 30,000 W->e&nu events

    After running the above commands to make 30,000 W->e&nu events we are left with the event data file as well as the file TimingNtuple.root. Inside this file are two Trees: sim and gen. The gen tree is from the OBSV_StorableBank and is the "true" information for all particles. The sim tree contains the timing information for only those particles that have hits. We next provide some example plots for our sample:

    generated time generated time after removing slow (delayed) particles
     

    - Generated Time :
    The tcorrarrival is filled as the gt0 variable in the sim Tree in TimingNtuple.root. One would naively expect this to be centered at zero in eq.(2). In the first plot we can see the mean shift is ~0.1 ns. This is caused by slow(delayed) particles, e.g. heavy proton and other heavy EM interacting particles(vpart is less than the speed of light c in eq (1) above). By only considering high energy particles E > 2 GeV, we see the mean is 0 as we expected in the second plot.

    raw time
     

    - Raw Time :
    We next show the results of the simulation, as stored to t0raw variable in the sim Tree. After all seven steps we are left with a set of towers with a "raw time" where the slewing has been simulated and the output is truncated to integer to simulate the TDC. This is put into an EMTD_StorableBank so that the time format resembles the output of the TDCs for real data. In the plot the values range from 560 to 590 ns for prompt particles and has an RMS of ~8 ns due to the energy slewing, the vertex t0 variations etc. (see CDF Note 7928, Section 1, Figs 2 and 3, Tables I and II). This number is typical and reflects the hardware difference between the TDCstart time and the time of arrival at the TDC input. Again, the user should note that the mean and RMS of this distribution reflect the sample distribution; RMS's that are not within 2 ns of the 8ns expected are problematic and a mean outside the range 560 to 590 is also considered problematic.



    For comments or questions, please e-mail to Eunsin Lee or David Toback