Barak 0.3.2 documentation

barak.convolve.convolve_constant_dv

«  barak.abundances.calc_abund   ::   Contents   ::   barak.convolve.convolve_psf  »

barak.convolve.convolve_constant_dv

barak.convolve.convolve_constant_dv(wa, fl, wa_dv=None, npix=4.0, vfwhm=None)[source]

Convolve a wavelength array with a gaussian of constant velocity width.

If vfwhm is specified an intermediate wavelength array with constant velocity pixel width is calculated. Otherwise, both wa_dv and npix must be given – this is faster because no intermediate array needs to be calculated.

Parameters :

fl, wa : arrays of floats, length N

The array to be convolved and its wavelengths.

vfwhm : float, optional

Full width at half maximum in velocity space (km/s) of the gaussian kernel with which to convolve fl.

npix : float, default 4

Number of pixels corresponding to vfwhm in wa_dv if given, otherwise wa is interpolated to an array with velocity pixel width = vfwhm / npix.

wa_dv : array of floats, default None

Wavelength array with a constant velocity width (this can be generated with make_constant_dv_wa_scale()).

Returns :

fl_out : array of length N

fl convolved with the gaussian kernel with the specified FWHM.

«  barak.abundances.calc_abund   ::   Contents   ::   barak.convolve.convolve_psf  »