.help fvelalc Feb96 ftools.vela5b
.ih
NAME
fvelalc - FTOOL to generate a light curve from the Vela 5B satellite raw data
.ih
USAGE
fvelalc sourcename long_src lat_src searchrad collim spincheck pointcheck
        backopt minflux maxflux maxerr beginyr beginday endyr endday 
        weight binopt timbin (imax)
.ih
DESCRIPTION

This FTOOL generates a FITS light curve from the Vela 5B raw data, extracting
data from a radius specified by the user around the source.  This tool 
assumes there are no other sources in the Vela 5B detectors' field of 
view (roughly 6 degrees radius).  If the source of interest is in a potentially
confused field, the appropriate set of FTOOLS are FVELMAP and FVELGALLC.

  For further information regarding this task, current plans/schedule, 
comments or bug reports, please contact Jesse S. Allen
(http://heasarc.gsfc.nasa.gov/cgi-bin/ftoolshelp).

.ih
PARAMETERS
.ls sourcename [string]
The name of the source.  This will be passed as a keyword value to the 
FITS file; strings longer than 16 characters will be trunctated in the 
FITS OBJECT keyword entry.
.le
.ls long_src [real]
The galactic longitude (LII) of the source.
.le
.ls lat_src [real]
The galactic latitude (BII) of the source.
.le
.ls searchrad [real]
The search radius around the source position from which to include data.
The recommended search radius is 5.0 degrees.  At 5.0 degrees from the
source, the collimator response function becomes so small that very 
little extra data can be collected at a greater radius, and collimator
response corrections will greatly magnify the variance of this data.  Larger
radii also increase the likiehood of including data from a nearby source.
.le
.ls collim [boolean]
Whether or not to apply collimator response corrections.  Correcting the data
is recommended.
.le
.ls spincheck [boolean]
Whether or not to reject data points which have been flagged for irregularities
in the spin period of the Vela 5B satellite.
.le
.ls pointcheck [boolean]
Whether or not to reject data points which have been flagged for errors in
the pointing of the Vela 5B satellite.
.le
.ls backopt [integer]
Which model of the Vela 5B background rates to use in correcting the 
data.  There are three options:
.ls
0  Make no background corrections whatsoever
.le
.ls
1  Use the original linear background model
.le
.ls
2  Use the sinusoidal modeled background
.le
.ls minflux [real]
The minimum flux level to include in the data.  NULL data for the Vela 5B
mission has been recorded as -100.0: we recommend setting the minimum 
acceptable value to -100.0 in include all data (NULL data will not be
included).
.le
.ls maxflux [real]
The maximum flux level to include in the data.
.le
.ls maxerr [real]
The maximum background level to accept in the data.
.le
.ls beginyr [integer]
The calendar year in which to start collecting data.  Vela 5B was launched
in 1969 and stopped operating in 1979; years outside this range will not
be accepted.  You may entry the year in full (e.g. 1969) or just the 
last two trailing digits (e.g. 69).
.le
.ls beginday [integer]
The day of the start year in which to begin accepting data.  The entry should
be the number of days since January 0 (e.g. day 32 = 1 February). Data
from that day will be included. 
.le
.ls endyr [integer]
The calendar year in which to stop including data in the light curve.  
The maximum acceptable value is 80 (or 1980; entering day 1 of 1980 for a
stop date ensures that data is included all the way to the end of the 
Vela 5B mission).
.le
.ls endday [integer]
The day of the stop year in which to cease accepting data. The entry should
be the number of days since January 0 (e.g. day 32 = 1 February).  Data
from that day will be included. 
.le
.ls weight [boolean]
Whether or not to weight the data according to the background levels when
binning the data.
.le
.ls binopt [integer]
Which binning option to use.  Data can be retained in its original 1-s
time resolution with no binning (option 0), binning in 10 day intervals
(option 1), binned so that all data from a source seperated by less than
an hour is binned together (called natural binning, option 2; This works
out to be 56 hrs (half a Vela 5B orbit)), or binning data into 
user-specified size bins (option 3).
.le
.ls timbin [integer]
If binning option 3 was chosen, a bin size must be specified.  The time
width of the bins is specified in seconds.
.le
.ls (imax) [integer]
This is a "hidden" parameter; The user must edit the parameter file to 
set imax.  This is the maximum number of data points that the program will
read in at one time.  The default value of 500,000 is sufficient for 
1-s time resolution light curves covering the entire Vela 5B mission for
virtually any source, so there should not been any need to increase imax.
However, for computers with smaller memory capacities, it may be necessary
to reduce imax if insufficient memory can be allocated. 500,000 elements
requires ~10 Mb of memory.
.le

.ih
BUGS
Version 1.1 and prior may include data flagged for bad background by
the NOS processing.  Some corruption of light curves by a small number
of bad data points will result.

Version 1.0 and prior may fail if given very small ( < 50 time records)
light curves due to problems with small sized dynamically allocated
arrays.

Potentially runs out of memory on smaller systems; see comments on the 
IMAX parameter.

.ih
LOG OF SIGNIFICANT CHANGES
.ls v1.2 (1996 Feb)
   Prior versions failed to correctly reject data flagged on the NOS side of the 
Vela 5B processing: this is corrected with v1.2.  Specifically, when the NOS computer 
found problems with the data, it wrote the SIN and/or COS background
term to be +/- 32.75, the linear term to 327.5, or the linear term
to be less than 0.  All such data points are now rejected.
.le
.ls v1.1 (1995 Dec)
   Minimum size for dynamically allocated arrays to prevent known problem
with the umdget routines.
.le
.ls v1.0 (1995 Aug)
   First release version; channel 0 error in Beta version removed.
Also writes HISTORY keyword entries.
.le
.ls v0.9 (1995 Jan)
   Beta test version, uses IMAX for dynamic memory.
.le

.ih
PRIMARY AUTHOR

.nj
Jesse S. Allen
.br
.nj
Hughes STX
.br
.nj
HEASARC NASA/GFSC
.br
.nj
http://heasarc.gsfc.nasa.gov/cgi-bin/ftoolshelp
.br
.nj
(301) 286-8245
.ju
.endhelp

