Spectral fitting
Overview
At this website it is possible to model X-ray spectra of a large subset of XMM-Newton detections for which SAS based pipeline has extracted necessary data products. For the 4XMM-DR11 catalog, out of 895 415 detections 319 565 (or 35.7%) have spectra. Note that they were extracted in an automated regime so in complex cases such as highly variable / diffuse background, aperture centering and background extraction algorithms work imperfectly. In other words, these spectra and present spectral analysis tool are provided for quick-look purposes only.
If you want to try the spectral fitting but are not sure which source to take, just type has_spectrum = true in the search field at the top and pick any item from the list of results. Then click any of the Fit spectrum links in the table at the bottom of the page.
Data
The XMM-Newton pipeline produces the following spectral data products for sources which are used at the core of the spectral fitting functionality:
SRSPEC — EPIC source spectrum.
- A source spectrum is generated for each EPIC source which is found to be sufficiently bright to yield a useful spectrum. Spectra are considered for extraction for point sources in the EPIC field where the EPIC band-8 count rate is > 100 cts/s — where the detection comes from only one or two of the cameras, this initial filtering is by equivalent EPIC counts, which are derived adopting a PN to MOS count ratio of 3.5:1. Spectra are subsequently delivered where the extracted spectrum has > 100 "good" (in XSPEC terminology) counts.
- A source spectrum is accumulated by use of a spatial filter (a circular aperture whose radius is determined by a S/N optimisation algorithm) on valid events in an exposure from CCDs operating in IMAGING mode.
- Currently the extraction aperture is of fixed (28") radius for all sources.
- For each candidate source a spectrum is produced for each EPIC camera (2 MOS and 1 pn), where available.
- No systematic error is included in the spectrum file. The statistical error is defined by Poisson errors on the counts in the channel.
BGSPEC — EPIC background spectrum.
- It is generated for each detected EPIC source for which a source spectrum is generated.
- The background spectrum is generated by accumulation of detected events from a source- free region of the field-of-view (contaminating source regions having been masked out in the process).
- For each candidate source a background spectrum is produced for each EPIC camera (2 MOS and 1 pn) where available.
- No systematic error is included in the spectrum file. The statistical error is defined by Poisson errors on the counts in the channel.
- The data are stored as counts, not count rate.
SRCARF — ancillary response function file.
- This is the file providing the effective area of the instrument as a function of energy (channel).
- A file is produced for each source and exposure for which spectral products have been extracted and is for use with those spectral products.
The fitting application uses most recent version of canned response matrices.
More details on these and other science ready data products from the XMM-Newton are available in the Specifications for individual SSC data products document.
Please note that SRSPEC, BGSPEC, SRCARF data products are available for direct download from this website for further analysis in any OGIP-compatible software package such as XSPEC, Sherpa or ISIS. To find direct download links one needs to fetch exported detections table in FITS, VOTable or CSV formats from any query results and check columns url_data_spectrum_PN, url_data_bckgrnd_PN, url_data_arf_PN (replace 'PN' to 'M1' or 'M2' in column names if you are interested in MOS data).
Software
Under the hood the spectral fitting engine uses PyXSPEC, the Python interface to XSPEC (part of HEASoft). XSPEC is the standard X-ray spectral fitting package maintained by NASA/GSFC. All spectral models available in XSPEC can in principle be made available here — if you miss a specific model from the XSPEC model library, let us know and we will add it.
Spectral fitting interface
Instrument — selection of spectrum for particular source coming from any of the three EPIC detectors: PN, M1, M2. If a particular selection is disabled, it means that source spectrum from this instrument has not been produced as it does not meet spectral extraction criteria (see above). Default value: whichever instrument available first in the order PN, M1, M2.
Energy range min and Energy range max — minimum and maximum energy of the spectral range to consider, in keV. Equivalent of XSPEC's ignore command. Default value: 0.2 to 10 keV range.
Group counts — regroup the spectrum to a minimum number of counts per bin using the HEASoft
ftgroupphatool. Set to 0 to keep the pipeline default grouping (recommended). Any positive value overrides the pipeline grouping. Default value: 0 (pipeline default).Optimization — method for finding a minimum of the statistics function, see XSPEC documentation. Presently Levenberg-Marquardt (leven) and Simplex (simplex) local optimization methods are supported. Default value: leven.
Statistics — statistics function. Presently χ² statistic with variance computed from data amplitudes (chi), χ² with Churazov weighting (chi churazov), and χ² with the Gehrels variance function (chi gehrels) are supported. See details in the XSPEC documentation. Default value: chi.
Model — model function. Presently a predefined set of frequently used simple models is supported. Model names in the dropdown list are abbreviated XSPEC model expressions, for example phabs_pl corresponds to
phabs*powerlaw, phabs_pl_nsatm isphabs*(powerlaw+nsatmos), etc. Detailed model descriptions are available from the XSPEC model documentation. Default value: phabs_pl.
Model parameters options
value — initial value for each model parameter. Default value: as defined in the XSPEC model, or at the best fit values if this source spectrum has already been fit by other users.
min — hard minimum limit for the interval where to look for optimal parameter value, in XSPEC model units. Default value: as defined in the XSPEC model.
max — hard maximum limit for the interval where to look for optimal parameter value, in XSPEC model units. Default value: as defined in the XSPEC model.
freeze — check this box to freeze the parameter at its initial value during the fit. Uncheck the box to thaw. Default value: as defined in the XSPEC model.
If the fit is successful, the X-ray spectrum plot is updated with the fitted model and residuals (in units of sigma). The text output shows the fit statistic, reduced χ², model parameters at their best-fit values, and the total model energy flux within the specified energy range.