~mwinter4/maus/ckov-update

« back to all changes in this revision

Viewing changes to src/map/MapCppTOFSlabHits/MapCppTOFSlabHits.cc

  • Committer: Chris Rogers
  • Date: 2013-02-01 13:08:06 UTC
  • mfrom: (659.1.57 release-candidate)
  • Revision ID: chris.rogers@stfc.ac.uk-20130201130806-kkxs626x4loudqsm
Tags: MAUS-v0.4, MAUS-v0.4.3
MAUS-v0.4.3

Show diffs side-by-side

added added

removed removed

Lines of Context:
258
258
    xDocPMT0["charge"] = xChargeDigit0;
259
259
    xDocPMT1["charge"] = xChargeDigit1;
260
260
    xDocSlabHit["charge"] = xChargeDigit0 + xChargeDigit1;
261
 
    xDocSlabHit["charge_product"] = xChargeDigit0 * xChargeDigit1 / (xChargeDigit0 + xChargeDigit1);
 
261
    if ((xChargeDigit0 + xChargeDigit1) == 0)
 
262
        xDocSlabHit["charge_product"] = 0;
 
263
    else
 
264
        xDocSlabHit["charge_product"] =
 
265
                 xChargeDigit0 * xChargeDigit1 / (xChargeDigit0 + xChargeDigit1);
262
266
  }
263
267
 
264
268
  // Calculate the measured value of the time in nanoseconds.