From 1c8051e72f3c00384cb3e5b07d22b325ddcd2273 Mon Sep 17 00:00:00 2001 From: tlatorre Date: Mon, 29 Jul 2019 12:33:59 -0500 Subject: flag PMT charges below qlo This commit updates get_event() to flag PMT charges below qlo, which is the minimum charge value that we compute the charge PDFs for. This is to prevent the likelihood from returning nan. --- src/sno_charge.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/sno_charge.c') diff --git a/src/sno_charge.c b/src/sno_charge.c index 17e4ebc..f36bfb5 100644 --- a/src/sno_charge.c +++ b/src/sno_charge.c @@ -106,6 +106,16 @@ static double QSMEAR_ADC = 3.61; /* Mean of simulated threshold distribution. */ static double MEAN_THRESH = 8.5; +double get_qlo(void) +{ + return qlo; +} + +double get_qhi(void) +{ + return qhi; +} + static double nlopt_log_pq(unsigned int n, const double *x, double *grad, void *params) { int i; -- cgit