- compute the rms/mean by channel for n secs (1200) seconds worth
of
data.
There must be a cal record in the file for the file to be processed.
- Do a robust linear fit to the rms/mean by channel throwing out
outliers.
The remaining channels will be the mask used to compute the total power
for each spectra of the 1200 seconds (and the cal).
- compute the total power (mean) for each 1 second record
using the
above mask.
- Over the entire strip compute the median of the total power using
the
data
from 4.
- Compute the cal scale factor : calK/(calOn-calOff). For the cal
off use
the last record of the strip (the one before the cal on). If the next
strip
starts within 6 seconds of the cal record, include the first
record
of that strip for the calOff. If there are two cal offs,
interpolate
their total power to the cal On time (if not, just use the single cal
off.
- Scale the total power data (from 4) to kelvins using the cal
scale
factor.
- Save the following to disc (one save file per day). assume there
are
NstripsTot
total strips:
- tpIAr[nstripsTot] (tpI struct), brmsAr[nstripsTot] (corget
struct)
,bcalRAr[nstripsTot]
(corget struct), and maskAr.
TpI struct:
SCAN LONG 503514951
FNAME STRING '/proj/a2010/wapp.20050204.a2010.0007.fits'
NPNTS LONG 1200
RMSFITA FLOAT Array[2, 7] (ao + a1*channum) fit torms polA
RMSFITB FLOAT Array[2, 7] (ao + a1*channum) fit to rms polB
MASKFRACT FLOAT Array[2, 7] (fraction of band each mask contained)
TPCORA FLOAT Array[1200, 7] (tot power deg K each point (polA)
TPCORB FLOAT Array[1200, 7] (tot power deg K each point (polB)
TPMEDIAN FLOAT Array[2, 7] (median tot pwr each strip cor Units (a,b)
CALK FLOAT Array[2, 7] (calval degK for [pols,pixels])
CALSCL FLOAT Array[2, 7] ( calK/(calOn-calOff) tp [pols,pixels]
NCALOFF FLOAT 2.00000 (number of cal offs used)
AZ FLOAT 359.638 ( azimuth feed)
ZA FLOAT 9.22350 ( za )
JD DOUBLE 2453405.3 (jd start of strip)
ALFAANGLE FLOAT 18.9999 (alfa rotation angle)
- bcalRAr . This is a corget struct holding the calon/caoff
spectra
for each cal
- maskAr . This holds the masks used to compute the
total
power.
Note that the daily save files are done by ast date so they may include
data from 2 different observing runs.
The save files can be input and merged using inpsav.pro. This
routine
creates one large array of tpI structs. It only takes strips that have
1200 seconds worth of data.