QUOCKA-team / quocka

MIT License
5 stars 6 forks source link

Incorrect normalization in makecube.py #13

Closed AlecThomson closed 4 years ago

AlecThomson commented 5 years ago

In makecube.py, the smoothing kernel is currently:

g = Gaussian2DKernel(hpbw / (2. * np.sqrt(2. * np.log(2.))) / grid)
data = convolve(data, g, boundary='extend')

This was written for absolutely calibrated data (i.e. Kelvin-scale). As the data are in Jy/Beam, this normalization/kernel is incorrect.

The kernel should take into account elliptical beams. Additionally, I think we need to include the normalization factor:

data = convolve(data, g, boundary='extend') * (2 * np.pi * sig_min * sig_maj)

Where,sig_min and sig_maj are the standard deviations of the minor and major axes, respectively.