aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortlatorre <tlatorre@uchicago.edu>2018-11-14 15:24:25 -0600
committertlatorre <tlatorre@uchicago.edu>2018-11-14 15:24:25 -0600
commit8b16bcb386c4e9dd4f7601159858d40b96b4449e (patch)
tree708d2066a03d91c81fdeb0a1e8e6962579fee03a
parentfc8db35aeda8d2bc02a023b9ebcd8b8cddadcbed (diff)
downloadsddm-8b16bcb386c4e9dd4f7601159858d40b96b4449e.tar.gz
sddm-8b16bcb386c4e9dd4f7601159858d40b96b4449e.tar.bz2
sddm-8b16bcb386c4e9dd4f7601159858d40b96b4449e.zip
update TODO and small updates to likelihood calculation
-rw-r--r--TODO1
-rw-r--r--src/likelihood.c12
2 files changed, 5 insertions, 8 deletions
diff --git a/TODO b/TODO
index 2ccd95d..a3ad150 100644
--- a/TODO
+++ b/TODO
@@ -29,3 +29,4 @@
other rings
- add rayleigh scattering to likelihood function
- add muon shower PDF? delta rays?
+- calculate path length through acrylic?
diff --git a/src/likelihood.c b/src/likelihood.c
index ca73902..707ff38 100644
--- a/src/likelihood.c
+++ b/src/likelihood.c
@@ -224,11 +224,7 @@ static double get_expected_charge(double x, double beta, double theta0, double *
R = NORM(pos);
- if (R <= AV_RADIUS) {
- n = n_d2o;
- } else {
- n = n_h2o;
- }
+ n = (R <= AV_RADIUS) ? n_d2o : n_h2o;
*reflected = 0.0;
if (beta < 1/n) return 0.0;
@@ -646,10 +642,10 @@ double nll_muon(event *ev, int id, double T0, double *pos, double *dir, double t
path *path;
static double mu_direct[MAX_PMTS];
- static double mu_shower[MAX_PMTS] = {0};
+ static double mu_shower[MAX_PMTS];
static double ts[MAX_PMTS];
- static double ts_shower[MAX_PMTS] = {0};
- static double ts_sigma[MAX_PMTS] = {0};
+ static double ts_shower[MAX_PMTS];
+ static double ts_sigma[MAX_PMTS];
static double mu[MAX_PMTS];
double mu_noise, mu_indirect;