{"id":524,"date":"2024-11-04T19:03:18","date_gmt":"2024-11-04T19:03:18","guid":{"rendered":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/?page_id=524"},"modified":"2024-11-06T14:54:33","modified_gmt":"2024-11-06T14:54:33","slug":"how-to-use-sixte","status":"publish","type":"page","link":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/how-to-use-sixte\/","title":{"rendered":"Quick Start"},"content":{"rendered":"\n<p>In the following, a quick tutorial for SIXTE is displayed to get you started. We still recommend to take a look into the tutorial section in the SIXTE manual (link to the most recent version at the bottom of this page) for a way more detailed tutorial with a lot of explanations.<\/p>\n\n\n\n<h3>Environment Variable and testing<\/h3>\n\n\n\n<p>To be able to use the tools, you have to set the environment variables&nbsp;<code>$SIMPUT<\/code>&nbsp;and&nbsp;<code>$SIXTE<\/code>&nbsp;to the respective installation directories and source the&nbsp;<code>sixte-install.csh\/sh<\/code>&nbsp;script, like shown in the <a href=\"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/linux\/\">installation tab<\/a>.<\/p>\n\n\n\n<p>To follow along with this tutorial, you will need to have XSPEC installed. <\/p>\n\n\n\n<p>Next, we are going to test if SIMPUT and SIXTE are running in general. Please enter to your terminal the following commands:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>plist simputfile\nplist sixtesim<\/code><\/pre>\n\n\n\n<p>Both give you a list with possible parameters to set for <code>simputfile<\/code> and <code>sixtesim<\/code> respectively.<\/p>\n\n\n\n<p>For <code>simputfile<\/code> this should look like the following:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Parameters for \/Your\/directory\/pfiles\/simputfile.par\n       Simput = some_fits_file.fits output SIMPUT catalog file\n      (Src_ID = 1)               source ID\n    (Src_Name = none)            source name\n          (RA = 0.0)             right ascension (deg)\n         (Dec = 0.0)             declination (deg)\n     (srcFlux = 0.0)             source flux (erg\/s\/cm^2)\n        (Elow = 0.1)             lower bound of the generated spectrum (keV)\n         (Eup = 100.0)           upper bound of the generated spectrum (keV)\n       (Estep = 0.0)             deprecated (resolution of the spectrum (keV) )\n       (Nbins = 1000)            number of energy bins created from Elow to Eup\n    (logEgrid = no)              use a logarithmic energy grid (from Elow to Eup with Nbins)\n  (plPhoIndex = 2.0)             power law index\n      (plFlux = 0.0)             power law flux (erg\/s\/cm^2)\n        (bbkT = 1.0)             black body temperature (keV)\n      (bbFlux = 0.0)             black body flux (erg\/s\/cm^2)\n     (flSigma = 1.0e-3)          Fe line sigma (keV)\n              .                            .\n              .                            .\n              .                            .\n<\/code><\/pre>\n\n\n\n<h3 id=\"source\">SIMPUT Source creation<\/h3>\n\n\n\n<p>Before starting an observation simulation, the sources need to be described in the&nbsp;<a href=\"http:\/\/hea-www.harvard.edu\/heasarc\/formats\/simput-1.1.0.pdf\">SIMPUT<\/a>&nbsp;format. The SIXTE software package contains tools to obtain such a file from several input files such as an XSPEC- or ISIS-parameter file for a spectrum, as well as for example an ASCII description of a lightcurve.<\/p>\n\n\n\n<p>For a simple non-variable source with an absorbed power law spectrum, we are going to create a simple .xcm file with <a href=\"https:\/\/heasarc.gsfc.nasa.gov\/xanadu\/xspec\/\">XSPEC<\/a>:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>computer:~\/&gt; xspec\n\n\t\tXSPEC version: 12.12.0\n\tBuild Date\/Time: Mon Dec 20 11:07:27 2021\n\nXSPEC12&gt;model phabs*pegpwrlw\n\nInput parameter value, delta, min, bot, top, and max values for ...\n              1      0.001(      0.01)          0          0     100000      1e+06\n1:phabs:nH&gt;0.2\n              1       0.01(      0.01)         -3         -2          9         10\n2:pegpwrlw:PhoIndex&gt;2.05\n              2      -0.01(      0.02)       -100       -100      1e+10      1e+10\n3:pegpwrlw:eMin&gt;2\n             10      -0.01(       0.1)       -100       -100      1e+10      1e+10\n4:pegpwrlw:eMax&gt;10\n              1       0.01(      0.01)          0          0      1e+20      1e+24\n5:pegpwrlw:norm&gt;21.6\n\n========================================================================\nModel phabs&lt;1&gt;*pegpwrlw&lt;2&gt; Source No.: 1   Active\/Off\nModel Model Component  Parameter  Unit     Value\n par  comp\n   1    1   phabs      nH         10^22    0.200000     +\/-  0.0          \n   2    2   pegpwrlw   PhoIndex            2.05000      +\/-  0.0          \n   3    2   pegpwrlw   eMin       keV      2.00000      frozen\n   4    2   pegpwrlw   eMax       keV      10.0000      frozen\n   5    2   pegpwrlw   norm                21.6000      +\/-  0.0          \n________________________________________________________________________\n\nXSPEC12&gt;flux 2 10\n Model Flux 0.0032845 photons (2.1157e-11 ergs\/cm^2\/s) range (2.0000 - 10.000 keV)\nXSPEC12&gt;\nXSPEC12&gt;save model mcrab.xcm\nXSPEC12&gt;quit<\/code><\/pre>\n\n\n\n<p>With this, we can now build our SIMPUT file, by writing a short shell script:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>#!\/bin\/bash\n\nbase=mcrab\n$SIXTE\/bin\/simputfile Simput=${base}.fits \\\n     Src_Name=first \\\n     RA=0.0 \\\n     Dec=0.0 \\\n     srcFlux=2.137e-11 \\\n     Elow=0.1 \\\n     Eup=15 \\\n     NBins=1000 \\\n     logEgrid=yes \\\n     Emin=2 \\\n     Emax=10 \\\n     XSPECFile=${base}.xcm<\/code><\/pre>\n\n\n\n<p>Make this shell script executable (run: <code>chmod a+x .\/mcrab.bash<\/code>) and execute it.<\/p>\n\n\n\n<h3>Running the simulation<\/h3>\n\n\n\n<p>We are using the tool <code>sixtesim<\/code> to run our sample simulation. Therefore, we write another shell script:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>#!\/bin\/bash\n\nbase=mcrab\n\nxmldir=$SIXTE\/share\/sixte\/instruments\/athena-wfi\/wfi_wo_filter\nxml=${xmldir}\/ld_wfi_ff_large.xml\n\n$SIXTE\/bin\/sixtesim \\\n     XMLFile=${xml} \\\n     RA=0.000 Dec=0.000 \\\n     Prefix=sim_ \\\n     Simput=${base}.fits \\\n     EvtFile=evt_${base}.fits \\\n     Exposure=1000<\/code><\/pre>\n\n\n\n<p>Again, make this shell script executable and execute it.<\/p>\n\n\n\n<h3>Analysing the simulation<\/h3>\n\n\n\n<h4>Create an image<\/h4>\n\n\n\n<p>To take a look at our source, we can use the tool <code>imgev<\/code>:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>$SIXTE\/bin\/imgev \\\n     EvtFile=sim_evt_mcrab.fits \\\n     Image=img_mcrab.fits \\\n     CoordinateSystem=0 Projection=TAN \\\n     NAXIS1=512 NAXIS2=512 CUNIT1=deg CUNIT2=deg \\\n     CRVAL1=0.0 CRVAL2=0.0 CRPIX1=256.5 CRPIX2=256.5 \\\n     CDELT1=-6.207043e-04 CDELT2=6.207043e-04 \\\n     history=true clobber=yes<\/code><\/pre>\n\n\n\n<p>Even if a point source is not that interesting to look at, this can be used in the same way for much more complex sources.<\/p>\n\n\n\n<h4>Spectral shape<\/h4>\n\n\n\n<p>More interesting for a single point source is the spectral shape, so using the tool <code>makespec<\/code> we can produce an X-ray spectrum:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>$SIXTE\/bin\/makespec \\\n     EvtFile=sim_evt_mcrab.fits \\\n     Spectrum=spec_mcrab.pha \\\n     EventFilter=\"(RA&gt;359.95 || RA&lt;0.05) &amp;&amp; Dec&gt;-0.05 &amp;&amp; Dec&lt;+0.05\" \\\n     RSPPath=${xmldir} clobber=yes<\/code><\/pre>\n\n\n\n<h3>SIXTE Simulator Manual<\/h3>\n\n\n\n<p>The current version of the SIXTE simulator manual is available for download below. It includes a general description of SIXTE and the implementation of various X-Ray detectors such as the WFI, X-IFU, eROSITA and more. In addition, tutorials for Athena WFI and X-IFU simulations are included.<\/p>\n\n\n\n<p><strong>download:&nbsp;<\/strong><a href=\"http:\/\/www.sternwarte.uni-erlangen.de\/~sixte\/data\/simulator_manual.pdf\" data-type=\"URL\">simulator_manual.pdf<\/a> (v1.3.17, 2023-02-16)<\/p>\n\n\n\n<p>supplementary files for the X-IFU tutorial (30MB!):&nbsp;<a href=\"http:\/\/www.sternwarte.uni-erlangen.de\/~sixte\/downloads\/X-IFU_clusters_tutorial.tgz\">X-IFU_clusters_tutorial.tgz<\/a><\/p>\n\n\n\n<p>4 year eROSITA Attitude file for a launch in April 2019 (200MB!):&nbsp;<a href=\"http:\/\/www.sternwarte.uni-erlangen.de\/~sixte\/data\/eRASS_4yr_epc85_att.fits.bz2\">eRASS_4yr_epc85_att.fits.bz2<\/a><\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In the following, a quick tutorial for SIXTE is displayed to get you started. We still recommend to take a look into the tutorial section in the SIXTE manual (link to the most recent version at the bottom of this page) for a way more detailed tutorial with a lot&#8230;<\/p>\n","protected":false},"author":1085,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":[],"categories":[],"tags":[],"_links":{"self":[{"href":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/wp-json\/wp\/v2\/pages\/524"}],"collection":[{"href":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/wp-json\/wp\/v2\/users\/1085"}],"replies":[{"embeddable":true,"href":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/wp-json\/wp\/v2\/comments?post=524"}],"version-history":[{"count":5,"href":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/wp-json\/wp\/v2\/pages\/524\/revisions"}],"predecessor-version":[{"id":586,"href":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/wp-json\/wp\/v2\/pages\/524\/revisions\/586"}],"wp:attachment":[{"href":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/wp-json\/wp\/v2\/media?parent=524"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/wp-json\/wp\/v2\/categories?post=524"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.sternwarte.uni-erlangen.de\/sixte\/wp-json\/wp\/v2\/tags?post=524"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}