How to extract background spectra from blank fields event lists

Introduction

EPIC background spectra are normally extracted from regions of the observation field-of-view once contamination due to individual discrete celestial sources has been removed. This technique is fully appropriate when analyzing spectra of point-like sources in full window mode. However, there are cases where the determination of the background from the same observation is difficult due to the intrinsic extended nature of the celestial object of interest, or because a bright source was observed using a partial window mode. It is sometimes impossible to identify field-of-view regions where the target source does not substantially contribute to the total X-ray counts. It is recommended to have a look at the XMM-EPIC Status of EPIC Calibration and Data Analysis where the most up-to-date instrument behaviour is characterized, so it will help for the selection of source and background extraction regions for spectral analysis.

In order to cope with this situation, blank sky event lists are available through the XMM-Newton Science Operations Centre web site from the EPIC Background Analysis web pages. This thread briefly explains how to make use of these event files to create background spectra.

Expected Outcome

The expected outcome of this thread is a background spectrum file generated from a blank sky event list to be used for the spectral analysis of an extended diffuse source, or for those cases of a bright source observed using a partial window mode.

SAS Tasks to be Used

Prerequisites

Before starting this thread, a blank sky event list should be obtained. The creation of individually tailored blank sky files has been discontinued as of September 2013. You may still find existing generic blank field event lists and event lists for a certain combination of sky coordinates, Galactic column density and instrumental configurations. Go to the XMM-Newton EPIC 'Blank Sky' Background Web Page for information on how to obtain one of these files.

Useful Links

 

Caveats

Last Reviewed: 18 April 2018, for SAS v17.0

Last Updated: 23 October 2014

 


 

Procedure

 

  1. Set up your SAS environment (see Prerequisites for this thread at the top of the page).
     
  2. Create an EPIC cleaned and filtered for particle background event file for your observation (see Prerequisites for this thread at the top of the page). Let the name of the filtered file be: EPICclean.fits.
     
  3. Extract an image of the observation in detector coordinates:

      evselect table=EPICclean.fits imagebinning=binSize imageset=EPICimage.fits withimageset=yes \
        xcolumn=DETX ycolumn=DETY ximagebinsize=80 yimagebinsize=80

     
  4. Display the image:

      imgdisplay withimagefile=true imagefile=EPICimage.fits
     
  5. Identify the center coordinates and radius of the source spectrum extraction region. Let's assume that they are:

      DETX(center) = 100
      DETY(center) = -100
      Radius = 6000

     

  6. Extract the source spectrum from the identified region:

    For MOS:
      evselect table=EPICclean.fits \
        withspectrumset=yes spectrumset=EPICsource_spectrum.fits \
        energycolumn=PI spectralbinsize=5 withspecranges=yes specchannelmin=0 specchannelmax=11999 \
        expression='((DETX,DETY) IN circle(100,-100,6000))'


    For pn:
      evselect table=EPICclean.fits \
        withspectrumset=yes spectrumset=EPICsource_spectrum.fits \
        energycolumn=PI spectralbinsize=5 withspecranges=yes specchannelmin=0 specchannelmax=20479 \
        expression='((DETX,DETY) IN circle(100,-100,6000))'

     
  7. Let the name of the blank sky event list be (see Prerequisites for this thread at the top of the page on how to obtain one of these files): blank_sky_event_lists.ds
     
  8. Add the keyword DATE-OBS to the primary and events extension of the blank sky event file, for example utilising the FITS file editor fv and adding the date value of the observation event file (see the watchout notes of the blank sky web pages).

    These keywords can also be added to the blank sky event file using FTOOLS commands, for example:

      fparkey '2004-07-12T12:30:00.0' blank_sky_event_lists.ds+0 DATE-OBS add=yes
      fparkey '2004-07-12T12:30:00.0' blank_sky_event_lists.ds+1 DATE-OBS add=yes
     
  9. The blank sky event lists have been very conservatively filtered, to allow leverage for a user to further filter the data to the level that they desire. Therefore, it is strongly suggested that a user filters their blank sky event list to a level suitable for their observation and analysis using the same criteria applied for the generation of the source spectrum (see Prerequisites for this thread at the top of the page for filtering event files). Let the name of the filtered blank sky event file be: blank_sky_event_lists_clean.ds
     
  10. Perform the same operation as for the source extraction region and extract the background spectrum from the same region in detector coordinates as the source, using the same event selection expression:

    For MOS:
      evselect table=blank_sky_event_lists_clean.ds \
        withspectrumset=yes spectrumset=background_spectrum.fits \
        energycolumn=PI spectralbinsize=5 withspecranges=yes specchannelmin=0 specchannelmax=11999 \
        expression='((DETX,DETY) IN circle(100,-100,6000))'


    For pn:
      evselect table=blank_sky_event_lists_clean.ds \
        withspectrumset=yes spectrumset=background_spectrum.fits \
        energycolumn=PI spectralbinsize=5 withspecranges=yes specchannelmin=0 specchannelmax=20479 \
        expression='((DETX,DETY) IN circle(100,-100,6000))'

     
  11. From this point onwards, with the source and background spectral files, follow the thread for EPIC spectrum extraction to generate a redistribution matrix, an ancillary file and to calculate the area of source and background region (BACKSCALE) used to make the spectral files (see Prerequisites for this thread at the top of the page and the watchout notes of the blank sky background web pages). Please, note that the threads for EPIC spectrum extraction is focused on the analysis of point-like sources. In particular, the call to the SAS task arfgen to generate the ancillary file for extended sources, requires the use of the parameter extendedsource=yes. It is also advised that the call to arfgen includes an externally-created detector map which is more suitable for the analysis of extended sources (see for more details the documentation for arfgen).

It is also possible to extract a background spectrum from the blank sky event lists using a spectral extraction region defined in sky coordinates. In this case, one needs to recast the blank sky event list to mimic the nominal pointing direction of the observer's field, using, for instance, the SAS task attcalc:

  attcalc eventset=blank_sky_event_lists.ds attitudelabel=fixed withatthkset=N \
   refpointlabel=user nominalra=... nominaldec=...


where nominalra and nominaldec are the celestial coordinates of the central reference point which can be user defined by setting refpointlabl to user. For the case where the blank sky background field is matched to the source observation field, these values should be RA_NOM, DEC_NOM as they appear in the header of the source observation event file, which correspond to the boresight RA/Dec values of the prime instrument (i.e. the proposed pointing).


 

Caveats

 

  • This thread deals only with the blank sky data sets. There are other background tools and files available. For example, the particle background component is time variable and therefore one could imagine the scenario where a particular blank sky file does not have enough particle background included in it. A user may wish to understand more fully the various components that contribute to make up the XMM-Newton background by reading the relevant sections on the XMM-Newton EPIC Background Analysis Web Pages.

  • To scale the blank sky exposure maps (delivered with a blank sky event list) to a particular energy band of choice, please see the XMM-Newton EPIC 'Blank Sky' Background Web Page Threads section for more details.