I'm trying to write a program to calculate galaxy angular power spectra and compare my result with that calculated by camb. In camb I use Gaussian window function with redshift=0.272, sigma=0.1 in calculation. Here is my camb code

Code: Select all

```
lmax = 2500
pars = camb.CAMBparams()
pars.set_cosmology(H0=67.5, ombh2=0.022, omch2=0.122)
pars.InitPower.set_params(As=2e-9, ns=0.965)
pars.set_for_lmax(lmax, lens_potential_accuracy=1)
pars.Want_CMB = False
pars.NonLinear = model.NonLinear_both
pars.SourceTerms.limber_windows = False
#pars.SourceTerms.counts_redshift = False
pars.SourceWindows = [GaussianSourceWindow(redshift=0.272, source_type='counts', bias=1.5, sigma=0.1, dlog10Ndm=-0.2)]
results = camb.get_results(pars)
cls = results.get_source_cls_dict()
```

Code: Select all

`qgal = 1.5 * np.exp(-(zs - 0.272) ** 2 / 2 / 0.1 ** 2) / np.sqrt(2 * np.pi) / 0.1`

But when comparing two results, I find they are not of the same order of magnitude. It seems that camb only uses the shape of Gaussian distribution, and it multiplies distribution function by a factor unknown for me. Until now I don't successfully find the related code in camb. So how does camb use the window function when calculating angular power spectra? Or in which file can I find it?

Thanks,

Lanyang