scopesim.optics.image_plane_utils.sub_pixel_fractions#
- scopesim.optics.image_plane_utils.sub_pixel_fractions(x, y)#
Make a list of pixel coordinates and weights to reflect sub-pixel shifts.
A point source which isn’t centred on a pixel can be modelled by a centred PSF convolved with a shifted delta function. A fraction of the delta function in moved into each of the adjoining pixels. For example, a star at
(x,y)=(0.2, 0.2)would be represented by a following pixel weights:--------------- | 0.16 | 0.04 | --------------- | 0.64 | 0.16 | ---------------
where (0,0) is the centre of the bottom-left pixel
Given (x,y) pixel coordinates, this function returns the fractions of flux that should go into the surrounding pixels, as well as the coordinates of those neighbouring pixels.