powspec_guide
guide to powspec

   
At a UNIX prompt, type powspec

if in xselect, type $ to temporarily leave xselect (type exit to return to xselect)

the powspec routine operates on files with either an extension .lc or extension .flc  (.flc files are created by the lcurve routine which operaties on .lc files) that are located in the same directory;
the powspec routine outputs a .fps file on which the fdump routine operates

The information within brackets [] is either the default value or the last value selected.
Pressing <Enter> without typing anything automatically selects this value.

extracting a power spectrum

input command/response description of
input command/response


software response
to input
information returned after  execution of input command/response
and before software response
Type powspec
Opens the power spectrum routine
Ser. 1 filename +options (or @file of filenames +options) [ ]

filename.lc


or
@filename.txt
if finding the power spectrum of a single light curve

if finding the power spectrum of a concatenated set of files;
see below
Name of the window file ('-'
for default window).
Displays information about the *.lc file, e.g., source name, coordinates, start/stop time, bin time, etc.
Type -
Tells xselect what window file you want to use.
Newbin Time or negative
rebinning [3.241]
Displays Minimum Newbin Time(s);
this should match time resolution

Displays Default Newbin Time
(which must be an integer multiple of the Minimum Newbin Time); Default Newbin Time chosen so that number of bins is close to an integer power of 2 (helpful for Fourier transform process)
3.2410400 A bin is an interval of time over which the data is lumped together for analysis.

Select the Minimum Newbin Time to match the time resolution ("timedel" in fits header for image) of the data.  It is commonly used unless there are too few photons in this bin size. 

The Newbin Time entered MUST be an integral multiple of the Minimum Newbin Time.In general, enter the default value
Number of Newbins/Interval [14433] Confirms the Newbin Time entered.
Displays number of Newbins covering the exposure time interval.
14433
The prompt is asking how many bins you want the complete data set broken into.

Select Maximum Newbin No. in order to see the entire observation.  In general,  enter the default value
Number of Intervals/Frame [1] Confirms number of Newbins and Newbin TIme interval.
1
A frame is the average of the results of analysis of several intervals. 1 provides a sum of the data, whereas a number N averages N number of files in the data set.

Tells powspec that all data should be collected in one inteval of time
Rebin results?
Confirms that all data will be collected in 1 interval.
0
Rebins results into different time segments.  Default is 0.

(allows another opportunity for rebinning?)
Name of output file?
[powspec_objectname]

suggest using obsid
Saves power spectrum results in an output .fps file which can then be manipulated by the fdump routine.

The default option saves the power spectrum with a filename identical to that used for the input file (either a .lc or a   ) but ending with the .fps extension.
Do you want to plot your results? [yes] power spectrum file has .fps extension
yes
plots power spectrum
Enter PGPLOT device
[/xw]

/xw Selects device used for drawing the graph on screen.  Most commonly this is /xw or sometimes /xterm Power Spectrum Ready!

Under the PLT> type hardcopy
Saves the power spectrum file and closes the window


Type exit
Exits PLT> and returns to either UNIX or xselect prompt



concatenating files for use in powspec


Run lcurve on each data set separately to obtain a .flc file for each

List all .flc files, one per line, in a text file, e.g.,  powcat.txt
i.e.,

filename1.flc
filename2,flc
etc.

Run the powspec routine, but respond when prompted for the filename with
@powcat.txt

when prompted for the number of intervals per frame:

    choose 1 if you want a concatenation of the data by adding (this is best)

    choose N (= number of files in the concatenated list) if  you want to concatenate by averaging