diff options
author | tlatorre <tlatorre@uchicago.edu> | 2019-08-27 14:13:52 -0500 |
---|---|---|
committer | tlatorre <tlatorre@uchicago.edu> | 2019-08-27 14:13:52 -0500 |
commit | 265bee5b44fedc85992b8eecb1c5ad93a33bb9ea (patch) | |
tree | 966591e01a29c3c9881eced5435d556e37c87bb0 /src/dc.c | |
parent | 28850f2e412966c10e1cef2b8a3651b9ce2a572c (diff) | |
download | sddm-265bee5b44fedc85992b8eecb1c5ad93a33bb9ea.tar.gz sddm-265bee5b44fedc85992b8eecb1c5ad93a33bb9ea.tar.bz2 sddm-265bee5b44fedc85992b8eecb1c5ad93a33bb9ea.zip |
update neck cut
This commit updates the second requirement of the neck event tag to flag events
in which either 50% of the normal PMT hits are at the bottom of the detector
*or* 50% of the ECA calibrated charge is at the bottom of the detector.
This update was added after testing the cut out on run 10058 which is not in
the golden run list and noticing that there were 4 events which were very
clearly neck events but which didn't get tagged.
Diffstat (limited to 'src/dc.c')
-rw-r--r-- | src/dc.c | 15 |
1 files changed, 11 insertions, 4 deletions
@@ -478,8 +478,8 @@ double get_neck_tube_cut_time_diff(event *ev) * average ECA time of the PSUP PMTS with z les than 0. After the cable * changes to the neck tubes this time difference changes to 15ns. * - * and the SNOOP definition of a neck event which requires that 50% of the - * normal PMTs have z <= -425.0. + * and the added requirement that 50% of the normal PMTs have z <= -425.0 or + * 50% of the ECA calibrated charge for normal PMTs have z <= -425.0. * * I added the requirement that 50% of the normal PMTs be near the bottom since * for the high energy events I'm interested in, it's entirely possible that a @@ -495,6 +495,7 @@ int is_neck_event(event *ev) double avg_ept_psup; int nhit, nhit_bottom; double time_diff; + double ehs, ehs_bottom; /* First, we compute the average ECA time for all the PSUP PMTs with z <= 0. */ @@ -525,6 +526,8 @@ int is_neck_event(event *ev) high_charge = 0; nhit = 0; nhit_bottom = 0; + ehs = 0; + ehs_bottom = 0; for (i = 0; i < MAX_PMTS; i++) { if (!ev->pmt_hits[i].hit) continue; @@ -543,13 +546,17 @@ int is_neck_event(event *ev) (ev->pmt_hits[i].ept < avg_ept_psup - time_diff)) high_charge = 1; break; case PMT_NORMAL: + if (pmts[i].pos[2] < NECK_BOTTOM_HEIGHT) { + nhit_bottom += 1; + ehs_bottom += ev->pmt_hits[i].ehs; + } nhit += 1; - if (pmts[i].pos[2] < NECK_BOTTOM_HEIGHT) nhit_bottom += 1; + ehs += ev->pmt_hits[i].ehs; break; } } - if ((n >= 2 || high_charge) && nhit_bottom >= nhit*NECK_BOTTOM_FRACTION) return 1; + if ((n >= 2 || high_charge) && ((nhit_bottom >= nhit*NECK_BOTTOM_FRACTION) || (ehs_bottom >= ehs*NECK_BOTTOM_FRACTION))) return 1; return 0; } |