Skip to content

Commit

Permalink
dropping a commit before i probably mess things
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremy-baier committed Dec 7, 2024
1 parent 932cfd3 commit 1b428b8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion hasasia/skymap.py
Original file line number Diff line number Diff line change
Expand Up @@ -386,6 +386,7 @@ def _fdp_angle_averaged(self, F_thresh, h0, fidx):
'''
The angle-averaged false dismissal probablity. See arXiv....
'''
snr = self.SNR(h0,0,0,fidx)
integrand = lambda psi, iota: np.sin(iota)/np.pi*ss.ncx2.cdf(2*F_thresh, df=4,
nc=self.SNR(h0,iota,psi,fidx).mean()**2)
return si.dblquad(integrand,0,np.pi,-np.pi/4,np.pi/4)[0]
Expand All @@ -395,7 +396,7 @@ def _solve_F_given_fap(self, fap0=0.003, Npsrs=None):

def _solve_F_given_fdp_snr(self, fdp0=0.05, snr=3, Npsrs=None, iota_psi_ave=False):
Npsrs = 1 if Npsrs is None else Npsrs
F0 = (4*Npsrs+snr**2)/2
F0 = (4*Npsrs+snr**2)/2
return sopt.fsolve(lambda F :self.false_dismissal_prob(F, snr, Npsrs=Npsrs, iota_psi_ave=iota_psi_ave)-fdp0, F0)

def _solve_snr_given_fdp_F(self, fdp0=0.05, F=3, Npsrs=None, iota_psi_ave=False):
Expand Down

0 comments on commit 1b428b8

Please sign in to comment.