The channel number of the wapp/alfa band center.
21feb06
For the alfa data taken with the wapps, the users
need to map the spectral channels to frequency and velocity. To do this
they need to know:
-
The RF frequency for the center of the band (fits keyword: CRVAL1).
-
The the pixel number of this frequency (fits keyword: CRPIX1). Also be
careful whether the pixel number starts counting at 0 (idl) or 1 (fits).
-
The change in frequency (channel width) as you increase the pixel number
(fits keyword: CDELT1)
-
Where in the reference pixel the RF center is located.
-
You also need to be aware that for an even number of pixels, flipping
the spectra (changing the sign of CDELT1) changes the pixel number for
the center (e.g....)
-
Start with the array [0,0,0,1,0,0]. The number 1 is in channel 3 (0 based).
-
Flipping the array gives: [0,0,1,0,0,0]. 1 is now in channel 2 (0 based).
-
The raw fits files are written with the spectra in decreasing frequency
order (the first channel is the highest frequency).
-
When Phil's idl routines read in a spectra, they always return the
spectra in increasing frequency order (they flip the spectra).
To measure the center channel of the alfa/wapp combination,
data was taken on 21feb06 using the following setup:
-
The band was centered at 1400 Mhz.
-
Three levels, 100 Mhz, 4096 channels were used to take the data (24 Khz
bin widths).
-
A birdie was radiated (using a helix) at 1400, 1400+binWd/2, 1400+binWd
(binWd=100Mhz/4096 or 24 Khz).
The plots show where
the band is centered (.ps) (.pdf)
:
-
Fig 1 top: This over plots the 3 spectra with birdies at 1400 (black),
1400+binWd/2 (red), and 1400 + binWd (green).
-
Fig 1 middle: A blowup of the first plot. You can see that all of
the 1400Mhz (black) and 1400Mhz + binWd (green) sit in 1 channel.
The red trace with the birdie at 1400Mhz+binWd/2 has equal power in two
channels (there has been on hanning smoothing). This shows that the 1400
Mhz birdie was centered exactly in the middle of whatever channel it fell
in.
-
Fig 1 bottom: This plots the 3 spectra versus channel number. The
1400 Mhz birdie falls in the center of channel 2047 (counting from zero).
This data has been read in with Phil's idl routines so the spectra
is in increasing frequency order.
-
Fig 2: This is a raw fits spectra read in with fxbread. The data
has not yet been flipped so increasing channel number corresponds to decreasing
frequency. The 1400 Mhz birdie is now in channel 2049 (1 based). I've switched
to 1 based since the fits keyword crpix1 is 1 based. The value in the fits
header (feb06) is 2048 rather than 2049. So the fits keyword is off by
1 channel.
Conclusions:
-
Using alfa with the wapps, the center of the band is in the center of channel
number 2047 (counting from 0). This assumes the spectra is in increasing
frequency order (Phil's idl routines always return the data in increasing
frequency order).
-
If you are reading the raw fits files (which are in decreasing frequency
order) then the center of the band is in the center of channel 2049 (counting
from 1 a la fits).
-
The fits keyword CRPIX1 is off by 1 (it reports 2048 rather than 2049 ..
1 based).
-
The idl routines corfrq() return the correct mapping of channel number
to frequency.
processing: x101/060221/chkalfa.pro
home_~phil