def GetCrossSpectrumMagLim(cosmo, a, z0, b, bias=1, alpha=1., lmax=1000, sigma_zph=0., compute_at_z0=False): DNDZ = dNdzMagLim(a, z0, b, sigma_zph=sigma_zph) limb = Limber(cosmo, lmin=0, lmax=lmax, compute_at_z0=compute_at_z0) gals = GalsTomo(cosmo, DNDZ, b=bias, alpha=alpha) return limb.GetCl(gals, k2=LensCMB(cosmo))
def GetAutoSpectrumMagLim(cosmo, a, z0, b, bias=1, alpha=1., lmax=1000, sigma_zph=0., compute_at_z0=False): # DNDZ = dNdzInterpolation(z, dndz, nbins=1, z_min=z[0], z_max=z[-1]) DNDZ = dNdzMagLim(a, z0, b, sigma_zph=sigma_zph, z_min=0, z_max=1) limb = Limber(cosmo, lmin=0, lmax=lmax, compute_at_z0=compute_at_z0) gals = GalsTomo(cosmo, DNDZ, b=bias, alpha=alpha) return limb.GetCl(gals)
def GetAutoSpectrum(cosmo, z, dndz, bins, b=1, alpha=1., lmax=1000, sigma_zph=0., compute_at_z0=False): DNDZ = dNdzInterpolation(z, dndz, bins=bins, sigma_zph=sigma_zph, z_min=0, z_max=1) limb = Limber(cosmo, lmin=0, lmax=lmax, compute_at_z0=compute_at_z0) gals = GalsTomo(cosmo, DNDZ, b=b, alpha=alpha) return limb.GetCl(gals)
def GetCrossSpectrum(cosmo, z, dndz, bins, b=1, alpha=1., lmax=1000, sigma_zph=0., i=0): DNDZ = dNdzInterpolation(z, dndz, bins=bins, sigma_zph=sigma_zph, z_min=0, z_max=1) # DNDZ = dNdzInterpolation(z, dndz, nbins=1, z_min=z[0], z_max=z[-1], sigma_zph=sigma_zph) limb = Limber(cosmo, lmin=0, lmax=lmax) gals = GalsTomo(cosmo, DNDZ, b=b, alpha=alpha) return limb.GetCl(gals, k2=LensCMB(cosmo), i=i)
nz, [zmin, zmax], b=1.24, alpha=1., lmax=500, sigma_zph=0.015) clgg_th = GetAutoSpectrum(cosmo_nl, z, nz, [zmin, zmax], b=1.24, alpha=1., lmax=500, sigma_zph=0.015) # clkk_th = cosmo_nl.cmb_spectra(2000)[:,4] lcmb = LensCMB(cosmo_nl) limb = Limber(cosmo_nl, lmax=2000) clkk_th = limb.GetCl(lcmb) nlkk = np.loadtxt( '/Users/fbianchini/Research/CosMojo/data/nlkk_planck2015.dat', unpack=1, usecols=[1])[:2001] # embed() # exit() # Power spectrum estimator # est = cs.Master(np.ones_like(mask), lmin=lmin, lmax=lmax, delta_ell=delta_ell, MASTER=1, pixwin=False) est = cs.Master(mask, lmin=lmin, lmax=lmax, delta_ell=delta_ell, MASTER=0,