def cumsum_snr(freqs, detector, data, hpf, hxf, theta, phi, psi, zeroFreq=False, normalizeTemplate=True ):
"""
returns the cumulative sum of the snr as a function of frequency
does NOT maximize over the phase at coalescence
"""
template = detector.project(freqs, hpf, hxf, theta, phi, psi, zeroFreq=zeroFreq)
PSD = detector.PSD(freqs)
deltaF = freqs[1]-freqs[0]
ans = 2*np.cumsum(deltaF*np.conjugate(data)*template/PSD).real
if normalizeTemplate:
ans /= np.sum(deltaF*np.conjugate(template)*template/PSD).real**0.5
return ans
#------------------------
评论列表
文章目录