Home
User manual
Contents
1. Comment The last step in this example will be to make a plot of the fit residuals Therefore is entered Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 55 oF 131 SPEX Version 1 00 SPEX plot menu Select a new plot type Do the plot Set plotting device Set plot file name PostScript print landscape mode PostScript print portrait mode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear Redefine x axis units Redefine y axis units Modify x axis range Modify y axis range Change font type Change font height Modify caption texts Change plot symbols Histogram continuous line plot mode Change line weights Change line styles Change plot colours Back to main menu SPEX Version 1 00 Select the plot type Select a plasma component for plotting bserved spectrum amp predicted model Model photon spectrum Effective area of the detector Response matrix Fit residuals Plasma model Continuum and line emission components Back to main menu Enter your choice DATA chi2 Comment is entered to change the plot type to fit residuals Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 56 oF 131 SPEX Version 1 00 SPEX plot menu Select a new plot type Do the plot Set plotting devi
2. Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 103 oF 131 Modify the font type for the x axis label only See options at Modify the font type for the y axis label only See options at UTIT Modify the font type for the upper title label only See options at LTIT Modify the font type for the lower title label only See options at Modify the font type for the identification label only See options at Change font height Default at program startup 1s 1 for all character strings The font height may be chosen within the range from 0 invisible to 1000 extremely large ALL tu o v UTIT LTIT ID DATA Modify the font size for all character strings Modify the font size for the box annotation only Modify the font size for the x axis label only Modify the font size for the y axis label only Modify the font size for the upper title label only Modify the font size for the lower title label only Modify the font size for the identification label only Modify the font size for the data symbols only Modify caption texts The caption texts may be modified using the pgplot escape sequences These are character sequences that are not plotted but are interpreted as instructions to change the font draw superscripts or subscripts draw non ASCII characters Greek letters etc All escape sequences start with a
3. 2239 2270 2943 2286 2 9944 2281 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 105 oF 131 Displayed pgplot escape sequence f x x cos 272x fif x x u2 d frcos fi fr2 fi gpx Ho 75 25 km s7 Mpc fik dO u fr 75 N 2233 25 km s u 1 d Mpc u 1 d L L 5 6 A1216A fsL L fr d 2281 u 5 6 gl1216 A Figure 3 6 Some examples of the use of pgplot escape sequences Modify the upper title label Modify the lower title label Modify the identification label Change plot symbols So not plot any symbol BAR Single error bar Two crossed error bars Single error bar with plot symbol Default at program startup 1s 17 Plot symbols may be chosen within the range from 8 to 31 see fig 3 7 Two crossed error bars with plot symbol Plot symbol only Default at program startup 1s 17 Plot symbols may be chosen within the range from 8 to 31 see fig 3 7 Histogram continuous line plot mode This menu option provides the possibilty to switch between histogram or continuous line plot mode CRO DATA modify the plot mode for the data modify the plot mode for all model components modify the plot mode for a single model component These are the components of the plot model not the spectral model components Select component Ranging from 01 to 32 SRON SPEX UsER s TUTORIAL MANUAL Do
4. Author F van der Wolf Purpose This is a log file for the example SPEX session in doc SRON SPEX TRUM A spectral model CIE ABSM will be defined and fitted on a simulated spectrum of II Peg based on the ASCA SIS instrument HHHHHHHHHHHHHHHHHHHHHR RRR R RE ERE RRR ERE RETENIR E IE E RRR RR RR RRR RE Define the distance of the source at 29 4 pc disu PC dist DIST 29 4 Set the energy limits for the flux calculations elim LOW 2 elim UPP 12 Read the energy grid from the response matrix iipeg3a res gdat NAME iipeg3a gdat READ Read the previously simulated spectrum of II Peg read RNAM iipeg3a read SNAM iipeg3a read READ dat SHOW Define an additiYe model component Collisional Equilibrium component CIE moda CIE Define a multiplicative model component Absorption component Morrison amp McCammon ABSM modb ABSM Set the relation betueen the additive and multiplicative component to 1 Document SRON SPEX Date Issue UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION SRON SPEX TRUM April 24 1995 Version 1 06 PAGE 61 OF 131 mode SAME 1 Show the spectral model mod SHOW Modify the spectral model parameters for the CIE component additive par COMP comp A01 Set Normalisation to 1E 5 i e 10E59 m 3 par PARA scie NORM par VAL 1 E 05 Set Electron Temperature to 3 keV
5. SPEX Dae Ur Apri 24 1008 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX Loa FILE STRUCTURE PaGE 132 oF 131
6. 3 SPEX Menu Structure 3 1 3 2 3 3 3 4 3 5 3 6 3 7 Introduction oaa s n Program control 222 2l ll Rs s or Source parameters amp instrumental settings ooa ea a e Spectral model aoaaa rs Evaluation 2222s e RR o o ro Simulation 2 22 2l ll o o o Fitting lle ee e RR RR o s rs Oo 0 oo 1 D Cc Qt 11 11 12 12 12 17 22 27 37 40 50 59 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL PAGE 3 or 131 3 8 Plots amp ASCH files 2 2l S Rs o s ss 4 SPEX Models 4 1 Introduction 222 ls s on 4 2 Spectral model parameters 2 0 e 4 3 Cookbook examples 2 aaa e 5 Instrumental Response Files amp Spectral Simulations 5 1 Introduction 222222 0 00002 Ro ros 5 2 Instruments 4 4 e eee mo e S os 5 3 Spectral simulations 22e ll s rs 6 SPEX File Formats 6 1 Introduction 4 2 e eS m s eos 6 2 Spectral data files 2l rs 6 2 1 Writing spectral data in binary format spo een 6 2 2 Writing spectral data in ASCII format spa leen 6 3 Response Matrices 22 lle Rs rs 6 3 1 Writing response matrices in binary format res sls 6 3 3 Writing response matrices in ASCII format ras less 6 3 3 Useful software 2 6 4 Energy grids egr eR s 6 5 DEM files dem RR n 6 6 Other files 2 eR Rs ee 6 6 1 Log files com ee
7. 6 3 1 Remember to write the data in the right sequence e NKRESP integer 4 the total number of response groups and NRESP integer 4 the total number of non zero response elements Both quantities should appear on the same line A response group 1s a continuous sequence of output channels for which the response matrix 1s positive at a given input energy e NKRESP response groups containing the following information for group I First line KRESP 1 1 KRESP 2 1 KRESP 3 1 followed by REsP for the KRESP 1 1 elements of the specific group When SPEX writes an ASCII response matrix per line 5 data fields will be written This is however not mandatory for the input of an ASCII response matrix e NDETEDG integer 4 the number of edges in the effective area of the instruments Only if NDETEDG gt 0 then follows e lines containing EDETEDG I where I ranges from 1 to NDETEDG When SPEX writes an ASCII response matrix per line 5 data fields will be written This is however not mandatory for the input of an ASCII response matrix An example Fortran routine to write ASCII response matrices 1s presented in Fig 6 4 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 123 or 131 integer 4 nbmax nemax ncmax nrespmax ndetedgmax parameter nbmax 2048 nemax 8192 ncmax 32768 nrespmax 524288 ndetedgmax 64 integer 4 nchan neg real 4 echani nb
8. 6 6 2 Output files out lS e 6 6 3 ASCII output files asc from plasma model components 6 6 4 PostScript files 2 20 200 00200000 00 rs 6 6 5 Scratch files aaa a 7 SPEX Log File Structure amp Usage 7 1 Introduction aaa a 7 2 Log File Structure aaa aaa eos 111 111 113 113 114 114 114 115 116 116 116 116 117 118 119 120 124 124 124 126 126 126 126 126 126 127 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL PAGE 4 or 131 7 3 7 4 7 2 1 Commandlines 2 0 0 0 0 a 127 1 2 2 Comment lines 2 ooa a 128 Creating Log Files 0 2 a 128 7 3 1 SPEX session recording s 129 7 3 2 Manual composition aoaaa aa sors 129 7 3 3 Nesting of Log Files 4 129 Using Log Files a 130 7 4 1 Error handling 130 A References 131 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL INTRODUCTION PAGE 5 or 131 Chapter 1 Introduction 1 1 What is SPEX The advent of a new series of X ray satellites with high sensitivity and spectral resolution such as EUVE ASCA SAX AXAF and XMM strongly demands the availability of spectral codes with higher accuracy and more detail than has been available The menu driven SP Ectral X amp UV analysis software package SPEX has been developed at the Space Research Organization Netherlands SRO
9. Description Select the spectral component Select the parameter for the current component new value of the parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu Enter your choice PARA Comment This multiplicative component only has one parameter the column density SPEX Version 1 00 Select a spectral parameter absorption M amp M sabs Description Enter your choice NH Comment is entered to select the hydrogen column density Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 36 OF 131 SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the parameter for the current component Set new value of the parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu Enter your choice VAL mul comp 1 absm Column 1E28 m 2 type 2 1 E 04 5e 6 Comment This multiplicative component only has one parameter the column density Therefore can be selected without selecting the parameter first The new value is set at 5 107 m by ente
10. See Tab 3 10 Modify the line colour for the lower title label only See Tab 3 10 Modify the line colour for the identification label only See Tab 3 10 Modify the line colour for the data only See Tab 3 10 SRON SPEX Dae Ur Apri 24 1008 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 110 oF 131 Modify the line colour for all model components See Tab 3 10 Modify the line colour for a single model component See Tab 3 10 Switch between gray scale or contour plot This option is only available in 2D plot mode e g RESP Change number of contour levels This option is only available in 2D plot mode e g RESP CLEV Change contour levels SPEX asks for the component number and it s new value This option is only available in 2D plot mode e g RESP Back to main menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MODELS PAGE 111 oF 131 Chapter 4 SPEX Models 4 1 Introduction The SPEX software encompasses a number of subroutines for the computation of emergent spectra based on a variety of plasma models such as optically thin plasmas in collisional ionization equilibrium CIE e g stellar coronal loop structures Another category of optically thin plasmas are supernova remnants which show extreme transient ionization effects for which the non equilibrium ionization NEI plasma model must be applied
11. comment lines start with an as the first character of a new line and should be no longer than 256 characters or to add or delete commands IF Unless the file name is changed SPEX will use the default file name at program startup spex or the last defined filename NAME Change file name for saving your commands without com Open the file for saving your commands Close the file for saving your commands Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 66 OF 131 QUIT Exit from SPEX HIDE Hide show menu listings for experienced user only Program control LOG Save or read log files for commands and output DIST Set the source distance Source parameters amp GRID Select default energy grid ELIM Set energy limits for flux calculations instrumental settings VAR Define default abundances and line properties etc DATA Read write show or modify data MOD Modify the spectral model PAR Modify the current model parameters Spectral model CALC Evaluate the current spectral model Evaluation SIM Simulate a spectrum using current model amp detector Simulation FIT Fit the parameters using current data amp model uu DEM Differential emission measure analysis DEM Fitting ASC Output of SPEX model properties to file or screen PLOT Plot menu Plots amp ASCII files Figure 3 2 SPEX main menu divi
12. echan2 nbmax eg1 nemax eg2 nemax integer 2 kresp 3 ncmax real 4 resp nrespmax edetedg ndetedgmax real 4 r nemax nbmax rlim parameter rlim do ie rprev do ic 1 nchan if r ic ie gt rlim then nresp nresp 1 resp nresp r ic ie if rprev le rlim then k k 1 kresp 1 k 0 kresp 2 k ie kresp 3 k ic endif kresp 1 k kresp 1 k 1 endif rprev r ic ie enddo enddo nkresp k end Figure 6 5 Example Fortran program to convert a square SPEX matrix into a compressed form Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 126 or 131 Note SPEX interpolates the DEM on a previously defined temperature grid when setting the parameters of the DEM component For a capricious DEM e g with narrow peaks inaccuracies might occur Perhaps a newer version of SPEX can first integrate over the final DEM bin and then take the mean 6 6 Other files 6 6 1 Log files com SPEX provides options to record and play back SPEX commands using so called log files A log file is a series of previously recorded SPEX commands that can be executed by SPEX again To learn more about the log file structure see chapter 7 6 6 2 Output files out Various types of output from SPEX may be stored into a file e g runtime output data model and parameter information etc To learn more about the possibilities
13. obs spectrum Modify the spectral model Modify the current model parameters Evaluate the current spectral model Simulate a spectrum using current model amp detector Spectral fitting error search etc Differential Emission Measure analysis DEM Output of SPEX model properties to ascii file or screen Plot menu Figure 3 1 SPEX main menu terminal mode once all necessary parameters are loaded into the program Figure 3 3 shows the structure in which all menu options are displayed The main menu consists of two options M1 and M2 Main menu option M1 the default at program startup is titled and has two sub menu options S1 and S2 default Submenu option 81 titled represents a new sub sub menu with two options S11 default titled ssm1 and 12 titled ssm2 The sub sub sub menu options of 1 and 2 are called s111 s112 and 121 122 respectively All Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 65 oF 131 menu titles and item names are listed in the index at the end of this manual These index entries may be used for quick references when new log files are to be created or when old log files must be understood Besides the default menu options at program startup the menu structure also shows the default settings at program startup for certain parameters or file names 3 2 Program control The main menu
14. par PARA scie T par VAL 3 Set Ion Temperature to 1 keV par PARA scie IT par VAL 1 Set Electron density to 1E 4 i e 10E16 m 3 par PARA scie ED par VAl 1 E 04 Set Micro turbulence velocity to 0 km s par PARA scie VMIC par VAL E 00 Modify the spectral model parameters for the ABSM component multiplicative par COMP comp MO1 Document SRON SPEX Date Issue UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION SRON SPEX TRUM April 24 1995 Version 1 06 PAGE 62 OF 131 Set the Hydrogen column density to 5E 6 i e 5E18 cm 2 par VAL 5 E 06 Fit the defined model to the spectrum fit RUN Select a PostScript plotting device Landscape orientation pdev PS Name the PostScript file iipeg3a ps pmen NAME iipeg3a ps Write a plot to the PostScript file pmen PLOT Change X axis units to nanometers uxda NM Change Y axis units to Count second uyda CS Write another plot to the PostScript file pmen PLOT Select a model component to determine an error bound for one of lts parameters In this example the multiplicative component is chosen err COMP comp MO1 and the Hydrogen column density is selected par PARA sabs NH And the error bounds are determined err RUN Finally a plot of the fit residuals is written to the PostScript file SRO
15. 05 2 01 1 22782E 05 Errors 1 22782E 05 4 00454E 05 BPrPRoarFoOoecoooococoocooooo o PWWRWROPRNRFR AN SE Comment SPEX displays a trial paramtere the X value the difference between the trial value and the current value of the parameter and the Ay Desc Sele Sele SPEX Version 1 00 Search errors of spectral parameters ription ct the spectral component for error search ct the parameter for the current component Set level of Delta chi 2 for the errors Dete Back Back rmine the errors to previous menu to main menu Enter your choice RUN main Comment main is entered to return to the main menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 54 oF 131 SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Modify the current model parameters Evaluate the current spectral model Simulate a spectrum using current model amp detector Spectral fitting error search etc Output of SPEX model properties to ascii file or screen Plot menu Enter your choice FIT plot
16. Differential Emission Measure files dem e Other files command com output out amp asc PostScript ps amp cps amp vps amp cvs and scratch files The following sections will discuss the file format i e the way in which data are written into a file of each file type Whenever possible Fortran programs are presented that show how to create a specific file format 6 2 Spectral data files Spectral data are read or written in binary spo or ASCIT spa format 6 2 1 Writing spectral data in binary format spo Binary files are opened as sequential unformatted files and contain the following information in designated order e HEADER A header consists of a number of header lines with a maximum of 256 characters per line The FIRST character of a header line MUST always be a c or a C The rest of the headerline is arbitrary and may be used to provide the binary data file with relevant information about the data set itself for example The information in the header lines will be ignored by SPEX The header MUST be closed by a line containing the following string SPEX spex or Spex This indicates to SPEX that the header is finished and the following fields contain spectral data e NCHAN integer 4 the number of output data channels Should be smaller than or equal to NBMAX NBMAX is currently set at 2048 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 0
17. Further we have photo ionized plasmas and optically thick plasmas Single multi and continous temperature models are also available A synthetic spectrum program convolves the calculated input spectra with representative instrumental response functions which are described in the documents SRON SPEX TRISO1 05 for various instruments onboard current or future X ray satellites Various applications can be classified for possible source configurations for optically thin thick plas mas for single multi or continuous temperature distributions and for steady state or transient behaviour For a general description of various models we refer to the document SPEX SRON TRPBOL shortly referred to as PBO1 especially sections 3 6 and 7 and for more specific descriptions to the cited literature We distinguish between the following physical models 1 Power Law E nonthermal spectrum qa is the energy spectral index For example radiation from the core of Active Galactic Nuclei AGN or radiation from a solar flare 2 Delta function representing an infinitely narrow spectral line 3 Gaussian line representing a single spectral line broadened by e g thermal Doppler effects by instrumental effects or by turbulent velocities We can make combinations of several lines 4 CIE model Optically thin steady state plasma in Collisional Ionization Equilibrium The ionization and excitation occur by electron impact The ionization is ba
18. RATE lIonisation and recombination rates per ion GRID Energy grid used for calculation of the model Continuum emission components ff fb 2p amp total for layer CLIN Continuum and total line radiation spectrum for layer LINE Spectral line fluxes for layer EBAL Energy balance loop control parameters Ev Supernova Remnant parameters Total continuum emission components ff fb 2p amp total a Total continuum and total line radiation spectrum TLIN Total spectral line fluxes CNTS Calculate expected line counts for current model amp detector BACK Back to previous menu MAIN Back to main menu Give the requested output MAIN Back to main menu Plot menu This main menu option provides the possibility to make plots of data and models processed by SPEX The pgplot interface is used for this purpose The plot menu options cover nearly all the desirable features one may find in various other packages e g IDL However if special plot features are required one is advised to save the respective data sets and use a different plot package M SIS s S t uz A plot type should be selected before the actual plot is made Once a plot type is selected it will be used until another type is selected Select a new plot type Each plot type distinguishes a data and a model part The model part may consist of different components The data and model parts are indicated for the plot types listed below The op
19. Redefine x axis units Redefine y axis units Modify x axis range Modify y axis range Change font type Change font height Modify caption texts Change plot symbols Histogram continuous line plot mode Change line weights Change line styles Change plot colours Back to main menu Enter your choice PLOT Comment is entered to generate another PostScript plot displayed in Fig 2 3 Note that the PostScript file is not overwritten by this option The generated PostScript file is appended to the end of the PostScript file i e plotted on a new page Document SRON SPEX TRUM SRON EE SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 48 oF 131 Observed spectrum iipeg5a SPEX Version 1 00 Wed Dec 7 09 03 03 1994 r r r T r r r r 0 025 T 02 0 ir Counts s 0 01 T o J o T Pt re RA EE m J Ret Bu EE 1 1 1 1 1 1 I T T T 1 2 3 4 Wavelength nm Figure 2 3 Plot of the observed and fitted data in customized units Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 49 oF 131 SPEX Version 1 00 SPEX plot menu Select a new plot type Do the plot Set plotting device Set plot file name PostScript print landscape mode PostScript print portrait m
20. Ryd HZ Emission 10 Photons s Hz ANG Emission 1044 Photons s NM Emission 10 Photons s nm Emission 10 Photons s m FWK Power 1078 W keV Power 1075 W Hz wa Power 1075 W A FWNM Power 1078 W nm y z z ty S RS ES RES my Power vF 1078 W When spectral model type is DEM sPEX Y 10 4 m DSPE Y d 10 m5 cMPC Y d 10 cm3 p PSK dY dT 109 m keV d dT 10 4 m3 K PDK dY dT d 107 m keV 4Y dT d 10 m5 K POK dY dT d 1099 Jem pe keV 4Y dT d 10 fem fpc K a Y 5 og Is Is E Redefine z axis units When 18 resp Document SRON SPEX TRUM SRON EE SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 102 oF 131 PGPLOT Fonts Normal ABCDQ efgh 1234 a 6y6 AOAQ Roman ABCDQ efgh 1234 afByd AOAN Italic ABCDQ efgh 1234 aByd AOAN Script 4448622 fg 1234 aByd AOAQ f x x cos 2nx e 1 25 km s Mpc t 5 6 A12168 Markers 3 8B 12 28 Figure 3 5 Example of available font types Area channel range m keV Area channel range cm keV Modify x axis range Modify y axis range Modify z axis range Change font type Modify the font type for all character strings The available font types are shown in fig 3 5 Normal zom Roman Italic Script Modify the font type for the box annotation only See options at
21. SPEX TRPBO05 and Mewe et al 1994 For both methods first the library of convolved spectra should be generated using the option IE It is important to use the right regularisation parameter Generate the spectrum library Calculate the library of convolved basis spectra for the DEM analysis IEF has to be executed again if any spectral parameter is changed but not if only the regularisation is changed REG Set regularisation parameter This option sets the regularisation parameter manually Larger values correspond to more smoothing 0 means no smoothing but then the solution is unphysical After this step the DEM analysis can be performed by choosing Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 93 OF 131 Do the differential emission measure analysis using the regularisation method With this option the differential emission measure DEM analysis may be performed on the current data set for the given regularisation parameter The library of convolved spectra has been calculated before with SCAL Set scale for automatic regularisation parameter search With this option the scaling value f is set It is used for the automatic regularisation Default and recommended value is 1 In this case the regularisation R is determined by ean ease 14 nf 3 3 Nchannel NT where f is the scaling factor nchannel is t
22. SPEX and all accompanying files and documentation are Copyright 1992 1995 by SRON Space Research Organisation Netherlands Utrecht All rights reserved PGPLOT is Copyright 1988 1989 by California Institue of Technology UNIX is a registered trademark of AT amp T PostScript is a registered trademark of Adobe Systems Incorporated Numerical Recipes 1s a registered trademark of Numerical Recipes Software Warranty disclaimer This software and accompanying written materials including in structions for use are provided as is without warranty of any kind Further SRON does not warrant guarantee or make any rep resentations regarding the use or the results of use of the software or written materials in terms of correctness accuracy reliability currentness or otherwise The entire risk as to the results and per formance of the software is assumed by the user Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 12 oF 131 Chapter 2 Example SPEX session 2 1 Introduction This chapter presents an example with SPEX A model will be fitted on a previously simulated spec trum of the star II Peg using the ASCA SIS instrument for more information about the simulation of the spectrum see document SRON SPEX TRCBO0I The results of the fit will also be discussed A schematic overview of the steps to be taken in the SPEX program is presente
23. al isothermal SNR model Band isothermal or isentropic reverse shock DEM model differential emission measure analysis Modified black body spectrum MBB Gaussian line Black body spectrum BACK to previous menu SPEX Version 1 00 SPEX model menu Define an additive component Define a multiplicative or redshift component Delete an additive component Show the current model Back to main menu Enter your choice MUL Comment is entered to define a multiplicative component Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 25 oF 131 SPEX Version 1 00 Define a multiplicative or redshift component Description Redshift component Absorption component Morrison amp McCammon Absorption component EUVE Absorption component hot CIE medium Back to previous menu Enter your choice REDS absm You have defined 1 multiplicative components Comment SPEX shows the list of available multiplicative components See chapter 4 of this manual and SRON SPEX TRCBO1 for more information on the spectral model components This example uses the absorption cross sections of Morrison amp McCammon 1983 therefore is entered SPEX shows the number of multiplicative components that are currently defined SPEX Version 1 00 Define a multiplicative or redshift component Description Redshift component Absorption component Morrison
24. as weights in the calculation of y Wheaton et al showed that the problem can be resolved by using instead o s i e the expected number of counts from the best fit model The current option allows to use these modified weights By selecting it the expected number of counts both source plus background of the current spectral model is used onwards in calculating the fit statistic Wheaton et al suggest to do the following 3 step process which we also recommend to the user of SPEX first fit the spectrum using the data errors as weights option the default at start up of SPEX After completing this fit select the option and do again a fit then repeat this step once more by again selecting in order to replace s of the first step by s of the second step in the weights The result should now have been converged under the assumption that the fitted model gives a reasonable description of the data BACK Back to previous menu MAIN Back to main menu RUN Fit the parameters using current data amp model Determine error bounds on parameters It is possible to determine the error bounds on one spectral model parameter at a time SPEX determines the error bounds by iteratively modifying the parameter of interest and calculating X as a function of the parameter During this process the other free parameters of the model may vary The iteration stops when x x24 Ax where Ax is a parameter that can be set separately The it
25. asks for a filename without the extension dem CLEA Do the differential emission measure analysis clean method MAIN Back to main menu 3 8 Plots amp ASCII files This category handles the presentation of the calculated data Plots may be made in the form of graphical output or alternatively written as PostScript files Data may be written to ASCII files Output of SPEX model properties to file or screen With this main menu option SPEX s current model properties can be displayed either on screen or saved into an ASCII file Only components corresponding with plasma models can be used in this main menu option Before displaying the menu structure SPEX will recalculate the current model This is because during normal model evaluations not all the necessary model information is calculated because of numerical efficiency reasons COMP Select the spectral component Additive component Ranging from 01 to 16 Multiplicative component Ranging from 01 to 08 DEV Output to screen or file NAME Give file name for ascii output without asc Select the type of output Run time statistics Plasma parameters temperatures densities etc Heating and cooling rates Abundances amp average charge ions Ion concentrations Ionisation rates per ionic subshell Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 95 oF 131
26. components Select component Ranging from 01 to 32 Change line styles Modify the line style for the data do not plot Modify the line style for all model components See options at Modify the line style for a single model component These are the components of the plot model not the spectral model components Select component Ranging from 01 to 32 SRON SPEX a C e Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 108 oF 131 PGPLOT Line Widths Line Width Figure 3 8 Example of available line weights Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 109 oF 131 Table 3 10 Available plot colours Value Colour 01 Black background 02 White default 03 Red 04 Green 05 Blue 06 Cyan Green Blue 07 Magenta Red Blue 08 Yellow Red Green 09 Orange Red Yellow 00 Green Yellow 11 Green Cyan 12 Blue Cyan 13 Blue Magenta 14 Red Magenta 15 Dark Gray 16 Light Gray Change plot colours ALL Modify the line colour for all plot variables Colour Ranging from 01 to 16 see Tab 3 10 BOX Modify the line colour for the box only See Tab 3 10 Modify the line colour for the x axis label only See Tab 3 10 Modify the line colour for the y axis label only See Tab 3 10 Modify the line colour for the upper title label only
27. font height Modify caption texts Change plot symbols Histogram continuous line plot mode Change line weights Change line styles Change plot colours Back to main menu Enter your choice PLOT name Give plotfile name with ps extension spex iipeg3a ps Comment The name of the PostScript file is set by entering and the name of the file Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 43 oF 131 SPEX Version 1 00 SPEX plot menu Select a new plot type Do the plot Set plotting device Set plot file name PostScript print landscape mode PostScript print portrait mode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear Redefine x axis units Redefine y axis units Modify x axis range Modify y axis range Change font type Change font height Modify caption texts Change plot symbols Histogram continuous line plot mode Change line weights Change line styles Change plot colours Back to main menu Enter your choice PLOT Comment The plot may be written to the PostScript file by entering The content of this file is displayed in Fig 2 2 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 EXAMPLE SPEX SESSION PAGE 44 oF 131 UsER s TUTORIAL MANUAL Observed spectrum iipeg3a SPEX Version 1 00 Wed Dec 7 09 03 03 1994 T T T T
28. normalization Fit the spectrum Simplex amp linear scalings This method is based on the Simplex minimization method by Press et al This method is not yet available in the current version of SPEX It should be used for complicated cases BACK Back to previous menu MAIN Back to main menu Set weighting type for x calculation ftyp Use data errors in weights classical chi 2 method This is the most widely used method x is usually calculated as the sum over all data bins i of N si o7 where N is the observed number of source plus background counts s the expected number of source plus background counts of the fitted model and for Poisson statistics usually one takes c N Take care that the spectral bins contain sufficient counts either source or background recommended is e g to use at least 10 counts per bin If this is not the case first rebin the data set The method has inaccuracies if N is less than 100 In that case use see below Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 90 oF 131 Use source background model counts in weights Wheaton et al 1995 have shown that the classical X method becomes inaccurate for spectra with less than 100 counts per bin This is not due to the approximation of the Poisson statistic by a normal distribution but due to using the observed number of counts N
29. options in this category control the way SPEX is run Exit from SPEX When SPEX is run in window mode this option is not available and SPEX may be left by quitting the main window In both interactive and window modes all open files are closed and run time statistics are shown HIDE Hide show menu listings for experienced users only This main menu option is a switch to hide or show the menu options Novice users are advised not to use the option to hide the menu listings until they have gained enough experience with SPEX When SPEX is run in window mode this option is not available When the menu options are hidden typing at the SPEX prompt will result in the display of the menu options for that particular menu Save or read log files for commands and output SPEX has the option to store and read commands from log files A log file is a copy of a sequence of commands from a previous SPEX run It is also possible to store SPEX output into a file If in the following options no path is specified SPEX will read or write to a file in the directory from which SPEX was started IE Chapter 7 gives a detailed description of the log file structure and usage of it COM Set log file for storing your commands Store commands into a log file The log file may be used to record steps that can be played back at a later time After the log file is closed it may be edited with an ASCII editor for example to add comment lines
30. parameters do a grid search Back to main menu Enter your choice RUN err Comment is entered to determine the error bounds on one of the model parameters Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 51 oF 131 SPEX Version 1 00 Search errors of spectral parameters Description Select the spectral component for error search Select the parameter for the current component Set level of Delta chi 2 for the errors Determine the errors Back to previous menu Back to main menu SPEX Version 1 00 Select a spectral component 401 Additive component 1 MO1 Multiplicative component 1 SPEX Version 1 00 Search errors of spectral parameters Description Select the spectral component for error search Select the parameter for the current component Set level of Delta chi 2 for the errors Determine the errors Back to previous menu Back to main menu Enter your choice RUN para Comment is entered to select a parameter from the current spectral model component ABSM Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 52 oF 131 SPEX Version 1 00 Select a spectral parameter absorption M amp M sabs Description Enter your choice NH Comment The multiplicative ABSM model component only has one parameter is entered to se
31. previous menu Back to main menu Do the grid search SPEX does the grid search and displays for each search parameter the following information Parameter value Chi 2 Delta chi 2 with respect to minimum BACK Back to previous menu MAIN Back to main menu Back to main menu Differential Emission Measure analysis DEM This main menu option provides tools to make a good DEM analysis DEM analysis should be used when the spectrum or model contains a continuous temperature distribution The spectral model can only have one additive component the DEM component that corresponds to a multi temperature structure There are no restrictions to the number of multiplicative components For a description of the DEM analysis method see document SRON SPEX TRPBO05 and Mewe et al 1994 Currently there are 2 DEM analysis methods available the regularisation method for which the options are available and the cleaning method for which the opti CLEA can be used The option and SAVE can be used with both methods The options in this menu determine the emission measure distribution but perform no fitting of other spectral parameters When the fitting of the other parameter 1s desired the fit option of the main menu should be used Note that in this case the fitting method should be the classical Levenberg amp Marquardt method without linear scalings The DEM algorithm uses a second order regularisation see document SRON
32. shock electron temperature keV Number of shells Uu E Number of projected rings zwi Minimum energy keV of radial profile semax Maximum energy keV of radial profile nMIN Minimum radius for projected spectrum annulus RMAX Maximum radius for projected spectrum annulus Abundance of element ranging from 02 to 30 Z 2 to 30 SNR model Chevalier adiabatic reverse shock xonM Normalisation 1079 m Electron temperature keV Ionisation parameter 107 s m T lon temperature keV vwic Micro turbulence velocity km s Density gradient s of ISM Z ti Density gradient n of stellar ejecta aam Adiabatic index Angular filling factor Pre shock electron temperature keV Number of shells zZ v Z a Number of projected rings Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 82 oF 131 emin Minimum energy keV of radial profile semax Maximum energy keV of radial profile RMIN Minimum radius for projected spectrum annulus rmax Maximum radius for projected spectrum annulus Abundance of element ranging from 02 to 30 Z 2 to 30 SNR model Hamilton adiabatic reverse shock clumps NonM Normalisation 1029 m Electron temperature keV Ionisation parameter 107 s m9 Ion temperature keV vmic Micro turbulence velocity km s Density gradi
33. source region due to variations in detector response to background counts For imaging detectors this is the ratio of the number of pixels in the source and in the background region if necessary corrected for small detector inhomogeneities For collimator detectors this ratio should be 1 since the background is determined by swapping the detector between source and background The source to background area ratio may be energy dependent e g for imaging detectors with energy dependent spatial pointspread functions such as the SAX ME concentrator In this case SPEX reads the new ratio for the first channel Rnew 1 and calculates the new ratio for channel by Rnew 1 Fio Rnew i Fia TIME Integration time source spectrum Default at program startup 1s 40000 BTIM Integration time background spectrum Default at program startup 1s 40000 Add Poisson noise yes or no Realistic spectra require Poisson noise 3 1 Default at program startup 1s yes SYST Systematic error fraction of source flux This option is useful in cases where the detector efficiency is variable in time or badly calibrated and when these variations cannot be reproduced SPEX uses the systematic errors as being energy independent Default at program startup 1s 0 BSYS Systematic error fraction of raw background This option is useful in cases where the detector background is time variable or 1s different for the source and
34. spectral line Gaussian line single spectral line broadened by e g thermal Doppler instrumental or tur bulent velocity effects Power Law E nonthermal spectrum e g AGN stellar flare Black Body spectrum optically thick single temperature Modified Black Body spectrum modified by Compton scattering on nonrelativistic elec trons optically thick single temperature e g active galactic nucleus AGN Further SPEX encompasses the following multiplicative components that can be applied in arbitrary sequence to any combination of additive components Redshift cosmological redshift Absorption X ray absorption from the diffuse ISM according to Morrison amp McCammon 1983 Absorption EUV absorption from the diffuse ISM according to Rumph et al 1994 Absorption continuum absorption by a hot plasma in collisional ionization equilibrium CTE SPEX Models under development The following more sophisticated models are currently under development 1 Active Region Loop model Optically thin multi temperature stationary plasma in coronal loop structures G H J van den Oord LTE atmosphere model Optically thick atmosphere with temperature stratification in Local Thermal Equilibrium with irradiation by an external radiation field e g a white dwarf the stellar wind of an O star J Heise Photo ionized model Nebular type plasma with ionization dominated by external radiation fie
35. 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 77 OF 131 Table 3 1 Output of the SPEX show data option Latest spectral data file Latest spectral response file Number of photon model energy bins Number of photon model energy bins Number of response groups Number of response groups Photon model energy range keV Data energy range keV Net source count rate counts s Net source counts Background count rate subtracted c s Background counts subtracted Average integration time per channel Minimum integration time per channel Maximum integration time per channel Aver exposure rat source background Min exposure ratio source background Max exposure ratio source background Se FE SR FR FR ER FR EE FR EE Do NOT use this option if the current spectral model contains redshift components In that case SPEX calculates it s model spectrum on a wider energy grid than that for which the detector may be sensitive BACK Back to previous menu MAIN Back to main menu SHOW Show the current data set The ouput of this option is shown in tab 3 1 MAIN Back to main menu 3 4 Spectral model The main menu options in this category enable the definition and modification of models that generate spectra that are to be compared with an observed spectrum A model may consist of several additive and multiplicative components The relations between the defined components can be changed at will The various p
36. 21 113 133 15 1 168 99 73 9 00 11 8 142 163 182 201 99 99 15 1 184 211 23 5 25 7 27 8 MAIN Back to main menu Do a grid search A grid search is performed of x versus 1 2 3 or 4 parameters The minimum maximum and number of steps for each parameter may be adjusted Steps may be linear or logarithmic For each set of parameters a spectral fit is made using the last spectral fit before this STEP option as the starting point For each step the parameters and x are displayed This option is useful in case of doubt about the position of the best fit in the parameter space or in cases where the usual error search is complicated Dimension of grid number of search parameters Default at program startup 1s 1 Set parameters for parameter axis in grid search Ranging from 1 to 4 Select the spectral component for current axis el Additive component Ranging from 01 to 16 Multiplicative component Ranging from 01 to 08 Select the parameter for the current component and axis See 3 3 under Low Set lower value for parameters axis Set upper value for parameters axis Set number of steps for parameters axis negative for log steps For example grid axis axis type input HIDBIHISISITIS lineair 8 1 2 4 8 16 32 64 128 logarithmic 8 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 92 oF 131 Back to
37. 31 SPEX Version 1 00 SPEX data menu Set the format of the data files binary or ascii Type of data to be read or written res spo or res amp spo How are the new data to be combined with the old data Read new data set be sure FORM TYPE and COMB are correct Save the current data set be sure FORM TYPE are correct Modify rebin or optimise the current data set Show the current data set Back to main menu Enter your choice SHOW show Comment is entered to show the characteristics of the data that were just read Your energy grid contains 989 bins Start energy 0 19886 keV End energy 11 993 keV Latest Latest Number Number Number Number Photon spectral data file lipeg3a spectral response file lipeg3a of photon model energy bins 989 of data channels 230 of response groups 989 of non zero response elements 8487 model energy range keV 0 19886 11 993 Data energy range keV 0 25523 12 047 Net source count rate counts s 0 62613 3 97201E 03 Net source counts 25045 159 Background count rate subtracted c s 4 40611E 03 Background counts subtracted 176 Average integration time per channel 40000 Minimum integration time per channel 40000 Maximum integration time per channel 40000 Aver exposure rat source background 0 10000 Min exposure ratio source background 0 10000 Max exposure ratio source background 0 10000 Comment The menu returns after the data
38. 6 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 117 or 131 e TINTS NBMAX real 4 array the total net integration time in s of the source spectrum as a function of bin number Note that e g appending of spectra from other instruments to the current data set may lead to different integration times per channel e OCHAN NBMAX real 4 array the observed spectrum in counts s bin e DOCHAN NBMAX real 4 array the errors in the observed spectrum in counts s bin e BCHAN NBMAX real 4 array the model background spectrum in counts s bin This is used only for spectral simulations or for spectral fits where the expected instead of the observed number of counts is used in the weights of the fit statistic e FCHAN NBMAX real 4 array the exposure ratio of the expected number of background counts in the source region to the expected number of background counts in the background region Factors to be taken into account in this factor are e g exposure times detector areas and average efficiencies of both parts This array is only used for spectral simulations An example Fortran routine to write binary spectral data files is presented in Fig 6 1 6 2 2 Writing spectral data in ASCII format spa ASCII files are opened as sequential formatted files and contain the following information in desig nated order e HEADER A header consists of a number of header lines with a maximum of 256 characters per line The FIRST character
39. April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 46 oF 131 SPEX Version 1 00 SPEX plot menu Select a new plot type Do the plot Set plotting device Set plot file name PostScript print landscape mode PostScript print portrait mode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear Redefine x axis units Redefine y axis units Modify x axis range Modify y axis range Change font type Change font height Modify caption texts Change plot symbols Histogram continuous line plot mode Change line weights Change line styles Change plot colours Back to main menu SPEX Version 1 00 Set unit y axis for data Counts Counts s Counts s keV Counts s Ryd Counts s Hz Counts s A Counts s nm Counts s m Counts m 2 s Counts m 2 s keV Counts m 2 s Ryd Counts m 2 s Hz Counts m 2 s A Counts m 2 s nm Counts m 2 s m Enter your choice KEV cs Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 47 oF 131 Comment will set the units of the y axis to Counts per second SPEX Version 1 00 SPEX plot menu Select a new plot type Do the plot Set plotting device Set plot file name PostScript print landscape mode PostScript print portrait mode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear
40. Computational Project No 7 CCP7 on The physics of chromospheres coronae and winds ed C S Jeffery March 1992 Cambridge p 33 Mewe R Gronenschild E H B M 1981 Astron Astrophys Suppl Ser 45 11 Paper IV Mewe R Gronenschild E H B M van den Oord G H J 1985a Astron Astrophys Suppl Ser 62 197 Paper V Mewe R Kaastra J S 1994 X ray spectral modelling European Astron Society Newslett Issue 8 June 1994 p 3 Mewe R Kaastra J S Schrijver C J van den Oord G H J Alkemade F J M 1994 Astron Astrophys in press Mewe R Lemen J R van den Oord G H J 1986 Astron Astrophys Suppl Ser 65 511 Paper VI Morrison R McMcCammon D 1983 Astrophys J 270 119 Press W H Flannery B P Teukolsky S A and Vettering V T 1992 Numerical Recipes Cambridge University Press Rosner R Tucker W M Vaiana G S 1978 Astrophys J 220 643 Ross J E Aller L H 1976 Science 191 1223 Rumph T Bowyer S Vennes S 1994 Astron J in press Rybicki G B Lightman A P 1979 Radiative processes in astrophysics Wiley New York Sedov L 1959 Similarity and dimensional methods in mechanics Academic Press New York Solinger A Rappaport S Buff J 1975 Astrophys J 201 381 Vesecky J F Antiochos S K Underwood J H 1979 Astrophys J 233 987 Wheaton W A Dunklee A L Jacobson A S et al 1995 Astrophys J 438 322 SRON
41. Doppler broadening by 10ns and microturbulence BACK Back to previous menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 73 OF 131 MAIN Back to main menu Set type of line calculation old or new Ical This offers the opportunity to choose between the old mekal model and the newer spex calculations that become gradually available for more ions OLD Use old plasma code mekal Use new plasma code spex BACK Back to previous menu MAIN Back to main menu MAIN Back to main menu DATA Read write show or modify data response amp obs spectrum This is the file I O option for data of the SPEX program Spectral data and response files may be read and or written Data sets may be modified To learn more about the various file formats see chapter 6 Set the format of the data files binary or ascii BIN Set the format of the data files to binary mode Asc Set the format of the data files to ascii mode Back to previous menu TYPE Type of data to be read or written res spo or res amp spo dtyp R Response file to be read or written Spectra file to be read or written Both spectra and response files to be read or written D Me tll H gt H BACK Back to previous menu COMB How are the new data to be combined with the old data comb Read a new data set Any existing data set in SPE
42. EM was read this input DEM is plotted as model MAIN Back to main menu Do the plot SPEX plots the plot with all current settings on the selected output device An example plot is given in fig 3 4 The available output devices depend on the available output devices in the pgplot library that is used by SPEX Set plotting device Null device no output PostScript file landscape orientation Default at program startup Is spex SRON SPEX Document Date Issue SRON SPEX TRUM April 24 1995 Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 97 oF 131 Observed spectrum iipeg3a Example plot with SPEX Version 1 0 a Counts plot type plot device x axis units y axis units font for box annotation font for x amp y axis label font for upper amp lower title label font for identification label x axis label y axis label upper title label lower title label identification label plot symbol data line plot mode line weight for x amp y axis label line weight for upper title lable line weight for data amp model Wavelength A Plot characteristics data observed spectrum amp predicted model PostScript file landscape orientation Wavelength A Counts italic roman roman Script Wavelength A generated by SPEX Counts generated by SPEX Observed spectrum generated by SPEX iipeg3a the name
43. I ras format Only data for which the response is non zero are written This optimizes the memory usage of SPEX For this purpose response groups are defined A response group is a sequence of consecutive channels for a fixed input bin number for which all response elements are non zero Note that in principle one input energy bin can consist of several response groups Example data for a grating where the higher orders Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 119 or 131 integer 4 nbmax parameter nbmax 2048 integer 4 nchan real 4 tints nbmax ochan nbmax dochan nbmax bchan nbmax chan nbmax open unit 10 file dummy spa status unknown access sequential form formatted write 10 a C This is the first header comment line write 10 a C This is the last header comment line write 10 a SPEX write 10 nchan do i 1 nchan write 10 ib b5b 1pg14 6 i tints i ochan i dochan i bchan i fchan i enddo close unit 10 status keep end Figure 6 2 Example Fortran program to create ASCII spectral data files that are readable for SPEX can form separate groups 6 3 1 Writing response matrices in binary format res Binary files are opened as sequential unformatted files and contain the following information in designated order e HEADER A header con
44. N SPEX Dae Ur Apri 24 1008 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 63 OF 131 ptyp CHI2 pmen PLOT HHHHHHHHHAHHHRHHHAHHHE RHA HEHEHE RHEE RHEE RR EE RRR IE UE Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 64 oF 131 Chapter 3 SPEX Menu Structure 3 1 Introduction This chapter presents the complete menu structure of SPEX To recapitulate the example SPEX session in Chapter 2 showed more menu options as more data were loaded into SPEX and models were defined The complete SPEX main menu is displayed in Fig 3 1 The main menu is displayed in Fig 3 2 again now divided into categories of special purposes The following sections will describe all menu options in each category It should be noted that there is no difference in the menu structure for the windows version or the terminal version of SPEX However the windows version of SPEX does not use the options BACK and MAIN since under windows one uses the mouse to change to different menus SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp
45. N for complex modeling of hot astrophysical plasmas in view of fitting space based observations It has been applied in analyzing archival EXOSAT and EINSTEIN data recent EUVE amp ASCA data and in simulating AXAF amp XMM spectra SPEX encompasses a number of sophisticated modules for the computation of the physical parameters and associated emergent spectra of a variety of plasmas including optically thin plasmas such as stellar coronae and supernova remnants photo ionized plasmas and optically thick plasmas The model spectra can be convolved with instrumental response functions and compared with observations Examples of various spectral simulations are shown In short SPEX offers advantages such as advanced graphical and ascii file display of plasma and spectral parameters extended energy range from UV to X rays combination of many different models response matrices for various instruments like EUVE SAX ASCA XMM amp AXAF independent choice of energy grid and rebinning important for XMM amp AXAF combination of observations from different instruments for simulation amp fitting differential emission measure DEM analysis and other fitting methods complicated plasma models such as supernova remnant and coronal loop models non equilibrium ionization and photo ionization extended documentation on software and physical background Some details of performance are discussed below 1 Modeling a Com
46. ON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 39 OF 131 2 fit parameter 3 non fit parameter parameter with unit describes the spectral model parameter and shows the corresponding unit value denotes the current value of the parameter in the specified unit st denotes the status of the parameter 0 frozen 1 fitable free Each parameter may be fitted if allowed in the range between minimum and maximum with stepsize step Finally fluxes and luminosities are shown for the additive component CIE mod nr parameter with unit mod nr parameter with unit correlation cie 2 Temperature keV cie 2 Temperature keV 1 0000 cie 2 Temperature keV absm 1 Column 1E28 m 2 0 99998 absm 1 Column 1E28 m 2 Column 1E28 m 2 mod nr parameter with unit mod nr parameter with unit correlation cie 1 ne nH V 1E64 m 3 cie 1 ne nH V 1E64 m 3 1 0000 Normal end of input file encountered Comment Next SPEX shows the correlations between the free fit parameters above and the nor malization parameters below See Press et al 1992 for more information about the correlation of fit parameters SPEX Version 1 00 SPEX fit menu change the spectral fitting method fit the parameters using current data amp model determine error bounds on parameters do a grid search Back to main menu Enter your choice RUN main Comment main is entered to return to the mai
47. ON SPEX TRPBO7 Hot high gravity LTE atmosphere modelling TBD by J Heise SRON SPEX TRPBO0S Photo ionized modelling TBD by J S Kaastra Instrumental Response and Spectral Simulation SRON SPEX TRISOO Overview SRON SPEX TRISO1 EUVE SRON SPEX TRIS02 AXAF SRON SPEX TRIS03 XMM SRON SPEX TRISO04 SAX SRON SPEX TRISO5 ASCA Cookbook SRON SPEX TRCBO1 Cookbook Figure 1 1 Overview of the user level document structure Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL INTRODUCTION PAGE 11 or 131 Program level e SRON SPEX TRSWO I Introduction to the SPEX software e SRON SPEX TRSWO2 SPEX software description Declaration of variables and software level descriptions e SRON SPEX TRSWO3 Installation document Test cases system and hardware requirements installation procedure Figure 1 2 Overview of the program level document structure 1 7 Useful addresses If after careful examination of the manuals serious problems remain or suggestions of improvement arise please contact one of the persons below Rolf Mewe Internet R Mewe sron ruu nl SRON Utrecht Sorbonnelaan 2 3581 CA Utrecht The Netherlands Fax 31 0 30 540860 Jelle Kaastra Internet J KaastraGsron ruu nl SRON Utrecht Sorbonnelaan 2 3581 CA Utrecht The Netherlands Fax 31 0 30 540860 1 8 Copyrights trademarks and distribution policy
48. PEX SESSION SRON SPEX TRUM April 24 1995 Version 1 06 PAGE 13 or 131 Basic parameters 2 2 Source distance 29 4 pc Response file 2 3 ASCA SIS instrument Spectral model 2 4 collisional ionisation equilibrium model CIE plus absorption ABSM Counts s keV Counts s Plots 2 7 keV nm Accuracy of the fitted parameters 2 8 Input spectral parameters 82 5 emission measure temperature electron density micro turbulence velocity I S M column density Abundances relative to solar Anders amp Grevesse neng 109 m 3keV 1019 m 0kms 5 10 2m Figure 2 1 Schematic display of example SPEX session Each step will be discussed in separate sectiond of this chapter UsER s TUTORIAL MANUAL Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 EXAMPLE SPEX SESSION PAGE 14 oF 131 Comment SPEX displays a shortened version of the main menu Since there are no data read or models specified SP EX offers only limited possibities First some basic parameters and units will be set The distance of the source must be specified This is very important because SPEX uses luminosities not fluxes to calculate and fit models except of course for the observed and simulated spectra is entered to set the source distance SPEX Version 1 00 SPEX distance menu Define the unit of your distance scale Enter the value of th
49. SRON SPEX SPEX User s Tutorial Manual SRON SPEX TRUM SPEX Version 1 06 April 25 1995 prepared by J S Kaastra SRON Utrecht R Mewe SRON Utrecht H Nieuwenhuijzen RUU SRON Utrecht F van der Wolf SRON Utrecht SRON SPEX Dae Ur Apri 24 1008 Issue Version 1 06 UsER s TUTORIAL MANUAL PAGE 1 or 131 Preface This is the user s manual of SPEX version 1 06 released 25 april 1995 A novice user is advised to read at least Chapter 2 which gives an example of a typical SPEX session Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL PAGE 2 or 131 Contents Preface 1 Introduction 1 1 1 2 1 3 1 4 1 5 1 6 1 7 1 8 Development of Spectral Codes at SRON 2 aaa Spectral components available in SPEX aaa 00 0 2 0 008 SPEX Models under development 2222s SPEX Document structure 2 2 aa s osos Acknowledgements 0 son Useful addresses 222 s or Copyrights trademarks and distribution policy ls 2 Example SPEX session 2 1 2 2 2 3 2 4 2 5 2 6 2 7 2 8 2 9 Introduction oaa s n Basic parameters 2 a e S S s sa Response flle 2222s Ro o rs Spectral model aoaaa rs Input spectral parameters 2 le sr Fit of the parameters 2 2 les e sa Plot of observed and fitted data aaa Accuracy of the fitted parameters 22 ll ll rs Using a log file a
50. T Counts s keV 0 5 DA treater zs 2 4 6 Energy keV Figure 2 2 The first plot of the observed and fitted data made with SPEX all settings are the default settings at program startup Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 45 oF 131 SPEX Version 1 00 SPEX plot menu Select a new plot type Do the plot Set plotting device Set plot file name PostScript print landscape mode PostScript print portrait mode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear Redefine x axis units Redefine y axis units Modify x axis range Modify y axis range Change font type Change font height Modify caption texts Change plot symbols Histogram continuous line plot mode Change line weights Change line styles Change plot colours Back to main menu Enter your choice PLOT ux Comment The plot in Fig 2 2 was made using the default settings belonging to the default plot type at program startup is entered to change the units of the x axis SPEX Version 1 00 Set unit x axis for data Energy keV Energy Rydberg Frequency Hz Wavelength A Wavelength nm Wavelength m Enter your choice KEV nm Comment is entered to set the x axis units to nm nanometers Document SRON SPEX TRUM SRON SPEX Date
51. X s memory will be overwritten with the newly selected data et Read a new data set amp add per channel to old data The new and old data set must have the same energy grid and number of channels This option is useful for combining spectra obtained simultaneously by two nearly identical detectors e g the two ASCA SIS detectors un Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 74 oF 131 Read a new data set amp average with old data set The new and old data set must have the same energy grid and number of channels This option is useful for combining e g spectra taken at different epochs with the same instru ment for an analysis of the time averaged spectrum Example two SIS spectra of Cas A obtained by ASCA at different dates Read a new data set amp append it after the old data This option should be used to combine data obtained by two or more completely different instruments The new data channels will be appended after the old channels thus creating a single combined spectrum and response matrix Example combining the SIS and GIS data of ASCA Back to previous menu Read new data set be sure FORM TYPE and COMB are correct NE Unless the file name 1s changed SPEX will use the default file name at program startup spex or the last defined filename RNAM Change file name containing the response matrix Change file
52. a filename only 252 characters can be used to specify the filename 4 characters are needed to append the extension of the filename this is done internally Some notes 1 It may occur that several variables real 4 or integer 4 need to be entered at the same time In those situations SPEX reads the input as a character string 256 characters and extracts the variables from the string 2 menu and ITEM need to be separated by at least one space The same condition holds for ITEM and input 3 It does not matter if menu or ITEM are entered in either lower or upper case SPEX will convert menu to lower case and ITEM to upper case automatically However the case of the input field is very important Whenever file names are entered through the input field one should keep in mind that UNIX is case sensitive 7 2 2 Comment lines Comment lines may be added to the log file to explain certain steps in the log file The first character of a comment line must be a at the beginning of a new line The comment line has a maximum of 256 characters There 1s no restriction to the number of comment lines that follow each other in a log file It might be a good convention to put the comment line before a command line There are two ways to add comment lines to a log file 1 After a certain part of a SPEX session is recorded and the log file is closed comment lines may be added to
53. ain menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Plot menu SPEX Version 1 00 SPEX model energy grid selection menu Description Linear energy grid Logarithmic energy grid Input your own grid from a file Input the grid of a response matrix Save the current energy grid to a file Back to main menu Enter your choice LOG data Comment This example uses a simulation of the ASCA SIS data therefore a compatible energy grid must be used A response matrix of the ASCA SIS instrument is available see document SRON SPEX TRISO5 and is entered to read it Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 18 oF 131 SPEX Version 1 00 SPEX model energy grid from response matrix menu Description Set file name of response matrix with energy grid Read the file with the energy grid Back to previous menu Back to main menu Enter your choice NAME Enter response matrix without res extension spex iipeg3a Comment is entered to define the name of the file containing the response matrix SPEX asks for a n
54. ame and is entered SPEX Version 1 00 SPEX model energy grid from response matrix menu Description Set file name of response matrix with energy grid Read the file with the energy grid Back to previous menu Back to main menu Enter your choice READ Your energy grid contains 989 bins Start energy 0 19886 keV End energy 11 993 keV Comment reaa is entered to read the response matrix After the file is read and processed SPEX displays the start and end energies of the energy grid and returns to the main menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 19 oF 131 SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Plot menu Enter your choice ELIM data Comment Back in the main menu is selected to read the observed spectrum and the response file SPEX Version 1 00 SPEX data menu Set the format of the data files binary or ascii Type of data to be read or written res spo or res amp spo How are the new data to be combined with the old data Read new data set b
55. amp McCammon Absorption component EUVE Absorption component hot CIE medium Back to previous menu SPEX Version 1 00 SPEX model menu Define an additive component Define a multiplicative or redshift component Delete an additive component Delete a multiplicative or redshift component Set relation additive amp multiplicative components Show the current model Back to main menu Enter your choice REL Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 26 OF 131 Comment The spectral model is now defined is entered to set the relations between the additive and multiplicative components SPEX Version 1 00 Define relations additive and multiplicative components Description Define relations for additive component 1 Define the same dependence for all additive components Back to previous menu Enter your choice SAME Enter the dependency 0 0 O O O 0 0 0 1 Comment SPEX shows the relations between the current spectral model components In this example all components need to have the same dependency thus is entered Spex asks for a numerical input value and is entered This indicates that the cie component will be multiplied with the multiplicative component the absm component If more multiplicative components had been defined their dependencies are specified as well e g 3 1 2 in the case of 3 multiplica
56. arameters of the spectral models can be modified as well Modify the spectral model In a spectral model SPEX uses two different types of components emission and absorption here called additive and multiplicative respectively Additive components have a normalisation that determines Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 78 oF 131 the flux level Multiplicative components operate on additive components A delta line or a power law are typical examples of additive components Interstellar absorption is a typical example of multiplicative components The redshift component is treated as a multiplicative one since it operates on additive components Define an additive component See chapter 4 for specific information about the model components The newly defined component will be appended to the already existing one s A maxi mum number of 16 additive components is permitted PO DELT Delta line Simple power law IE Collisional ionisation equilibrium model NEIJ NEI model discontinuous temperature jump a Q o CHEV SOLI BAND NR model NR model S S HAM SNR model SNR model S NR model Sedov adiabatic Chevalier adiabatic reverse shock Hamilton adiabatic reverse shock clumps Solinger et al isothermal Band isothermal or isentropic reverse shock EM DEM model di
57. ate April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 34 oF 131 SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the parameter for the current component Set new value of the parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu Enter your choice VAL add comp 1 cie El dens 1E20 m 3 type 2 1 E 14 SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the parameter for the current component new value of the parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu Enter your choice VAL comp Comment Now the parameters of the multiplicative component will be modified is entered to select a new spectral component Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 35 oF 131 SPEX Version 1 00 Select a spectral component 401 Additive component 1 MO1 Multiplicative component 1 SPEX Version 1 00 Define or modify spectral parameters
58. ated using element abundances expressed in specified standard units The default abundance set is that of Anders amp Grevesse 1989 which are solar photospheric values The available options are displayed below however in most cases the Anders amp Grevesse 1989 set is recommended Solar abundances Anders amp Grevesse 1989 Solar abundances Allen 1973 Solar abundances Ross amp Aller 1976 Solar abundances Grevesse 1992 Back to previous menu MAIN Back to main menu Ionisation balance for CIE plasmas SPEX offers the opportunity to change the ionisation balance for CIE plasmas The default and recommended set of ionisation and recombination rates is currently Arnaud amp Raymond 1992 for iron and Arnaud amp Rothenflug 1985 for the other elements For NEI spectra like e g the supernova remnant models always the default rates are used DEF Use SPEX default currently Arnaud amp Raymond for Fe Arnaud amp Rothenflug 1985 Arnaud amp Rothenflug 1985 Arnaud amp Raymond 1992 for Fe Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 72 OF 131 BACK Back to previous menu MAIN Back to main menu GACC Set accuracy for free bound Gaunt factor The free bound gaunt factors as calculated by SPEX have limited accuracy Contributions from ions with low abundances or from the highest excited levels of ot
59. ax open unit 10 file dummy spo status unknown access sequential form unformatted write 10 C This is the first header comment line 10 C You are allowe to have 0 comment lines in SPEX 10 C But always end the header with a line starting with SPEX 10 C This is the last header comment line 10 SPEX 10 nchan 10 tints i i 1 nchan 10 Cochan i i 1 nchan 10 dochan i i 1 nchan 10 bchan i i 1 nchan 10 fchan i i 1 nchan close unit 10 status keep end Figure 6 1 Example Fortran program to create binary spectral data files that are readable for SPEX 6 3 Response Matrices In SPEX the response R IC IE is defined as the number of expected counts in channel tc for 1 photon m in input energy bin number tE Note that the effective detector area has been included in the response it is not a free normalisation parameter The effective detector area may contain sharp detector edges SPEX offers the possibility to define these edges in order to exclude the possibility of erroneous interpolation at these edges SPEX then interpolates the edge correctly starting at the correct side of the edge if the response matrix is read in and another input energy grid has been defined than is included in the response file itself It is always safer to include the edges as one of the input boundaries Response matrices may be read or written in binary res or ASCI
60. background region and can not be reproduced SPEX uses the systematic errors as being energy independent Default at program startup 1s 0 RUN Do the simulation MAIN Back to main menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 89 oF 131 3 7 Fitting The main menu options in this category provide possibilities to fit the spectral model on the selected data Fit the parameters using current data amp model With this main menu option the spectral model may be fitted to the selected data using the spectral fitting method defined by menu option METH Change the spectral fitting method Fit the spectrum classical Levenberg Marquardt method This widely used method is a combination of the steepest descent and the inverse Hessian method See Press et al It is well known that this method does not always converge to the absolute minimum but sometimes to a local sub minimum This method is used in the DEM analysis since it does not use a normalization LML Fit the spectrum Levenberg Marquardt amp linear scalings As above however the normalizations and abundances of the additive components are determined by simple matrix inversion All abundances are determined in a single iteration step which speeds up the calculations considerably This method should not be used in combination with a DEM analysis because it uses a
61. backslash character X list of the defined escape sequences is given in tab 3 7 A lookup table for Greek letters is presented in tab 3 8 Some useful non ASCII characters are listed in tab 3 9 Fig 3 6 shows some examples of the use of pgplot escape sequences in character strings Modify the x axis label Modify the y axis label Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 104 oF 131 Table 3 7 A list of available escape sequences Seq description Nu start a superscript or end a subscript Nu must be ended by a Md d start a subscript or end a superscript A d must be ended by a Nu NN backspace i e do not advance textpointer after plotting the previous character MA ngstrom symbol Ngt greek letter corresponding to roman letter x fn switch to Normal font Mr switch to Roman font fi switch to Italic font Ms switch to Script font n character number n see pgplot manual appendix B tab 1 Table 3 8 List of upper and lower case Greek letters G and their corresponding Roman letters R R A B G E Z Y H I K LIM NI C P R S T UJ FIXI Q W c aj r a e z no r k a w x s o ur s r v v x v o R a 6 g d ej z y h k t mi n c p lris tivu f zcvri q w cobble bt pie ee EEL Ls viele Table 3 9 Some useful non ASCII character sequences 2248 0583 x 0248 2267 0250 2268 x 2245 2269
62. ce Set plot file name PostScript print landscape mode PostScript print portrait mode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear Redefine x axis units Redefine y axis units Modify x axis range Modify y axis range Change font type Change font height Modify caption texts Change plot symbols Histogram continuous line plot mode Change line weights Change line styles Change plot colours Back to main menu Enter your choice PLOT Comment is entered to make the plot Since the plot device has not been changed this plot will be appended to the existing PostScript file The content of this plot is displayed in Fig 2 4 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 58 oF 131 SPEX Version 1 00 SPEX plot menu Select a new plot type Do the plot Set plotting device Set plot file name PostScript print landscape mod
63. components With this option it 1s possible to determine the way in which multiplicative components act on the additive components For example assume two multiplicative components the first one an absorption and the second a redshift component For each additive component the order in which the multiplicative components operate on it may be defined e g first the redshift then the absorption In the above example the SPEX command would be 2 1 0 0 0 0 0 0 It is also possible to enforce this relation on all defined additive components Define relations for additive component Ranging from 01 to 16 Define the same dependence for all additive components Back to previous menu SHOW Show the current model The output of this option 1s displayed in tab 3 2 BACK Back to main menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 80 oF 131 Modify the current model parameters The spectral model parameters of the current model may be adjusted with this main menu option Select first the component then the parameter and finally which property of the parameter should be modified in subsequent calls If one of the porperties of the same parameter as in the last call should be modified the component and parameter need not to be defined again Exception in cases where the model has been adjusted by adding or deleting spectral model component
64. cument Date Issue SPEX MENU STRUCTURE SRON SPEX TRUM April 24 1995 Version 1 06 PAGE 106 or 131 PGPLOT Marker Symbols 2 5 6 7 8 9 10 11 12 T 14 A 1S 16 17 18 19 20 21 22 235 24 o O 25 26 27 28 29 C 30 at 1 2 3 4 5 6 7 8 e e Figure 3 7 Example of available plot symbols Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 107 oF 131 Change line weights Default at program startup is 1 The line weights may be chosen within the range from 1 normal to 201 extremely thick lines see fig 3 8 Modifying the line weights of the labels may be used to generate bold face characters ALL Modify the line weight for all plot variables Box Modify the line weight for the box only Modify the line weight for the x axis label only Modify the line weight for the y axis label only UTIT Modify the line weight for the upper title label only LTIT Modify the line weight for the lower title label only ID Modify the line weight for the identification label only DATA Modify the line weight for the data only MOD Modify the line weight for the model components only SING Modify the line weight for a single model component only These are the components of the plot model not the spectral model
65. cument SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 87 oF 131 Table 3 4 Output of the SPEX option show the correlation between the fitted parameters In this case the spectral model consists of two components An additive collisional ionisation equilibrium model cie and a multiplicative absoprtion component Morrison amp McCammon absm mod nr parameter with unit mod nr parameter with unit correlation cie 2 Temperature keV cie 2 Temperature keV 1 0000 cie 2 Temperature keV absm 1 Column 1E28 m 2 99999 absm 1 Column 1E28 m 2 absm 1 Column 1E28 m 2 1 0000 mod nr parameter with unit mod nr parameter with unit correlation cie 1 ne nH V 1E64 m 3 cie 1 ne nH V 1E64 m 3 1 0000 With this main menu option SPEX will simulate a spectrum based on the currently defined spectral model and the chosen detector SPEX will do the simulation based on the parameters as displayed in the menu below These parameters have to be set before doing the actual simulation SPEX s simulation procedure is briefly as follows First the total spectrum in the source region is calculated including source and background counts The total number of counts is randomized using Poisson statistics The background spectrum in the background region is evaluated and randomized Then this background is scaled to the expected value in the source region and substracted from t
66. d 1986 Paper VI Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL INTRODUCTION PAGE 7 OF 131 a extended line amp continuum emission CIE 1985 codes with full description 7 Kaastra Jansen 1984 93 a EXOFIT code for spectral fitting of EXOSAT data b enhanced speed of ion balance calculations by a matrix inversion instead of 4th order Runge Kutta c development of various NEI supernova remnant models 8 Kaastra and Mewe 1992 93 a update amp extension of continuum amp line emission b development of new DEM code with C J Schrijver Alkemade van den Oord c d installment of MEKA code at HEASARC NASA 1992 development of photo ionization model amp calc of Auger ionization 9 Kaastra Mewe 1992 development of SPEX code a structuring the code with Nieuwenhuijzen b model development amp implementation c updating atomic physics and databases including e improved Fe L shell Fe XXIV XVIT calculations with Liedahl HULLAC code at Liver more e Arnaud Raymond 1992 ionization balance addition of about 60 DR lines to the He like Mg lines at 1 3 keV e addition of over 300 EUV lines from Landini Monsignori Fossi 1990 with corrections e improved calculations of Fe XVI VIIT d documentation of the code with Nieuwenhuijzen and of the physics e installment of SPEX at HEASARC NASA and availability to the commu
67. d above may be used 7 4 Using Log Files It is important to know that whenever log files are used to execute commands the menus will not be displayed when SPEX is run in terminal mode Various examples of log files can be found in chapter 2 of this manual and in document SRON SPEX TRCBOI 7 4 1 Error handling When SPEX encounters an error in a log file the program will return immediately to the log file executing the specific log file When the log file was executed from the interactive mode SPEX will return to the interactive mode In both situations SPEX will report an error in the log file and all consecutive commands will be disregarded SPEX returns to the menu that was called last by the log file When SPEX has executed a log file succesfully this will be reported too and SPEX will return to the menu that was called last by the log file Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX Loa FILE STRUCTURE PAGE 131 oF 131 Appendix A References Allen C W 1973 Astrophysical Quantities 3rd Ed Athlone Press London Anders E Grevesse N 1989 Geochimica et Cosmochimica Acta 53 197 Arnaud M Rothenflug R 1985 Astron Astrophys Suppl Ser 60 425 Arnaud M Raymond J C 1992 Astron Astrophys J 398 394 Band D L 1988 Astrophys J 332 842 Chevalier R A 1982 Astrophys J 258 790 Drake S A 1992 Plasma Emis
68. d in Fig 2 1 Each step will be discussed 1n a separate section of this chapter SPEX can be used in three modes a terminal mode a window mode and a log file mode The example session in this chapter is run in the terminal mode The same steps may be followed when running SPEX in the window mode At the end of this chapter a log file will be presented and discussed This log file follows the same steps taken in the example however automatically A log file is a series of previously recorded SPEX commands that can be executed by SPEX again To learn more about the log file structure see chapter 7 Note The SPEX menus and program output are displayed here in double lined boxes The keyboard entries since this example is run in terminal mode are denoted with single lined boxes in the texts commenting the SPEX menus and program output 2 2 Basic parameters At the command prompt type to start the program SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Plot menu Enter your choice LOG dist UsER s TUTORIAL MANUAL Document SRON SPEX Date Issue EXAMPLE S
69. d to design the windows version Nieuwenhuijzen contributed to the software design and Kaastra was responsible for the whole software implementation Eggenkamp Alkemade Stil Bartelds and van der Wolf helped in testing the software and contributed many new ideas The documentation has been prepared with starting help by Gunsing by van der Wolf and Nieuwenhuijzen for the manual structure and introduction by Mewe for the scientific background by Kaastra for the software description and by Mewe and Kaastra together for the description of models and instrument response functions The project supervision is in the hands of Mewe Kaastra and Nieuwenhuijzen Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL INTRODUCTION PAGE 10 or 131 User level User s Tutorial Manual SRON SPEX TRUM e Physical Background SRON SPEX TRPBO1 X Ray spectroscopy SRON SPEX TRPBO0O2 Ionization and energy balance in collisionally and photo ionized plasmas SRON SPEX TRPBO03 Continuum radiation processes SRON SPEX TRPBO04 Line excitation processes With appendices x SRON SPEX TRPB04a List of input line paramters x SRON SPEX TRPB04b Atlas of dielectronic recombination lines x SRON SPEX TRPB04e Atlas of innershell ionization lines SRON SPEX TRPBO065 Differential Emission Measure DEM analysis SRON SPEX TRPBO06 Active Region Loop modelling TBD by G H J van den Oord SR
70. ded into categories Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 67 OF 131 structure only structure with default settings Main menu option 1 titled m1 default Sub menu option 1 titled sm1 Sub sub menu option 1 1 titled ssm1 Sub sub sub menu option 1 1 1 Sub sub sub menu option 1 1 2 Sub sub menu option 1 2 titled ssm2 Sub sub sub menu option 1 2 1 Sub sub sub menu option 1 2 2 Sub menu option 2 Main menu option 2 Figure 3 3 Representation of the menu structure Both trees represent the same structure The right tree shows the menu titles in a and default options double boxed at program startup Menu titles and item names are listed in the index at the end of this manual BACK Back to previous menu MAIN Back to main menu EXE Set log file for reading your commands EE Unless the file name 1s changed SPEX will use the default file name at program startup spex or the last defined filename Change file name for reading your commands without com Open the file for reading your commands Back to previous menu MAIN Back to main menu Set log file for storing SPEX output Various types of output from SPEX may be stored into a file t program start all SPEX output will be stored if this option is selected EE Unless the file name 1s changed SPEX will use the default file name at program startup
71. dified first is entered to select the additive component 1 i e CIE SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the parameter for the current component new new new new new value of the parameter status of the parameter step for the parameter minimum for the parameter maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu Enter your choice PARA Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 29 oF 131 Comment is entered to select a parameter from the current component CIE Select a spectral parameter CIE model Description Normalisation ne nH V 1E64 m 3 Electron temperature keV Electron density 1E20 m 3 Ion temperature keV Micro turbulence velocity km s Abundance He Z 2 shortened Abundance Zn Z 30 Enter your choice NORM Comment norm is entered to select the normalization parameter SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the parameter for the current component Set new value of the parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fit
72. e PostScript print portrait mode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear Redefine x axis units Redefine y axis units Modify x axis range Modify y axis range Change font type Change font height Modify caption texts Change plot symbols Histogram continuous line plot mode Change line weights Change line styles Change plot colours Back to main menu Comment main is entered to return to the main menu SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Modify the current model parameters Evaluate the current spectral model Simulate a spectrum using current model amp detector Spectral fitting error search etc Output of SPEX model properties to ascii file or screen Plot menu Enter your choice FIT quit Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 59 oF 131 Comment is entered to exit the SPEX program Normal end of SPEX Run time statistics s slinsort layerstart ciescale addspec layerend setcon
73. e are merged with their neighbours resulting in a possibly lower S N ratio for that bin Low Specify lower limit rebin range Default at program startup is data channel 1 Specify upper limit rebin range Default at program startup is maximum available data channel in data set Specify mimimum number of bins to be taken together Default at program startup is 2 bins Specify mimimum signal to noise ratio per bin Default at program startup 1s 3 nEB Rebin the selected channel range Back to previous menu Back to main menu Multiply the response by a constant This option is useful in two situations One when spectral data from two instruments are to be combined and there is uncertainty in the absolute calibration of one of the instruments In this case the response matrix of one of the instruments may be adjusted by uniformly multiplying it with a constant The other situation occurs for off axis or extended sources observed with collimated instruments The multiplication factor may then be the collimator correction OPT Optimise the response and data for fitting purposes This option deletes all channels with zero data errors and all input energy grid bins with zero response During spectral fitting zero data errors will result in an endless loop with infinite y However it is better to rebin the spectrum first before optimizing it Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1
74. e distance in your selected units Show the current distance and unit Back to main menu Distance Distance Distance Distance Distance Distance in in in in in SPEX Version 1 00 SPEX distance unit menu Astronomical units light years pe kpc Mpc Cosmological redshift use HO 50 q0 0 5 Back to previous menu Back to main menu Enter your choice SPEX pc Comment The distance scale is taken here in units of parsec pc therefore is entered Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 15 oF 131 SPEX Version 1 00 SPEX distance menu Define the unit of your distance scale Enter the value of the distance in your selected units Show the current distance and unit Back to main menu Enter your choice DIST Enter the distance in your selected units 324078 29 4 Comment is entered to set the distance of the source in the selected unit SPEX will ask for a numerical value In this example is entered The source distance is now 29 4 pc SPEX Version 1 00 SPEX distance menu Define the unit of your distance scale Enter the value of the distance in your selected units Show the current distance and unit Back to main menu Enter your choice SHOW main Comment main is entered to return to the main menu SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for expe
75. e parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu Enter your choice VAL add comp 1 cie Ion temp keV type 3 1 Comment The value is modified by entering and the value i e 1 keV Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 33 OF 131 SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the parameter for the current component Set new value of the parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu Enter your choice VAL para Comment This multiplicative component only has one parameter the column density SPEX Version 1 00 Select a spectral parameter CIE model Description Normalisation ne nH V 1E64 m 3 Electron temperature keV Electron density 1E20 m 3 Ion temperature keV Micro turbulence velocity km s Abundance He Z 2 shortened Abundance Zn Z 30 Enter your choice NORM ed Comment The electron density is selected by entering Document SRON SPEX TRUM SRON SPEX D
76. e sure FORM TYPE and COMB are correct Save the current data set be sure FORM TYPE are correct Modify rebin or optimise the current data set Show the current data set Back to main menu Enter your choice SHOW read Comment is entered to read a new data set Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 20 oF 131 SPEX Version 1 00 SPEX data read menu Change file name containing the response matrix Change file name containing the spectrum Read the data set from named file Back to previous menu Back to main menu Enter your choice RIAM Give file name without res or ras extension iipeg3a SPEX Version 1 00 SPEX data read menu Change file name containing the response matrix Change file name containing the spectrum Read the data set from named file Back to previous menu Back to main menu Enter your choice SNAM Give file name without spo or spa extension spex iipeg3a SPEX Version 1 00 SPEX data read menu Change file name containing the response matrix Change file name containing the spectrum Read the data set from named file Back to previous menu Back to main menu Enter your choice READ Comment is entered to read the complete data set Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 21 oF 1
77. e that the spectrum is linear in the elemental abundances hence given the other model parameters the abundances can be determined using a simple matrix inversion This increases the fitting speed considerably b Differential emission measure DEM analysis is possible in SPEX it uses a completely different way of solution from the classical Levenberg Marquardt method otherwise used in spectral fitting In addition some general requirements such as modularity compact documentation transportability adaptability to various instruments and flexibility to include more or new atomic data have led us also to the restructuring of our software 1 2 Development of Spectral Codes at SRON 1 Mewe 1972 Paper I 1975 Paper II first approach to optically thin model a calculations of Collision Ionization Equilibrium CIE model 2 Mewe amp Gronenschild 1978 Paper IIT 1981 Paper IV a basic papers on continuum amp line emission with full description of parameters 3 Mewe J Schrijver amp Gronenschild 1974 1980 first non equilibrium calculations a development Non Equilibrium Ionization NEI model for solar flares 1974 b first application of NEI Sedov model to supernova remnants 1979 4 Mewe J Schrijver 1974 80 extended calculations on He like ions 5 Sylwester J Schrijver amp Mewe development of iterative DEM code 1979 6 Mewe Gronenschild amp van den Oord 1985 Paper V Mewe Lemen amp van den Oor
78. ectrum in the rest frame and then shifts all photons to the observers frame IF The energy grid should defined to be monotonically increasing in energy If an energy grid is calculated from an increasing wavelength grid the order of the wavelength grid must be reversed to obtain monotonically increasing values of the energy Linear energy grid The energy grid is defined by the lower and upper energy limits and either the step size or the number of energy bins O Set lower energy limit keV Set upper energy limit keV STEP Set step size keV Set number of bins R Make the energy grid BACK Back to previous menu MAIN Back to main menu Q az z v LOG Logarithmic energy grid The energy grid 1s defined by the lower and upper energy limits and either the step size or the number of energy bins Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 70 oF 131 LOW Set lower energy limit keV PP Set upper energy limit keV STEP Set log step size keV Set number of bins Make the energy grid BACK Back to previous menu MAIN Back to main menu Input an energy grid from a file NE Unless the file name 1s changed SPEX will use the default file name at program startup spex or the last defined filename Change file name of file with energy grid Read the file with the energy grid Back to previous menu MAIN Back to main me
79. een more than 5 free parameters in the current spectral model only the first five of these would be shown during the fitting procedure NOTE Due to improvements in the atomic physics used in SPEX minor differences may occur be tween the fits as presented in this manual and the fits that are made with your current implementation of SPEX Always check the version number that is used parameter with unit ne nH V 1E64 m 3 9 81741E 06 O0E 20 1 00E 20 Temperature keV 2 9125 00E 04 1 00E 03 El dens 1E20 m 3 1 00000E 04 00E 22 OOE 10 Ion temp keV 1 0000 0O0E 04 QOOE 07 Microturb vel km s 0 0 OOE 05 Abundance He 1 0000 OOE 10 OOE 10 Abundance Li 1 0000 00E 03 OOE 10 OOE 10 shortened 1 Abundance Zn 1 0000 00E 03 OOE 10 OOE 10 2 Column 1E28 m 2 1 22782E 05 1 00E 03 OOE 10 nr mod photon flux energy flux nr of photons luminosity phot m 2 s W m 2 photons s W 1 cie 100 36 1 73397E 14 1 05685E 39 1 80332E 23 Chi squared value 221 72 Degrees of freedom 227 Comment After the fitting procedure is completed SPEX displays the current values of the spectral model parameters Notation mod denotes the model components to which a specific parameter belongs nr denotes the parameter number of the model component t is a model specific parameter that defines the type of the parameter t ranges from 0 to 3 0 normalization parameter 1 abundance parameter Document SRON SPEX TRUM SR
80. eleion ionis2 augdis cheion cherec recomb cestart ionrec3 ioncon elhden cedec gauntff brems CONOONCTOROHOONO CO SO EST Ww w freebound twofot conem linem linsort linspe totspec SPEX total Comment At the end of the program SPEX shows for each routine how much processing time it used In some implementations of SPEX this option may not yet function However it does work on a SUN workstation SPEX will also show the number of errors that occured during the input of the commands 2 9 Using a log file SPEX provides an option to record and play back SPEX commands using so called log files These log files are especially useful to be used as macros to do routine jobs such as setting models reading data etc A log file is an ASCII file and may be edited with any ASCII editor In this way useful sets of SPEX commands may be precompiled For more information about the SPEX log file strucure see chapter 7 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 60 oF 131 All SPEX commands used to generate the example SPEX session in the previous sections are recorded in the file iipegfit3a com The contents of the log file are displayed below HHHHHHHHHHHHHHHHHHHHHR RRR R RE ERE RRR ERE RETENIR E IE E RRR RR RR RRR RE Title SRON SPEX TRUM example log file File lipegfit3a com Date September 12 1994
81. ent s of ISM Density gradient n of stellar ejecta aura Alpha parameter of Hamilton Nu parameter of Hamilton Angular filling factor 4 Pre shock electron temperature keV E Number of shells E Number of projected rings emin Minimum energy keV of radial profile semax Maximum energy keV of radial profile RMIN Minimum radius for projected spectrum annulus rmax Maximum radius for projected spectrum annulus Abundance of element ranging from 02 to 30 Z 2 to 30 SNR model Solinger et al isothermal xonM Normalisation 1079 m z z gel z z BHEHBBB li i i i e o Ne n Electron temperature keV a Z H Ionisation parameter 107 s m d Ion temperature keV vmic Micro turbulence velocity km s Density gradient s of ISM Density gradient n of stellar ejecta GAMM Adiabatic index ny Angular filling factor Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 83 oF 131 pt Pre shock electron temperature keV Number of shells Uu zZ a Number of projected rings zwi Minimum energy keV of radial profile semax Maximum energy keV of radial profile nMIN Minimum radius for projected spectrum annulus rmax Maximum radius for projected spectrum annulus Abundance of element ranging from 02 to 30 7 2 to 30 SNR model Band isother
82. equential formatted files The file content is the same as that of the binary files first a header then the data For readability the data are written in the following designated order Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 121 or 131 integer 4 nbmax nemax ncmax nrespmax ndetedgmax parameter nbmax 2048 nemax 8192 ncmax 32768 nrespmax 524288 ndetedgmax 64 integer 4 nchan neg real 4 echani nbmax echan2 nbmax eg1 nemax eg2 nemax integer 2 kresp 3 ncmax real 4 resp nrespmax edetedg ndetedgmax open unit 10 file dummy res status unknown access sequential form unformatted write 10 C This is the first header comment line write 10 C You are allowe to have 0 comment lines in SPEX 10 C But always end the header with a line starting with SPEX 10 C This is the last header comment line 10 SPEX 10 nchan 10 Cechani i i 1 nchan 10 Cechan2 i i 1 nchan 10 neg 10 Ceg1 i i 1 neg 10 eg2 1 i 1 neg 10 nkresp 10 Ckresp j i j 1 3 i 1 nkresp 10 nresp 10 resp i i 1 nresp 10 ndetedg if ndetedg gt 0 write 10 edetedg i i 1 ndetedg close unit 10 status keep end Figure 6 3 Example Fortran program to create binary response matrices that are readable for SPEX Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Vers
83. eration steps are displayed It is advised to check them because sometimes the fit at a trial parameter converges to a different solution branch therefore creating a discontinuous jump in x In those situations it is better to find the error bounds by using the step option or by varying the search parameter by hand Select the spectral component for error search a Additive component Ranging from 01 to 16 Multiplicative component Ranging from 01 to 08 Select the parameter for the current component See 3 3 under Set level of Ax for the errors The default value is 2 This is lo for one parameter of interest For other values see tab 3 5 Determine the errors SPEX calculates the positive and negative error bounds separately BACK Back to previous menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 91 oF 131 Table 3 5 Ax as a function of confidence level and degrees of freedom is the number of parameters of interest for which the confidence level is calculated simultaneously in general less than the number of free parameters p is the probability of the confidence level In case of doubt take 1 parameter of interest parameters of interest p 1 2 3 4 5 6 Ic 2 00 4 00 6 00 8 00 10 00 12 00 68 3 1 00 2 30 3 53 4 72 5 89 7 04 90 2 71 461 6 25 7 78 9 24 10 6 95 4 4 00 6 17 8 02 9 70 113 12 8 99 6 63 9
84. etical reference spectra calculated in CIE The DEM result generally does not reflect the true temperature distribution in the case of a SNR but gives only an indication of the temperature regime In the past we have applied several DEM modelling techniques e g in solar flare analysis in the analysis of EXOSAT transmission grating spectra of the coronae of several cool stars e g Lemen et al 1989 and very recently to the analysis of the EUVE spectra of a number of late type stars Mewe et al 1994 In the document SRON SPEX TRPBO05 we have described the modelling methods as applied in SPEX SNR model SuperNova Remnant optically thin multi temperature structure transient state The situation is prototype for a strongly NEI plasma See PB01 and more specific for the various plasma models Kaastra and Jansen 1993 We distinguish between the following SNR models e Sedov adiabatic model Sedov 1959 e Chevalier adiabatic reverse shock model Chevalier 1982 e Hamilton adiabatic reverse shock clumps model Hamilton 1985 e Solinger et al isothermal model Solinger et al 1975 e Band isothermal or isentropic reverse shock model Band 1988 The Sedov and Solinger models describe only the outward blast shock wave ploughing through the interstellar matter whereas the other models also take into account the inner reverse shock through the clumpy material from the remnant itself M BB Modified Black Body spectrum e
85. fferential emission measure analysis MBB Modified black body spectrum MBB GAUS Gaussian line Black body spectrum BACK Back to previous menu Define a multiplicative or redshift component See chapter 4 for specific information about the model components tw w IF The newly defined component will be appended to the already existing one s A maxi mum number of 8 multiplicative components is permitted Redshift component Absorption component Morrison amp McCammon Absorption component EUVE Absorption component hot CIE medium BACK Back to previous menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 79 oF 131 Table 3 2 Output of the SPEX show model option Number of multiplicative components Nr 01 multiplicative component name Nr multiplicative component name Number of additive components Nr 01 additive component name Nr additive component name Delete an additive component NE After a component has been deleted the remaining components will be renumbered Delete component Ranging from 01 to 16 Back to previous menu DMUL Delete a multiplicative or redshift component NE After a component has been deleted the remaining components will be renumbered Delete component Ranging from 01 to 08 BACK Back to previous menu REL Set relation additive amp multiplicative
86. g from the region around an AGN optically thick single temperature The BB spectrum is described by the Planck function whereas the MBB spectrum is modified by inverse Compton scattering by nonrelativistic electrons in a dense medium e g Rybicki and Lightman 1979 see also PBOI Active Region Loop model Optically thin multi temperature stationary plasma in coronal loop structures In the past we have used the results from Vesecky et al 1979 and Rosner et al 1978 see PB01 but in the future we will make use of the recent calculations by G H J van den Oord At the moment the model in SPEX is still TBD and will be described in document SRON SPEX TRPBO06 Hot high gravity LTE atmosphere model Optically thick atmosphere with temperature stratification in Local Thermal Equilibrium with irradiation by an external radiation field white dwarfs accretion disks This model has been developed by J Heise see also PBOI sec 6 5 1 Heise et al during the past years and will be implemented later At the moment the model in SPEX is still TBD and will be described in document SRON SPEX TRPBO07 Photo ionized model Nebular type plasma with ionization dominated by an external radia tion field accretion disks in X ray binaries The ionization balance is set up between photo ionization instead of electron impact ionization and radiative recombination The model is currently under development by J S Kaastra for some prelimina
87. h a spectrum that combines a power law a modified blackbody a CIE plasma and a Gaussian spectral emission line Moreover in addition to the foreground absorption a warm absorber is introduced It is our purpose to continuously extend and update the cookbook and we encourage every user to supply us with more examples Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL INSTRUMENTAL RESPONSE FILES PAGE 114 or 131 Chapter 5 Instrumental Response Files amp Spectral Simulations 5 1 Introduction To make spectral calculations representative for several instruments we need the response function matrix of a given instrument as an input in SPEX The response function is given in the form of a binary response file res which defines the energy grid of the instrument its spectral resolution and the effective area The binary spectrum spo file contains a dummy spectrum with a given exposure time and a background determined from a certain area box on the detector surface outside the region of the spectrum Both the size of the background area and the exposure time can be changed during the session See chapter 6 for more information about SPEX file formats 5 2 Instruments At the moment res and spo files are available for the following instruments e 1 EUVE e 2 AXAF e 3 XMM e 4 SAX e 5 ASCA e 6 The files are prepared in a fixed standard format and fo
88. have been displayed Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 22 oF 131 SPEX Version 1 00 SPEX data menu Set the format of the data files binary or ascii Type of data to be read or written res spo or res amp spo How are the new data to be combined with the old data Read new data set be sure FORM TYPE and COMB are correct Save the current data set be sure FORM TYPE are correct Modify rebin or optimise the current data set Show the current data set Back to main menu Enter your choice SHOW main Comment main is entered to return to the main menu 2 4 Spectral model SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Plot menu Enter your choice MOD Comment is entered to specify the spectral model Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 23 OF 131 SPEX Version 1 00 SPEX model menu Define an additive component Show the current model Back to main me
89. he raw source spectrum IE SPEX always saves the expected background contribution in the source region not randomized to the spectral file if the simulated spectrum is saved This in order to enable further simulations using the currently simulated spectrum as a template IE It may occur that the spectrum used as a template for spectral simulation consists of data from more than one instrument In that case SPEX can simulate a new spectrum provided that 1 The integration times for all instruments are the same 2 The systematic errors should be the same for all instruments 3 The ratio of source to background area will not be changed In all other cases the instrument spectra should be simulated individually before being added together SUB Subtract background yes or no SPEX always uses background substracted spectra However if raw spectra background in cluded are to be simulated SPEX offers a possibility to simulate them here These spectra are not to be fitted with SPEX Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 88 oF 131 Default at program startup Is yes AREA Set ratio source to background area If this ratio is very small the background can be determined very accurately However note that for most instruments very large background areas may introduce systematic errors in the background estimate for the
90. he number of channels in the data set and nq is the number of temperature components AUTO Automatic search for optimum regularisation amp DEM analysis This option automatically chooses the optimal regularisation parameter using eq 3 2 and performs the DEM analysis Usually this procedure is satisfactory Sometimes the result is not satisfactory and manual regularisation should be used followed by CHIR Make a list of y versus regularisation parameter Set lower value for regularisation UPP Set upper value for regularisation Set number of steps for regularisation neg for log steps For example grid grid type input TETAS LOTT LS dies 6 TETAS IOP SZ OTIS logarithmic 8 RUN Make a list of x versus regularisation parameter g For each selected regularisation parameter SPEX lists the y value and the DEM penalty p which is defined by i 3 3 yico NOH where y is the emission measure of temperature bin 7 and Ay it s error For a physical acceptable solution p should not be much larger than half the number of temperature bins BACK Back to previous menu MAIN Back to main menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 94 oF 131 Read a model DEM distribution and evaluate that model SPEX asks for a filename without the extension dem SAVE Save the DEM distribution to an ascii file SPEX
91. her ions to the total effective gaunt factor are usually small SPEX uses this by neglecting contributions from energy levels from ions that contribute less than a relative factor gacc to the total free bound Gaunt factor Default value is gace 107 The user may change this level for very accurate calculations or alternatively for very fast rough calculations Note however that computation time increases very rapidly with increasing accuracy level The current default represents a fair compromise between computational speed and accuracy DEF Use default value 1E 3 for solar abundances ser Set your own accuracy Back to previous menu Back to main menu LINE Change line emission properties To investigate the influence of specific plasma emission processes SPEX offers the possibility to switch them on or off This is for testing purposes only make sure that all options are set when calculating realistic spectra Include Include Include Ds Include not collisional excitation not radiative recombination not dielectronic recombination main line not dielectronic recombination satellites Include not inner shell ionisation Combine not all line contributions into single line BACK Back to previous menu MAIN Back to main menu Select line broadening mechanism NE The ion temperature and micro turbulence can be set by changing the spectral model parameters No line broadening Thermal
92. ion 1 06 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 122 or 131 e HEADER A header consists of a number of header lines with a maximum of 256 characters per line The FIRST character of a header line MUST always be a c or a C The rest of the headerline is arbitrary and may be used to provide the binary data file with relevant information about the data set it self for example The information in the header lines will be ignored by SPEX The header MUST be closed by a line containing the following string SPEX spex or Spex This indicates to SPEX that the header is finished and the following fields contain spectral data e NCHAN integer 4 the number of output data channels Should be smaller than or equal to NBMAX NBMAX is currently set at 2048 e lines containing the following information I ECHAN I ECHAN2 I where I ranges from 1 to NEG ECHANI I and ECHAN2 I are described in 86 3 1 NOTE When SPEX reads an ASCII response matrix I is considered as a dummy variable Therefore it is important that the sequence in which the data are written originally is correct Whenever a response matrix is written in ASCII format from within the SPEX program SPEX will of course use the correct value of 1 e NEG integer 4 the number of bins for the energy grid on which the spectrum is represented e lines containing the following information I EG1 1 Ea2 1 where I ranges from 1 to NCHAN EGI I and EG2 I are described in
93. lanced by radiative and dielectronic recombination of an electron with an ion The electron impact excitation of an 1on or atom 1s generally followed by a spontaneous radiative transition between either two bound states between two continuum states or between a continuum and a bound state The first process produces line radiation the latter two ones produce free free and free bound continuum radiation See also SRON SPEX TRPBO01 and references therein For line excita tion processes see SRON SPEX TRPBO04 and appendices 04a c for continuum radiation see SRON SPEX TRPBO03 for the ionization balance and processes see SRON SPEX TRPBO2 5 NEI model Discontinuous temperature jump causing Non Equilibrium Ionization transient optically thin plasmas such as solar flares and supernova remnants The heating process e g by a shock yields a temperature rise so fast that the ionization cannot follow this As a result the ionization balance in the X ray emitting plasma is generally far out of equilibrium The same holds for cooling vs recombination See documents SRON SPEX TRPBO1 amp 02 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MODELS PAGE 112 oF 131 6 10 11 DEM model Multi temperature optically thin plasma such as a stellar corona in steady state or a supernova remnant SNR in transient state The Diffferential Emission Measure DEM modelling uses theor
94. ld e g X ray binaries AGNs The ionization balance is set up between photo ionization and radiative recombination J S Kaastra Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL INTRODUCTION PAGE 9 or 131 1 5 SPEX Document structure The SPEX documentation is available in two levels a user level and a program level The user level see Fig 1 1 provides all the information needed to install and run the SPEX program and includes a description of the physical background associated with the software package It also provides information about the instrumental response of several X ray observing satellite instruments and a cookbook with tips and tricks for experienced users The program level see Fig 1 2 contains information about the software architecture and detailed descriptions of subroutines used by the SPEX program It also explains how to install SPEX on your own system and what soft and hardware requirements are to be met A novice user is advised to read this manual and the physical background A sample session in chapter 3 shows the scope of the SPEX environment Experienced users are encouraged to go through the other manuals and send suggestions of improvement to the addresses listed below 1 6 Acknowledgements We would like to express our special thanks to numerous people who have substantially contributed to the development of the work on X ray spectral model
95. lect the Hydrogen column density SPEX Version 1 00 Search errors of spectral parameters Description Select the spectral component for error search Select the parameter for the current component Set level of Delta chi 2 for the errors Determine the errors Back to previous menu Back to main menu Enter your choice RUN Comment is entered to start the determination of the error bounds of the Hydrogen column density parameter from the ABSM model component Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 53 oF 131 Trial parameter Chi 2 Delta parameter Delta Chi 2 1 20273E 05 17763E 05 12744E 05 027T06E 05 26294E 06 247T65E 06 1 1 1 1 8 4 c4 Muss NN H BBHBHBHBmHG 21528E 05 0 24037E 05 25292kE 05 27801E 05 32821E 05 42859E 05 62935E 05 03088E 05 83394E 05 44006E 05 65229E 05 44006E 05 03866E 05 5 23236E 05 Parameter 221 72 25478E 07 0 00 221 72 50956E 07 00 221 72 01911E 07 00 221 72 00382E 06 00 221 72 00765E 06 00 221 74 01529E 06 02 221 80 03058E 06 08 221 90 22782bE 05 18 221 72 25478E 07 00 221 72 50956E 07 00 221 72 01911E 07 00 221 72 00382E 06 00 221 73 00765E 06 01 221 74 01529E 06 02 221 81 03058E 06 09 222 06 60612E 05 34 223 03 21223E 05 31 226 75 4244TE 05 03 223 03 21223E 05 31 223 54 81083E 05 82 223 73 00454E
96. ling in chronological order J Schrijver E H B M Gronenschild J Sylwester A Fludra G H J van den Oord J R Lemen F A Jansen R J C Smeets C J Schrijver F J M Alkemade C J Th Gunsing D Verner J Stil I Eggenkamp E Philippus and G J Bartelds During the years the many people have contributed as follows The philosophy of the fitting procedure is based on the experiences obtained with the fitting of EXOSAT data especially on the software package ERRFIT designed by Jansen and Kaastra The non equilibrium ionization balance routine was developed by Jansen based on earlier work by J Schrijver 1974 and Gronenschild 1981 The SNR models are based on the work by Kaastra and Jansen 1992 The Hamilton SNR model is programmed by Stil The line and continuum emission routines were written by Kaastra based on previous routines by Mewe Gronenschild van den Oord and Lemen 1981 1986 Lemen Smeets and Alkemade developed an earlier version 1986 1990 of a spectrum synthesis program The original DEM modelling was based on the work by Sylwester and Fludra 1980 while the current DEM algorithm has been designed by C J Schrijver and Alkemade The line and continuum emission data are completely based on the work by Mewe and Kaastra The photo ionization cross sections have been calculated by Verner and implemented by Kaastra The complete menu structure is written by Kaastra with advice from Nieuwenhuijzen while Philippus helpe
97. mal or isentropic reverse shock w H xonM Normalisation 10 m Electron temperature keV Ionisation parameter 107 s m Ion temperature keV vmic Micro turbulence velocity km s Density gradient s of ISM ti Density gradient n of stellar ejecta GAMM Adiabatic index Angular filling factor 4 Pre shock electron temperature keV s Number of shells n Number of projected rings emin Minimum energy keV of radial profile semax Maximum energy keV of radial profile RMIN Minimum radius for projected spectrum annulus rmax Maximum radius for projected spectrum annulus Abundance of element ranging from 02 to 30 Z 2 to 30 DEM model differential emission measure analysis Lower electron temperature keV 4 y tt a Z d Upper electron temperature keV Number of temperature bins d Ion temperature keV vmic Micro turbulence velocity km s Electron density 107 m Abundance of element ranging from 02 to 30 Z 2 to 30 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 84 oF 131 Modified black body spectrum MBB Normalisation 107 m 5 Temperature keV Gaussian line Normalisation 10 photons s Line energy keV Line width FWHM keV Black body spectrum BB Normalisation 10 m Temperature keV Redshift component Redshift Abs
98. max echan2 nbmax eg1 nemax eg2 nemax integer 2 kresp 3 ncmax real 4 resp nrespmax edetedg ndetedgmax open unit 10 file dummy ras status unknown access sequential form formatted write 10 a C This is the first header comment line write 10 a C This is the last header comment line write 10 a SPEX write 10 nchan do i 1 nchan write 10 i15 2 1pg14 6 i echani i echan2 i enddo write 10 neg do i 1 neg write 10 i5 2 1pg14 6 i egi i eg2 i enddo write 10 nkresp nresp ki k2 do i 1 nkresp write 10 315 kresp j i j 1 3 k2 k2 kresp 1 i 1 write 10 5 1ipg14 6 resp j j k1 k2 k2 k2 1 ki k2 enddo write 10 i5 ndetedg if ndetedg gt 0 write 10 5 1pg14 6 edetedg i i 1 ndetedg close unit 10 status keep end Figure 6 4 Example Fortran program to create ASCII response matrices that are readable for SPEX Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 124 or 131 6 3 3 Useful software The example Fortran routine in Fig 6 5 may be useful to convert a square SPEX matrix into a compressed form In this example not only zero or negative response values are left out but also response values that are negligably small smaller than a user defined variable RLIM 6 4 Energy g
99. n menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 40 oF 131 2 7 Plot of observed and fitted data SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Modify the current model parameters Evaluate the current spectral model Simulate a spectrum using current model amp detector Spectral fitting error search etc Output of SPEX model properties to ascii file or screen Plot menu Enter your choice DIST plot Comment is entered to go to the plot menu to make a plot of the observed and fitted data Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 41 oF 131 SPEX Version 1 00 SPEX plot menu Select a new plot type Do the plot Set plotting device Set plot file name PostScript print landscape mode PostScript print portrait mode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear Redefine x axis units Redefine y axis units Modify x axis range M
100. name containing the spectrum Read the data set from named file Back to previous menu MAIN Back to main menu Save the current data set be sure FORM amp TYPE are correct NE Unless the file name 1s changed SPEX will use the default file name at program startup spex or the last defined filename RNAM Change file name containing the response matrix Change file name containing the spectrum Save the data set to named file Back to previous menu MAIN Back to main menu Modify rebin or optimise the current data set Delete specified data channels For example badly calibrated channels or channels that do not have sufficient flux infor mation can be deleted If only a certain part of the spectrum should be fitted this option can also be used The channels will be deleted from both the spectrum and the response matrix Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 75 oF 131 After deleting certain channels all channels above the deleted range have different 8 channel numbers Therefore if more ranges are to be deleted one is strongly advised to delete the highest channels first IE One can choose to delete either channel ranges or energy ranges When channels are deleted by energy the energy centroid of the channel determines if a channel will be deleted or not Delete by channel or energy Switch between deletion of chan
101. nce of output channels for which the response matrix is positive at a given input energy e KRESP 3 NCMAX integer 2 array The second argument corresponds to the response group number For each response group this array contains the following 3 quantities stored as integer 2 1 The number of non zero response elements of this group 2 The input energy bin number corresponding to this group 3 The output channel number for the first element of this group e NRESP integer 4 the number of non zero response matrix elements e RESP NRESPMAX real 4 array the response matrix elements Note that any effective area is already included in the response value the RESP value represents the expected number of counts s in a certain output energy channel for 1 photon s in the original energy bin Although the response matrix is 2 dimensional the array RESP is 1 dimensional and it contains compressed information only non zero response matrix elements are stored indexing takes place via the array KRESP e NDETEDG integer 4 the number of edges in the effective area of the instruments Only if NDETEDG gt 0 then follows e EDETEDG NDETEDGMAX real 4 array the edges in keV in the effective area of the instru ment Needed for interpolations of the effective area An example Fortran routine to write binary response matrices is presented in Fig 6 3 6 3 2 Writing response matrices in ASCII format ras ASCII files are opened as s
102. nel ranges or energy ranges Default at program startup is channel Low Specify lower limit delete range Default at program startup is data channel 1 Specify upper limit delete range Default at program startup is maximum available data channel in data set Add data between lower and upper range to delete selection Delete the selected range s Back to previous menu Back to main menu Rebin specific data channels Especially in situations with low statistics per channel e g less than 10 counts per channel it is advised to rebin the data set in order to create channels with sufficient statistics IE After rebinning specific channels all channels above the rebinned range have differ ent channel numbers Therefore if more ranges are to be rebinned one is strongly advised to rebin the highest channels first IE The number of channels that are to be rebinned should be a multiple of the number of channels that are to be taken together Example the lower channel limit is 100 and the upper is 199 the number of channels to be taken together is 25 After rebinning there will be 4 bins each containing 25 original channels If the upper channel limit would have been 201 rebinning would result into 4 bins containing 25 original channels and one last bin containing 2 original channels Low Specify lower limit rebin range Default at program startup 1s data channel 1 Specify upper limit rebin range Default at program startup 1
103. nity 1995 to be agreed 1 8 Spectral components available in SPEX 1 CIE model Optically thin steady state plasma in Collisional Ionization Equilibrium Ioniza tion amp excitation occur by electron impact Ionization is balanced by radiative amp dielectronic recombination 2 NEI model Discontinuous temperature jump causing Non Equilibrium Ionization transient optically thin plasmas like SNR and stellar flare Heating process yields temperature rise so fast that the ionization cannot follow this so that ionization balance is far out of equilibrium 3 SNR models SuperNova Remnant optically thin multi temp structure transient state Prototype of a strongly NEI plasma We distinguish between the following models a Sedov 1959 adiabatic model b Chevalier 1982 adiabatic plus reverse shock model Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL INTRODUCTION PAGE 8 or 131 10 11 12 13 1 4 c Hamilton 1985 adiabatic plus reverse shock clumps model d Solinger et al 1975 isothermal model e Band 1988 isothermal or isentropic plus reverse shock model DEM model differential emission measure DEM distribution of a multi temperature opti cally thin plasma such as a stellar corona or a cluster of galaxies in a steady state In addition the following simple models are available Delta function infinitely narrow
104. nu DATA Input the grid of a response matrix NE Unless the file name 1s changed SPEX will use the default file name at program startup spex or the last defined filename Change file name of response matrix with energy grid Read the file with the energy grid Back to previous menu MAIN Back to main menu SAVE Save the current energy grid to a file EE Unless the file name 1s changed SPEX will use the default file name at program startup spex or the last defined filename Change file name of file for energy grid Save the energy grid to the file Back to previous menu MAIN Back to main menu Q S w MAIN Back to main menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 71 oF 131 ELIM Set the energy limits for flux calculations It is possible to define an energy range for which fluxes and luminosities are calculated each time SPEX evaluates the current spectral model The default energy range at program startup is 2 10 keV LOW Set lower energy limit keV Set upper energy limit keV MAIN Back to main menu Define default abundances and line properties etc Several basic settings of the plasma models may be adjusted Novice users are discouraged to change the settings until they have gained enough experience with SPEX ABUN Set the standard set of abundances In SPEX the plasma emission is calcul
105. nu SPEX Version 1 00 Define an additive component Description Simple power law Delta line Collisional ionisation equilibrium model NEI model discontinuous temperature jump SNR model Sedov adiabatic SNR model Chevalier adiabatic reverse shock SNR model Hamilton adiabatic reverse shock clumps SIR model Solinger et al isothermal SNR model Band isothermal or isentropic reverse shock DEM model differential emission measure analysis Modified black body spectrum MBB Gaussian line Black body spectrum BACK to previous menu Enter your choice POW cie You have defined 1 additive components Comment SPEX shows the list of available additive model components See chapter 4 of this manual and SRON SPEX TRCBOI for more information about the spectral model components This example will use the collisional ionization equilibrium model therefore is entered SPEX shows the number of additive components that are currently defined Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 24 oF 131 SPEX Version 1 00 Define an additive component Description Simple power law Delta line Collisional ionisation equilibrium model NEI model discontinuous temperature jump SNR model Sedov adiabatic SNR model Chevalier adiabatic reverse shock SNR model Hamilton adiabatic reverse shock clumps SIR model Solinger et
106. ode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear Redefine x axis units Redefine y axis units Modify x axis range Modify y axis range Change font type Change font height Modify caption texts Change plot symbols Histogram continuous line plot mode Change line weights Change line styles Change plot colours Back to main menu Enter your choice PLOT main Comment main is entered to return to the main menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 50 oF 131 2 8 Accuracy of the fitted parameters SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Modify the current model parameters Evaluate the current spectral model Simulate a spectrum using current model amp detector Spectral fitting error search etc Output of SPEX model properties to ascii file or screen Plot menu SPEX Version 1 00 SPEX fit menu change the spectral fitting method fit the parameters using current data amp model determine error bounds on
107. odify y axis range Change font type Change font height Modify caption texts Change plot symbols Histogram continuous line plot mode Change line weights Change line styles Change plot colours Back to main menu Enter your choice PLOT dev Comment is selected to define the plotting device Note that the default plotting device at program startup Is the null device i e there will be no output SPEX Version 1 00 Set plot device Null device no output PostScript file landscape orientation PostScript file portrait orientation Colour PostScript file landscape orientation Colour PostScript file portrait orientation XTERM Tek terminal emulator Window on Xwindow server Pgdisp or figdisp server Enter your choice XWIN ps Comment Various plotting devices are available In this example the plotting device will be a PostScript file with landscape orientation thus is entered Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 42 oF 131 SPEX Version 1 00 SPEX plot menu Select a new plot type Do the plot Set plotting device Set plot file name PostScript print landscape mode PostScript print portrait mode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear Redefine x axis units Redefine y axis units Modify x axis range Modify y axis range Change font type Change
108. of a header line MUST always be a c or a C The rest of the headerline is arbitrary and may be used to provide the binary data file with relevant information about the data set it self for example The information in the header lines will be ignored by SPEX The header MUST be closed by a line containing the following string SPEX spex or Spex This indicates to SPEX that the header is finished and the following fields contain spectral data e NCHAN integer 4 the number of output data channels Should be smaller than or equal to NBMAX NBMAX is currently set at 2048 e lines containing the following information I TINTS I OCHAN I DOCHAN I BCHAN I FCHAN I where I ranges from 1 to NCHAN The definition of the other data fields can be found in 86 2 1 NOTE When SPEX reads an ASCII spectral data file 1 1s considered as a dummy variable Therefore it is important that the sequence in which the data are written originally is correct Whenever a spectral data set 1s written in ASCII format from within the SPEX program SPEX will of course use the correct value of 1 An example Fortran routine to write ASCII spectral data files is presented in Fig 6 2 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 118 or 131 integer 4 nbmax parameter nbmax 2048 integer 4 nchan real 4 tints nbmax ochan nbmax dochan nbmax bchan nbmax chan nbm
109. of the data set generated by SPEX Example plot with SPEX Version 1 0 modified single error bar with plot symbol 21 o continuous line plot mode for model 2 i e bold face 2 i e bold face E3 Figure 3 4 Example plot with SPEX Version 1 0 PostScript landscape orientation The plot character istics that were changed from the default values at program startup are also shown Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 98 oF 131 Tektronix 4010 terminal GraphOn Tek terminal emulator Retrographics VT640 Tek emulator XTERM Tek terminal emulator Window on Xwindow server Pgdisp or figdisp server X11 X11 NAME Set plot file name EE This option need only to be selected in case a hardcopy device is used e g PostScript SPEX will ask for a file name PostScript print landscape mode PostScript print portrait mode Change x axis scale scale logarithmic linear Change y axis scale scale logarithmic linear Change z axis scale scale logarithmic linear Redefine x axis units When is DATA MOD AREA CHI2 SPEC Bin nr Energy keV Energy Rydberg Frequency Hz Wavelength Wavelength nm SRON SPEX UsER s TUTORIAL MANUAL Document Date Issue SPEX MENU STRUCTURE SRON SPEX TRUM April 24 1995 Version 1 06 PAGE 99 oF 131 Wavelength m When is RESP Channel nr When s
110. orption component Morrison amp McCammon Hydrogen column density 1025 m 1024 cm Absorption component EUVE Hydrogen column density 1025 m 1024 cm He I HI ratio 59 He II HI ratio Absorption component hot CIE medium Hydrogen column density 1075 m 10 cm Electron temperature keV Abundance of element ranging from 02 to 30 Z 2 to 30 TYPE Select the type value status step min max With this option the properties of a spectral model parameter may be modified VAL Value of the parameter The value of the parameter may be changed Only values between the minimum and maximum values are accepted Status of the parameter The status of the parameter may be changed 0 indicates a frozen parameter that will not change during a fitting procedure 1 indicates a free parameter that may be changed during a fitting procedure Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 85 oF 131 Step for the parameter The stepsize used for determining the derivative of the model spectrum with respect to the parameter may be changed This may be helpfull when convergence problems occur Minimum for the parameter Maximum for the parameter Coupling of the parameter to another parameter During spectral fitting a parameter p may be coupled to another parameter p maintaining always p cijp with cj the c
111. oupling constant regardless of what p will be A value of 0 indicates a parameter that does not depend upon other parameters positive value indicates the label j of the parameter to which p is coupled This label is the unique number indicated in the first column with header par that is displayed if the parameters are shown option SHOW of this menu The coupling constant is by default 1 unless another value is chosen using the XSET option of this menu Coupling constant of the parameter to another parameter This option allows to modify the coupling constant between coupled parameters see above BACK Back to previous menu MAIN Back to main menu var Set new values for the current parameter SHOW Show the current parameters The output of this option 1s shown in tab 3 3 RCOR Show the correlations between the fitted parameters The output of this option 1s shown in tab 3 4 MAIN Back to main menu 3 5 Evaluation CALC Evaluate the current spectral model The currently defined spectral model is evaluated If a spectral data set is present the spectral model is convolved with the response matrix and the x is evaluated 3 6 Simulation Simulate a spectrum using current model amp detector Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 86 oF 131 Table 3 3 Output of the SPEX option show current paramete
112. pectral model type is DEM Temperature keV Temperature K Temperature MK Redefine y axis units When is DATA BIN Bin nr o Counts g Counts s Counts s keV Q SH lt RYD Counts s Ryd Counts s Hz d Counts s Counts s nm Counts s m Counts m s FKEV Counts m s keV FRYD Counts m s Ryd Counts m s Hz FANG Counts m s A FNM Counts m s nm M Counts m s m When is MOD H Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE Pace 100 oF 131 BIN Bin nr o Photons m s bin Q g KEV Photons m s keV RYD Photons m s Ryd HZ Photons m s Hz NG Photons m s A N Photons m s nm Photons m s m FWK Flux W m keV Flux W m2 Hz W m A W m2 nm Flux FWNM Flux Flux Jy IW vF W m w ll3 gt EERE HE N 1 vF JyHz When is AREA Bin nr M2 Area m Area cm When is RESP BIN Energy bin nr When is CHI2 DCHI Ax obs mod err c Counts s KEV Counts s keV RYD Counts s Ryd H Counts s Hz ANG Counts s Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 101 oF 131 Counts s nm Counts s m When is SPEC BIN Bin nr Emission 10 Photons s bin Emission 10 Photons s keV YD Emission 10 Photons s
113. plete restructuring of the plasma part of our code and calculation of complex models such as supernova remnants SNRs multilayer non equilibrium ionization stellar coronae DEM analysis photo ionized plasmas etc as compared to only equilibrium plasmas in the code implemented late 1992 in XSPEC version 8 23 under the name MEKA Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL INTRODUCTION PAGE 6 or 131 2 Display a In addition to the display output or plot of the total spectrum we are also interested in some other properties radial brightness profile 10n concentrations line identifications hydrodynamical properties plasma rates etc 3 Response matrices a If the response matrix for a given instrument has insufficient energy resolution to disentangle line features it is necessary to choose another energy grid and to rebin the response matrix to the chosen grid important e g for AXAF and XMM b More freedom in combining observations from different instruments e g adding spectra channel by channel and rebinning the data 4 Fitting a CPU intensive models like those for supernova remnants require a lot of model evaluations for one iteration step if the classical Levenberg Marquardt method is applied at least where many abundances have to be determined simultaneously We have reduced the number of model evaluations by making use of the principl
114. r each instrument a README file is available With special programs we convert e g FITS formatted files available from instrumental groups into SPEX readable files res and spo In the case of the EUVE spectrometers where we do analyses on real data we use the program EUVESPEX and also SPEX to generate specific res and spo files from the data of each individual observation In the documents SRON SPEX TRIS01 05 we describe shortly the parameters of the instruments mentioned above such as spectral resolution effective area and background In the future more instruments can be added e g EINSTEIN EXOSAT ROSAT scanners of EUVE Spectrum X y etc SRON SPEX Dae Ur Apri 24 1008 Issue Version 1 06 UsER s TUTORIAL MANUAL INSTRUMENTAL RESPONSE FILES PAGE 115 or 131 5 3 Spectral simulations With SPEX spectra can be generated using the instrumental files for several plasma models includ ing statistical photon noise and background Examples of various spectral simulations and analysis methods are given in the Cookbook technical report SRON SPEX TRCBO01 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 116 or 131 Chapter 6 SPEX File Formats 6 1 Introduction SPEX reads and writes the following file types e Spectral data spo amp spa e Response Matrices res amp ras e Energy grids egr e DEM
115. rameter for the current component Set new value of the parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu Enter your choice VAL add comp 1 cie Temperature keV type 2 1 5 Select the spectral component Select the parameter for the current component new value of the parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu Enter your choice VAL para Comment The same steps are followed to set the values of ion temperature and electron density at 1 keV EID and 1019 m 1e 4 respectively Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 32 OF 131 SPEX Version 1 00 Select a spectral parameter CIE model Description Normalisation ne nH V 1E64 m 3 Electron temperature keV Electron density 1E20 m 3 Ion temperature keV Micro turbulence velocity km s Abundance He Z 2 shortened Abundance Zn Z 30 SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the parameter for the current component Set new value of th
116. re especially useful to be used as macros to do routine jobs such as setting models reading data etc A log file is an ASCII file and therefore it may easily be edited with any editor In this way useful sets of SPEX commands may be precompiled The following sections will describe in detail the principles of creating recording and using these log files 7 2 Log File Structure A line in a log file may either contain a command or a comment 7 2 1 Command lines There are two types of command lines 1 menu ITEM 2 menu ITEM input menu is a menu acronym with a maximum of 4 characters it should be unique The index of document SRON SPEX TRUMO3 contains all current menu acronyms displayed in lowercase ITEM is a menu item This is also an acronym with a maximum of 4 characters Within each menu all menu items have unique acronyms Throughout the entire menu structure of the SPEX program the menu item acronyms do not have to be unique The index of document SRON SPEX TRUMO3 contains all current menu item acronyms displayed in uppercase input is an input field Several types of data may be entered Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX Loa FILE STRUCTURE PAGE 128 oF 131 e an integer 4 variable e a real 4 variable e a character string with a maximum of 256 characters Note when the input field 1s used to enter
117. rids egr An input energy grid file is a simple ASCII file containing one bin border per line starting with the lower limit from the first bin and ending with the upper limit from the last bin The data should be ordered in ascending energy and should be in units of keV An energy grid file with the following lines Oo TID QC produces 3 bins bin 1 from 5 6 keV bin 2 from 6 7 keV and bin 3 from 7 8 keV Note if data from various instruments are to be combined it is best to save the instrument energy grids separately and merge them later on into a new file that can be sorted with the UNIX sort utility in ascending energy order 6 5 DEM files dem DEM files are ASCII files containing at most 8192 lines of data Each line constists of 3 datafields e temperature keV e differential emission measure DEM in 109 m keV e error in the DEM The DEM is defined as Neng dV 6 1 andy 6 1 with ne the electron density ny the Hydrogen density V the volume and T the temperature When a DEM file is read the error in the DEM is not read However when a DEM file is written the error is written as well Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 125 or 131 integer 4 nbmax nemax ncmax nrespmax ndetedgmax parameter nbmax 2048 nemax 8192 ncmax 32768 nrespmax 524288 ndetedgmax 64 integer 4 nchan neg real 4 echani nbmax
118. rienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Plot menu Enter your choice GRID elim SRON SPEX Dae Ur Apri 24 1008 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 16 oF 131 Comment is entered to set the energy limits for total flux calculations SPEX Version 1 00 SPEX set energy limits for flux calculation menu Description Set lower energy limit keV Set upper energy limit keV Back to main menu Enter your choice LOW Enter the lower limit in keV 2 SPEX Version 1 00 SPEX set energy limits for flux calculation menu Description Set lower energy limit keV Set upper energy limit keV Back to main menu Enter your choice UPP Enter the upper limit in keV 10 12 SPEX Version 1 00 SPEX set energy limits for flux calculation menu Description Set lower energy limit keV Set upper energy limit keV Back to main menu Enter your choice MAIN Comment main is entered to return to the main menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 17 oF 131 2 3 Response file SPEX Version 1 00 SPEX m
119. ring SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the parameter for the current component Set new value of the parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu Enter your choice VAL main Comment main is selected to return to the main menu Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 37 OF 131 2 6 Fit of the parameters SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and output Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Modify the current model parameters Evaluate the current spectral model Simulate a spectrum using current model amp detector Spectral fitting error search etc Output of SPEX model properties to ascii file or screen Plot menu Comment is entered to fit the currently defined spectral model to the spectral data SPEX Version 1 00 SPEX fit menu change the spec
120. rr stel ste2 ste3 ste4 aspe amp ptyp e When the menu item is PARA for the menus par err stel ste2 ste3 amp sted In these situations it 1 not obvious to SPEX from which menu the menu item was requested For example COMP may be used to select a new spectral model component or to select an already existing spectral model component for ASCII output It then 1s beter to use par COMP comp A02 to select additive component 2 to modify one of it s parameters 7 3 2 Manual composition When log files are to be edited by hand chapter 3 of the user s manual should be used to select the correct menu acronyms and menu item acronyms 7 3 3 Nesting of Log Files SPEX allows nesting of log files up to 20 levels deep This means that log files may be executed from within log files For example Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX Loa FILE STRUCTURE PAGE 130 oF 131 exe NAME filename exe OPEN where filename is the explicit file name of the log file without the extension com of course After the line containing exe OPEN commands will follow that need to be executed after the execution of the commands in the log file named filename Note that whenever SPEX reads from one log file and at the same time writes to another log file the commands that were read will not be stored again In this situation the same construction as presente
121. rs In this case the spectral model consists of two components An additive collisional ionisation equilibrium model cie and a multiplicative absoprtion component Morrison amp McCammon absm mod nr t parameter with unit value st step minimum maximum cie 1 0 ne nH V 1E64 m 3 9 92346E 06 1 1 00E 03 1 00E 20 1 00E 20 cie 2 2 Temperature keV 2 5186 1 1 00E 03 1 00E 04 1 00E 03 cie 3 2 El dens 1E20 m 3 1 00000E 04 0 1 00E 03 1 00E 22 1 00E 10 cie 4 3 Ion temp keV 1 0000 O 00E 00 1 00E 04 1 00E 07 cie 5 2 Microturb vel km s 00000E 00 0 OOE 00 00E 00 3 00E 05 cie 6 1 Abundance He 1 0000 O 1 00E 03 1 00E 10 1 00E 10 cie 34 1 Abundance Zn 1 0000 O 1 00E 03 1 00E 10 1 00E 10 absm 1 2 Column 1E28 m 2 1 37425E 04 1 1 00E 03 00E 00 1 00E 10 Fluxes and restframe luminosities between 20000 and 12 000 keV nr mod photon flux energy flux nr of photons luminosity phot m 2 s W m 2 photons s W 1 cie 82 235 1 49219E 14 1 02189E 39 1 63844E 23 Chi squared value 888 76 Degrees of freedom 324 Notation nr denotes the parameter number of the model component t is a model specific pa rameter that defines the type of the parameter t ranges from 0 to 3 O normalization parameter 1 abundance paramter 2 fit parameter 3 non fit parameter st denotes the status of the parameter O frozen 1 fittable Each parameter may be fitted if allowed in the range between minimum and maximum with stepsize step Do
122. ry results see PBO1 section 6 4 At the moment the model in SPEX is still TBD and will be described in document SRON SPEX TRPBO08 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MODELS PAGE 113 oF 131 4 2 Spectral model parameters In the future a list of all parameters and default values at program startup for each spectral model will be made available At the moment we refer to the Cookbook document SRON SPEX TRCBO01 for a description of some spectral models and their relevant parameters 4 3 Cookbook examples In the Cookbook document SRON SPEX TRCBO1 we give a number of examples of spectral sim ulations using a so called log file We consider two categories of plasmas First we deal with optically thin plasmas In this category we consider the CIE equilibrium model applied to single temperature fitting of various coronal plasmas II Peg Capella We give an example of the DEM modelling of a stellar coronal plasma which combines the physical properties of the hot star Capella and the relatively cooler solar type star Centauri We also calculate the NEI non equilibrium model for a SNR and a more specific SNR Chevalier model for Cas A Secondly for non optically thin plasmas we simulate for the case of an Active Galactic Nucleus AGN a model spectrum which combines a variety of features that 1s contained within SPEX a red shifted source wit
123. s COMP Select the spectral component Additive component Ranging from 01 to 16 Multiplicative component Ranging from 01 to 08 PARA Select the parameter for the current component Depending on the current model and components Simple power law Normalisation 10 photons s keV at 1 keV Photon index Delta line Normalisation 10 photons s Line energy keV Collisional ionisation equilibrium model Normalisation neng V 10 m Electron temperature keV Electron density 107 m Ion temperature keV Micro turbulence velocity km s Abundance of element ranging from 02 to 30 Z 2 to 30 NEI model discontinuous temperature jump Normalisation neng V 10 m Preshock electron temperature keV Postshock electron temperature keV Ionisation parameter 107 s m Electron density 107 m Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 81 oF 131 r Ton temperature keV vmic Micro turbulence velocity km s Abundance of element ranging from 02 to 30 Z 2 to 30 SNR model Sedov adiabatic norm Normalisation 10 m Electron temperature keV Ionisation parameter 107 s m Ion temperature keV vmic Micro turbulence velocity km s Density gradient s of ISM Density gradient n of stellar ejecta aamm Adiabatic index Angular filling factor uU T Pre
124. s maximum available data channel in data set Specify number of bins to be taken together Default at program startup 1s 2 bins nEB Rebin the selected channel range Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 76 OF 131 Back to previous menu Back to main menu Rebin using minimal bin width amp sufficient S N ratio Especially in situations with low statistics per channel e g less than 10 counts per channel it is advised to rebin the data set in order to create channels with sufficient statistics The most significant difference with is that this option generates bins with variable widths however with a minimum signal to noise ratio This option is useful for example for high resolution spectra with strong line emission and very weak continuum IE After rebinning specific channels all channels above the rebinned range have differ ent channel numbers Therefore if more ranges are to be rebinned one is strongly advised to rebin the highest channels first IF It is not always guaranteed that the minimum signal to noise ratio is obtained in all channels This is an effect of the applied algorithm Channels with the highest S N ratio and neighbouring bins are merged until sufficient S N ratio is obtained This process is continued for the remaining number of bins At the end of the process a few bins with a low S N ratio will remain Thes
125. see this manual 3 2 6 6 3 ASCII output files asc from plasma model components SPEX provides options to save plasma model properties into ASCII files To learn more about these options see this manual 83 8 6 6 4 PostScript files The graphical output from SPEX may be written to PostScript files For this purpose SPEX uses the PGPLOT interface A typical PostScript file may contain several pages PGPLOT uses the standard Adobe convention and the PostScript files may be printed or used for other purposes e g encapsulating in documents To learn more about the various types of PostScript files generated by SPEX see this manual 3 8 6 6 5 Scratch files SPEX uses various temporary scratch files These files normally will be removed when the program is left However when SPEX is aborted or encounters a program crash these scratch files must be removed by hand NEVER delete these temporary files when running SPEX Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX Loa FILE STRUCTURE PaGE 127 oF 131 Chapter 7 SPEX Log File Structure amp Usage 7 1 Introduction SPEX may be run in three different modes 1 classical terminal mode 2 window mode 3 log file mode When SPEX is run in mode 1 or 2 mode 3 may always be used SPEX provides options to record and play back SPEX commands using so called log files These log files a
126. sion Codes in Legacy Nr 1 May 1992 the Journal of the High Energy Astrophysics Science Archive Research Center HEASARC eds K M Smale N White NASA GSFC Greenbelt U S A p 59 Gronenschild E H B M Mewe R 1978 Astron Astrophys Suppl Ser 32 283 Paper IIT Hamilton A J S 1985 Astrophys J 291 523 Heise J et al 1995 Astron Astroph in preparation Jansen F A 1988 X ray photometric morphology of the Cas A and Puppis A supernova remnants Thesis Leiden University Kaastra J S Jansen F A 1993 Astron Astrophys Suppl Ser 97 873 Kaastra J S Mewe R 1993a Astron Astrophys Suppl Ser 97 443 Kaastra J S Mewe R 1993b in UV and X ray Spectroscopy of Laboratory and Astrophysical Plasmas eds E Silver S M Kahn Cambridge Univ Press Cambridge U K p 134 Kaastra J S Mewe R 1993c The Mewe et al Plasma Emission Code in Legacy Nr 3 May 1993 the Journal of the High Energy Astrophysics Science Archive Research Center HEASARC eds K M Smale N White NASA GSFC Greenbelt U S A p 16 Landini M Monsignori Fossi B C 1990 Astron Astrophys Suppl Ser 82 229 Lemen J R Mewe R Schrijver C J Fludra A 1989 Astrophys J 341 474 Liedahl D A Osterheld A L Mewe R Kaastra J S 1994 in Proc Conf New Horizon of X ray Astron omy First Results from ASCA Tokyo in press Mewe R 1992 in Proc Workshop of UK SERC s Collaborative
127. sists of a number of header lines with a maximum of 256 characters per line The FIRST character of a header line MUST always be a c or a C The rest of the headerline is arbitrary and may be used to provide the binary data file with relevant information about the data set it self for example The information in the header lines will be ignored by SPEX The header MUST be closed by a line containing the following string SPEX spex or Spex This indicates to SPEX that the header is finished and the following fields contain spectral data e NCHAN integer 4 the number of output data channels Should be smaller than or equal to NBMAX currently set at 2048 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX FILE FORMATS PAGE 120 or 131 ECHAN NBMAX real 4 array the lower energy limits of the observed spectrum data channels in keV e ECHAN2 NBMAX real 4 array the upper energy limits of the observed spectrum data chan nels in keV e NEG integer 4 the number of bins for the energy grid on which the spectrum is represented e EG I NEMAX real 4 array the lower bin boundaries in keV for the energy grid on which the spectrum 1s represented e EG2 NEMAX real 4 array the upper bin boundaries in keV for the energy grid on which the spectrum 1s represented e NKRESP integer 4 the total number of response groups response group is a continuous seque
128. spex or the last defined filename Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 68 OF 131 PROG Save runtime output on off 5 Save data model and parameter information on off Save selected menus and items on off Change file name for SPEX output without out OPEN Open the file for saving SPEX output CLOS Close the file for saving SPEX output BACK Back to previous menu MAIN Back to main menu zl xmI Sjal S 2 H 3 3 Source parameters amp instrumental settings The main menu options in this category enable the control of important source specific information such as distance of the source and the abundances of elements It may also be used to provide SPEX with the necessary data such as energy grids and response matrices of space based instruments DIST Set the source distance It is very important to set the source at the right distance when additive and multiplicative model components are to be used SPEX specifically works with luminosities and not with fluxes except of course for the observed and simulated spectra Define the unit of your distance scale Internally SPEX uses a unit of 10 m to prevent machine overflow Other distance scales internally use their numbers PEX Distance in 102 m au Distance in Astronomical units Distance in light years Distance in pc KPC Distance in kpc MP Di
129. stance in Mpc Cosmological redshift use Ho 50 q9 0 5 BACK Back to previous menu MAIN Back to main menu UT my gt N DIST Enter the value of the distance in your selected units Default at program startup is 1 in SPEX units of 10 m Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PaGE 69 OF 131 SHOW Show the current distance and unit MAIN Back to main menu Select default energy grid This menu option sets the default energy grid on which the future calculations will be done Linear and logarithmical grids may be defined manually Predefined grids and response matrices of space based instruments may be read from file The current energy grid may be saved to a file for later use The default energy grid at program startup is a logarithmic grid from 107 100 keV with 8192 steps An energy grid must be defined before reading in any spectral data If the default grid is By 8 8 8 used interpolations to that grid will be made IE If data is to be appended to an existing data set the energy grid must be redefined in order to cover the full energy range and resolution of both instruments Otherwise the model is only calculated on the energy grid of the first data set IF If a model contains a red shift component the energy grid must be wide enough to cover the spectrum in the source s rest frame SPEX calculates the sp
130. ted parameters Back to main menu Enter your choice VAL add comp 1 cie ne nH V 1E64 m 3 type 0 1 1e 5 Comment In this example only the value of the selected parameter needs to be nodified thus is selected and the new value is entered i e 10 79 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 30 oF 131 SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the parameter for the current component Set new value of the parameter new status of the parameter new step for the parameter new minimum for the parameter new maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu SPEX Version 1 00 Select a spectral parameter CIE model Description Normalisation ne nH V 1E64 m 3 Electron temperature keV Electron density 1E20 m 3 Ion temperature keV Micro turbulence velocity km s Abundance He Z 2 shortened Abundance Zn Z 30 Enter your choice NORM t Comment The electron temperature is selected by entering Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PaGE 31 oF 131 SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the pa
131. the file 2 At the SPEX command prompt comment lines may be added to the log file that 1s used to store the commands of that particular session The comment is entered by typing a first followed by the comment itself Note that this 1s only possible when SPEX 1s actually storing commands to a log file i e the log file must be open Further it is not possible to add a comment to the log file when SPEX requests specific numerical input 7 3 Creating Log Files Log files may be created in two ways Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX Loa FILE STRUCTURE PAGE 129 oF 131 1 by storing the commands during a SPEX session See the user s manual 3 2 for more information about the options that SPEX offers 2 by editing a new file with any ASCII editor Note that this option is only recommended to experienced SPEX users In both cases the log file will have the extension com 7 3 1 SPEX session recording When log files are created by SPEX only those commands are stored that do not refer to new menus For example the command MAIN will not be stored The same holds for a number of commands with which a user may go from one menu to another By using the commands in a log file SPEX can access a menu item directely There are however a few situations in which the intermediate steps are stored e When the menu item is COMP for the menus par e
132. tions and may only be selected when the current spectrum model contains plasma components Select a plasma component for plotting Additive component Ranging from 01 to 16 Multiplicative component Ranging from 01 to 08 Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL SPEX MENU STRUCTURE PAGE 96 OF 131 Table 3 6 Line styles for the continuum and line emission components initially free free emission free bound emission two photon total continuum line emission not plotted Observed spectrum amp predicted model The observed spectrum convolved with the instrument response is plotted as data and the convolved model spectrum as model Model photon spectrum The photon spectrum is plotted as data Effective area of the detector Effective area of the detector is plotted as data Response matrix The response matrix is plotted as a two dimensional map The abscis displays the channel number the ordinate displays the input energy bin number Fit residuals The fit residuals are plotted as data The line y 0 is plotted as model Plasma model Continuum and line emission components The total component spectrum is plotted as data and the model is plotted with the linestyles displayed in tab 3 6 Plasma model Emission measure versus temperature The emission measure is plotted as data Only when an input D
133. tive components This would mean that first the third then the first and finally the the second multiplicative component would be applied to the selected additive component SPEX Version 1 00 SPEX model menu Define an additive component Define a multiplicative or redshift component Delete an additive component Delete a multiplicative or redshift component Set relation additive amp multiplicative components Show the current model Back to main menu Enter your choice SHOW Comment is entered to get an overview of the spectral model Number of multiplicative components Nr 1 absm Number of additive components 1 Nr 1 cie 1 O 0 O O O 0 O Comment SPEX shows the components and their relations Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 27 OF 131 SPEX Version 1 00 SPEX model menu Define an additive component Define a multiplicative or redshift component Delete an additive component Delete a multiplicative or redshift component Set relation additive amp multiplicative components Show the current model Back to main menu Enter your choice SHOW back Comment is entered to return to the main menu 2 5 Input spectral parameters SPEX Version 1 00 SPEX main menu Exit from SPEX Hide do not hide menu listings for experienced user only Log file save or read log files for commands and o
134. tral fitting method fit the parameters using current data amp model determine error bounds on parameters do a grid search Back to main menu Comment The parameters will be fitted with the default method at program startup Levenberg Marquardt amp linear scalings Therefore may be entered without setting the fitting method first Document SRON SPEX TRUM SRON SPEX Date April 24 1995 Issue Version 1 06 UsER s TUTORIAL MANUAL EXAMPLE SPEX SESSION PAGE 38 oF 131 iter lamda chisq param 2 param 35 0 1 E 02 2539 4395 5 00 5 000E 06 E 03 2386 5146 96 572E 05 E 04 350 2993 63 936E 05 E 05 222 2223 89 b14E 05 E 06 221 7196 91 228E 05 E 05 221 7196 91 228E 05 E 04 221 7196 91 228E 05 E 03 221 7196 228E 05 228E 05 40 bomn Bnoooo OrRPrRRPRPRB RHEE NNNNNNNE H H H RE WE Comment SPEX fits the spectral model with the spectral data iteratively The number of successive trials to improve the fit is shown as iter Convergence is assumed to occur at iter 4 After each iteration SPEX shows the fit parameter described in Press et al 1992 the x value and the value of the free parameters of the current spectral model In this example param 2 is the temperature keV and param 35 the column density The numbers denote the number with respect to the total number of spectral model parameters in the current spectral model Note that normalization parameters are not shown If there would have b
135. utput Set the source distance Select default energy grid Set energy limits for flux calculations Define default abundances and line properties etc Read write show or modify data response amp obs spectrum Modify the spectral model Modify the current model parameters Evaluate the current spectral model Simulate a spectrum using current model amp detector Spectral fitting error search etc Output of SPEX model properties to ascii file or screen Plot menu Enter your choice PAR Comment All spectral model components are defined with default values at program startup is entered to modify some spectral model parameters of the current spectral model Document SRON SPEX TRUM SRON SPEX Date April 24 1995 UsER s TUTORIAL MANUAL Issue Version 1 06 EXAMPLE SPEX SESSION PAGE 28 OF 131 SPEX Version 1 00 Define or modify spectral parameters Description Select the spectral component Select the parameter for the current component Set new new new new new value of the parameter status of the parameter step for the parameter minimum for the parameter maximum for the parameter Show the current parameters Show the correlations between the fitted parameters Back to main menu SPEX Version 1 00 Select a spectral component 401 Additive component 1 MO1 Multiplicative component 1 Enter your choice A401 Comment The spectral parameters of the additive component will be mo
Download Pdf Manuals
Related Search
Related Contents
iilll tteeerrrrrriiitttooorrriiiooo ccooommmeee aauuulllaaa `11 バイオマスター 4000 Einführung in das miniLAB 1008 Agri-Fab Cultivator 45-02661 User's Manual 5085PH User Guide-ClickOffer A/W Ayuda - Gasnor Untitled Haier AU182XFERA User's Manual Copyright © All rights reserved.
Failed to retrieve file