\section{Hard X-Ray Telescope (HXT)}

\subsection{Routines for Making Time Plots}
\subsubsection{PLOTT\_HDA }

PLOTT\_HDA will make a light curve plot of all four channels using either the index or
roadmap.  The second `T' signifies that it is a time plotting routine.
Four plots are made on the page, one for each channel.  Some sample calls are:
%
\idlinputa{plott\_hda, index}	\index{PLOTT\_HDA}
\idlinputb{plott\_hda, roadmap}	
\idlinputc{plott\_hda, roadmap(100:200), psym=10} 
%
\subsection{Routines for 2-D Spectral Display}
\subsubsection{DISP\_HDA  }

The evolution of  sensor intensity against  time  can  be  displayed as a pseudo-image
using the routine DISP\_HDA.  Note:  The time axis of DISP\_HDA is not uniform.
%
\idlinputd{disp\_hda, index, data}\index{DISP\_HDA} 
%
\subsection{Routines for Data and Information Extraction}
%%\subsubsection{GT\_SUM\_L, GT\_SUM\_M1, GT\_SUM\_M2, GT\_SUM\_H}
\subsubsection{GT\_SUM\_L}

These routines will extract the average counts/sec of all 64 sensors.  
The input can be roadmap, index, or observing log and it will
get the proper structure tag and decompress it properly to 
return counts/sec/sensor.
It is possible to get a string defining the
channel selected by using the {\it title} keyword option.
%
\idlinputa{y = gt\_sum\_l(roadmap)}	\index{GT\_SUM\_L}\index{GT\_SUM\_M1}\index{GT\_SUM\_M2}\index{GT\_SUM\_H}
\idlinputc{y = gt\_sum\_l(w\_h, title=title)} 
%
\subsubsection{GET\_INFO}

See the description in the ``General Yohkoh Software'' chapter on
page~\pageref{get_info}.

\subsection{Routines for Calibration and Analysis}

\subsubsection{HXT\_QLOOK}
\index{quick look, HXT images}
\index{synthesizing HXT images}
\index{image synthesis}
\index{HXT images}


HXT\_QLOOK makes a series of HXT quick-look images (i.e. a quick-look movie).
This program is much faster than the MEM code, but should be used only
for quick-look movies.  It is very useful for verifying positions etc. before
running a long MEM job.
%
\idlinputa{hxt\_qlook, index, data, movie, hxi\_index}\index{HXT\_QLOOK}
\idlinputb{hxt\_qlook, index, data, movie, hxi\_index, patterns}

\vspace{0.2in}\begin{tabular}{lp{15.0cm}}
     index & {\raggedright HXT index from an HDA file}\\
     data & {\raggedright   HXT data from an HDA file}\\
     patterns & {\raggedright the sub-collimator modulation patterns.  Computed if not\\
                supplied.  The computation is slow, so if you plan to make\\
                a series of movies, use patterns to receive the computed \\
                patterns the first time you call HXT\_QLOOK and then use\\
                patterns to pass the modulation patterns back to the routine\\
                on subsequent calls to HXT\_QLOOK.  You must recompute the \\
                modulation patterns whenever you use a different pointing.}\\

     movie & {\raggedright  a data cube of the HXT images (output)}\\
     hxi\_index & {\raggedright  an index describing various parameters of the images.  The\\
                 time in the index is the start of the accumulation period\\
                 (output).}\\

     /new\_mod\_patterns & {\raggedright  Force a new computation of the modulation patterns,\\
                         even if the patterns parameter is set.  Normally, if\\
                         patterns is set, the modulation patterns are not\\
                         computed.  You must recompute the modulation \\
                         patterns whenever you use a different pointing.}\\
     /show\_images & {\raggedright  show each image as it is computed}\\
     /quiet & {\raggedright  don't print any diagnostics}\\
     /verbose & {\raggedright  print lots of diagnostics}\\
     smooth & {\raggedright  smoothing parameter which determines how much the inverse \\
              computation of the image is smoothed.  Default = 0.1.}\\
\end{tabular}

\subsubsection{HXTPRO}\index{HXTPRO}

See the User's Guide for a description of this program.

\subsubsection{HXT\_IMG}\index{HXT\_IMG}

See the User's Guide for a description of this program.

\subsubsection{GET\_HXT\_POS}
\index{HXT flare location}
\index{flare location, HXT}

The routine GET\_HXT\_POS will return the HXT address of the flare location.
It will perform the following checks in this order
until it finds a match.

\EEnumerate
\item Read the \$DIR\_HXT\_CAL/hxt\_flare\_pos.txt file to see if the time is in that list
\item Use the GOES heliocentric location to determine the address
\item Use an SXT image index to define the address
\item Pass in heliocentric coordinates and convert them
\item Ask for user to specify HXT address directly
\end{enumerate}

Sample calls are:
%
\idlinputa{xy0 = get\_hxt\_pos('15-Nov-91 22:37')} \index{GET\_HXT\_POS}
\idlinputb{xy0 = get\_hxt\_pos(index(20), helio='N32W23')}
\idlinputb{xy0 = get\_hxt\_pos(index(20), status=status)}
%
The optional keywords {\it /get\_sxt, /get\_goes} and {\it helio} will
force the calculation of the function to use that technique.  The
keyword option {\it /nouser} should be used when running in batch mode as it
will inhibit asking the user for input.  The {\it status} output is
a $-1$ if no match has been found, 1 for HXT flare list, 2 for SXT image,
3 for GOES event list, 4 for heliocentric coordinate passed in, and
5 for user input.

\subsubsection{HXT\_FSP and HXTBOX\_FSP [*]} \index{spectral fitting}
\index{spectral fitting, HXT}

HXT\_FSP is the same as HXS\_FSP, but for HXT spectra.  See HXS\_FSP for a
better description.   Index and data come from an hda file.
%
\idlinputa{HXT\_FSP, index, data, fit\_pars} \index{HXT\_FSP}
%
HXTBOX\_FSP fits spectra to a given box, chosen by LCUR\_IMAGE, for a set of 
HXT images in the HXI structure; index and data come from and hxi file 
of deconvolved images.
%
\idlinputa{HXTBOX\_FSP, index, data, fit\_pars}   \index{HXTBOX\_FSP}
%
\subsubsection{SXTHXT\_FSP and SXTHXTBOX\_FSP[*]} \index{spectral fitting}

SXTHXT\_FSP fits combination SXT and HXT spectra, no spatial resolution! $index$ and 
$data$ are uncompressed SXT images, $hindex$ and $hdata$ are uncompressed HXT data, from 
an HDA file.
%
\idlinputa{SXTHXT\_FSP, index, data, hindex, hdata, fit\_pars} \index{SXTHXT\_FSP}
%
SXTHXTBOX\_FSP fits SXT-HXT spectra for a box chosen using LCUR\_IMAGE.  $hindex$ must be 
the HXI structure, and $hdata$ are HXT images. You should be sure of alignment 
beforehand.
%
\idlinputd{SXTHXTBOX\_FSP, index, data, hindex, hdata, fit\_pars} \index{SXTHXTBOX\_FSP}
%
\subsubsection{HXT\_DECOMP}

HXT\_DECOMP will decompress the HXT data.  A sample call is
%
\idlinputd{odata = hxt\_decomp(data)}\index{HXT\_DECOMP}
