def fp_lens2(freq): p_lens2 = f.BB(freq * 1.e9, T_mir) * ( lens_emiss_MFT2 + ref_lens_MFT * f.BB(freq * 1.e9, Tr_lens) / f.BB(freq * 1.e9, T_lens)) * f.Eff( t_fil, n_fil, tan_fil, freq * 1.e9, ref_fil) * f.Eff( t_len, n_len, tan_len, freq * 1.e9, ref_len) * det_eff_MFT return p_lens2
def fp_cmb(freq): p_cmb = f.BB(freq * 1.e9, T_cmb) * hwp_eff_MFT * f.AptEff( dpixMFT * 1.e-3, bf_MFT, Fnum_MFT, freq * 1.e9) * lens_eff_MFT1 * lens_eff_MFT2 * f.Eff( t_fil, n_fil, tan_fil, freq * 1.e9, ref_fil) * f.Eff( t_len, n_len, tan_len, freq * 1.e9, ref_len) * det_eff_MFT # p_cmb= f.BB(freq*1.e9,T_cmb)*hwp_eff_MFT return p_cmb
def fp_apt(freq): #p_apt= f.BB(freq*1.e9,T_apt)*(1.-f.AptEff(dpixMFT*1.e-3, bf_MFT, Fnum_MFT, freq*1.e9))*lens_eff_MFT1*lens_eff_MFT2*f.Eff(t_fil, n_fil, tan_fil, freq*1.e9, ref_fil)*f.Eff(t_len, n_len, tan_len, freq*1.e9, ref_len)*det_eff_MFT p_apt = f.BB(freq * 1.e9, T_apt) * ( 1. - f.AptEff(dpixMFT * 1.e-3, bf_MFT, Fnum_MFT, freq * 1.e9)) * f.Eff( t_fil, n_fil, tan_fil, freq * 1.e9, ref_fil) * f.Eff( t_len, n_len, tan_len, freq * 1.e9, ref_len) # p_apt= f.BB(freq*1.e9,T_apt) return p_apt
def fp_fil(freq): p_fil = f.BB(freq * 1.e9, T_fil) * ( f.Emiss(t_fil, n_fil, tan_fil, freq * 1.e9, ref_fil) + ref_fil * f.BB(freq * 1.e9, Tr_fil) / f.BB(freq * 1.e9, T_fil)) * f.Eff( t_len, n_len, tan_len, freq * 1.e9, ref_len) * det_eff_MFT return p_fil
ref_hwp_MFT = ref_hwp_MFTarr[i] hwp_eff_MFT = 1. - hwp_emiss_MFT - ref_hwp_MFT lens_emiss_MFT1 = lens_emiss_MFTarr1[i] lens_eff_MFT1 = 1. - lens_emiss_MFT1 - ref_lens_MFT lens_emiss_MFT2 = lens_emiss_MFTarr2[i] lens_eff_MFT2 = 1. - lens_emiss_MFT2 - ref_lens_MFT p_cmb = fp_cmb(freqMFT[i]) apt_emiss = 1. - f.AptEff(dpixMFT * 1.e-3, bf_MFT, Fnum_MFT, freqMFT[i] * 1.e9) eff_lens1 = lens_eff_MFT1 eff_lens2 = lens_eff_MFT2 eff_fil = f.Eff(t_fil, n_fil, tan_fil, freqMFT[i] * 1.e9, ref_fil) eff_len = f.Eff(t_len, n_len, tan_len, freqMFT[i] * 1.e9, ref_len) eff_det = det_eff_MFT P_cmb, P_cmb_err = quad(fp_cmb, freq_l, freq_h) P_apt, P_apt_err = quad(fp_apt, freq_l, freq_h) P_lens2, P_lens2_err = quad(fp_lens2, freq_l, freq_h) P_fil, P_fil_err = quad(fp_fil, freq_l, freq_h) P_len, P_len_err = quad(fp_len, freq_l, freq_h) P_cmb = P_cmb * 1.e9 * 1.e12 P_apt = P_apt * 1.e9 * 1.e12 * lens_eff_MFT1 * lens_eff_MFT2 * det_eff_MFT P_lens2 = P_lens2 * 1.e9 * 1.e12 P_fil = P_fil * 1.e9 * 1.e12 P_len = P_len * 1.e9 * 1.e12