This is meant as a beginner's guide to HESSI spectroscopy. It will take you through demonstrations of two ways to analyze solar spectra: producing "semi-calibrated" spectra and removing the instrument response more thoroughly with the SPectral EXecutive (SPEX) package.
First, let's produce a semi-calibrated spectrum using only the Graphical User Interface (GUI) to the HESSI software, and using simulated data. Enter solarsoft and type
You should get a window that looks like this:
We begin by choosing a flare, which is also the first step for imaging, of course. On the command bar at top, pull down "File" and choose
Now let's look at spectra. Back on the main widget (pictured above) use the pull-down menu on the top to select:
This lets us make a lot of choices in how to take our spectra. Let's exercise them a bit. We'll leave the top panel (time interval) alone, since we just chose that with the other window (which is more flexible). The second panel covers energy binning. Generally you want to pick energy bins fine enough to distinguish between the different emission models you want to study, but not so fine that the statistical noise is overwhelming. There are several good default choices, or you can construct your own binning by pressing
The next panel lets us select times. We can create not just a single spectrum but a whole array of them, and when we do full spectroscopy with SPEX (below) we will do so. But for now, let's choose the pulldown menu next to Time Bin Width(s) and set it to 240.000 seconds, so that we have only one time bin.
The next panel lets us select detector segments: front and rear for any or all of the 9 detectors. The document Behind, Beneath and Before HESSI Spectroscopy or "BBB" discusses the detector segments in detail. Basically, the front (F) segments detect most of the hard x-rays up to 100 keV and the rear (R) segments detect most of the gamma-rays above 100 keV. The simulated data have no rear segment events, so we won't bother with those. Instead, let's do something which you'll probably want to do most of the time in real life: remove from consideration the front segment of the detector under Grid 7 (we refer to this detector as "G7" for short). G7 has much poorer energy resolution in its front segment than any of the other detectors (about 3 keV instead of 1 keV FWHM at hard x-ray energies). So hit the button marked
Let's look at the spectrum we're getting by pressing the button on the bottom labeled
This is a count spectrum, meaning it's the spectrum of energies that would be reported by the detector. First, notice that there are no events below 5 keV or above 300 keV. These are artificial cutoffs that are part of the simulation. Real data would have at least a few background counts, if nothing else, in these ranges. Now notice that the spectrum is rising from about 5-15 keV. This is not a characteristic of the Sun; it's due to absorption in passive material in front of the detectors (thermal blankets, beryllium detector windows, and most importantly the aluminum attenuators which are often in front of the detectors -- see the BBB document). From here to about 100 keV the spectrum falls roughly as the true solar spectrum does. Above about 100 keV the spectrum has a shoulder. This is not from the flare, but from simulated background. Usually the background spectrum will be very hard, harder than anything solar (and in real life it would continue on past 300 keV).
The rest of this document will be devoted to converting this count spectrum to a photon spectrum, i.e. what's incident on the spacecraft from the Sun. The simplest thing to do is to divide this spectrum by the efficiency of the system as a function of energy. This will remove the effects of absorption from the materials in front. To do this, simply hit the check box next to "Use Semi-calibrated Data" and hit
The good news is that the instrumental absorption which caused the spectrum to roll over below 15 keV is gone. The bad news is that the background gets exaggerted: instead of just a slight hump, the spectrum now actually seems to RISE above 100 keV. This is just the background again, but it is amplified (artificially) when we convert to a photon spectrum. If we did a detailed spectral fit on this spectrum we'd probably find that hardening due to this background effect is probably contaminating the spectrum all the way down to 50 keV or so. To do the spectral analysis right, we need to subtract the background BEFORE we remove the instrument response. We will do that next.
"Semicalibrated" spectra can be used with caution for science when the following conditions hold: 1) only the front segments are used, 2) the flare spectrum is at least ten times the background spectrum for all the energies being examined, and 3) only energies below about 75 keV (50 keV to be conservative) are being examined. Above 75 keV, the redistribution of photons to lower energies by Compton scattering becomes more and more significant.
Now let's do a real spectral analysis using SPEX. First we'll make some files for SPEX to use. Let's go back and click again on the box next to "Use Semi-calibrated Data" so that the check disappears. Then go back to the time panel and pick a Time Bin Width of 5.000 sec. Now hit
Now we can save a file for SPEX to use. It will contain a time series of spectra, one for each of 52 time bins, with 199 energy bins in each spectrum. We will also ask the GUI to create and save a second file, containing the response of the instrument. Click on the
Each line of the SRM gives the total response of the instrument to photons of a particular energy. The diagonal terms of this matrix represent the total system efficiency for recognizing a photon energy directly. Off-axis elements represent the probability that photons are redistributed to another (generally lower) energy. For hard x-rays, more photons are recorded with their true energy than with a lower energy, but above 100 keV this is reversed. This is why the "semicalibrated" procedure, which simply takes the diagonal elements of the response and divides the count spectrum by them to get a photon spectrum, is inaccurate above 50-100 keV or so, even without considering the issue of background.
Now go ahead and click
Now let's start SPEX, which is its own command environment within IDL/Solarsoft, by typing
Now let's create the background spectrum by telling SPEX to accumulate it during intervals before and after the flare when there is nothing going on. This won't always be possible, but when such intervals exist within 10 minutes or so of the flare it's usually the best way to get an accurate background measurement. SPEX can fit a polynomial background model of order N for each energy bin given at least N background time intervals. For this case a constant background (order zero) will do. To get it, we type:
then move the cursor back to the pop-up window and hit
Now select one or more data intervals for which to analyze the spectra. Each of these intervals should of course be exclusive of your background periods. Type on the command line:
Now SPEX has a background model, an instrument response, and a set of two times in which to accumulate spectra. All that's left to do is define a model and fit to it. We'll do the simplest model, a power law: