aboutsummaryrefslogtreecommitdiff
path: root/src/dc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/dc.c')
-rw-r--r--src/dc.c30
1 files changed, 24 insertions, 6 deletions
diff --git a/src/dc.c b/src/dc.c
index 8a93c12..ff99f3f 100644
--- a/src/dc.c
+++ b/src/dc.c
@@ -454,7 +454,7 @@ int qvnhit(event *ev)
}
/* Returns 1 if the event is classified as a neck event. The definition of
- * a neck event comes from the SNOMAN companion:
+ * a neck event is a combination of the neck flag in the DAMN word:
*
* This cuts events containing neck tubes. It requires that either both
* tubes in the neck fire, or that one of those tubes fires and it has a
@@ -464,6 +464,14 @@ int qvnhit(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.
+ *
+ * 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
+ * high energy electron or muon travelling upwards could cause multiple neck
+ * PMTs to fire.
+ *
*/
int is_neck_event(event *ev)
{
@@ -471,7 +479,7 @@ int is_neck_event(event *ev)
int n;
int high_charge;
double avg_ept_psup;
- int nhit;
+ int nhit, nhit_bottom;
/* First, we compute the average ECA time for all the PSUP PMTs with z <= 0. */
@@ -498,11 +506,16 @@ int is_neck_event(event *ev)
* PMTs. */
n = 0;
high_charge = 0;
+ nhit = 0;
+ nhit_bottom = 0;
for (i = 0; i < MAX_PMTS; i++) {
- /* Require good calibrations. */
- if (!ev->pmt_hits[i].hit || ev->pmt_hits[i].ept <= -100) continue;
+ if (!ev->pmt_hits[i].hit) continue;
+
+ switch (pmts[i].pmt_type) {
+ case PMT_NECK:
+ /* Require good calibrations. */
+ if (ev->pmt_hits[i].ept <= -100) break;
- if (pmts[i].pmt_type == PMT_NECK) {
n += 1;
/* FIXME: The SNOMAN companion says "Early if defined by the neck
@@ -511,10 +524,15 @@ int is_neck_event(event *ev)
* place? */
if ((ev->pmt_hits[i].ehs > 70 || ev->pmt_hits[i].ehs < -110) &&
(ev->pmt_hits[i].ept < avg_ept_psup - 70.0)) high_charge = 1;
+ break;
+ case PMT_NORMAL:
+ nhit += 1;
+ if (pmts[i].pos[2] < NECK_BOTTOM_HEIGHT) nhit_bottom += 1;
+ break;
}
}
- if (n >= 2 || high_charge) return 1;
+ if ((n >= 2 || high_charge) && nhit_bottom >= nhit*NECK_BOTTOM_FRACTION) return 1;
return 0;
}