Wednesday, March 31, 2010

First two patches for xspec 12.6

We received two xspec bug reports whose fixes were too late to include in the latest release. Patches are in the usual place.

12.6.0a XSPEC issues a fatal error if the swind1 and zxipcf models are both used within the same session. Our thanks to Matteo Cerruti for pointing this out. Report added on Mar 29, 2010.

12.6.0b When applying fractional systematic errors to multiple channels grouped into a single bin, XSPEC should multiply by the square of the sum of the binned channels rather than the sum of the squares of the individual channels. Our thanks to Mike Nowak for pointing this out. Report added on Mar 31, 2010.

Tuesday, March 30, 2010

xspec 12.6 released

HEAsoft 6.9 is out including xspec v12.6. The release notes are below.

One point to note is that there have been internal changes to the models using the Magzdiarz & Zdziarski Compton reflection code. If there are local models out there which use internals from the xspec models they may break. Let us know and we will fix them.

New features in v12.6.0:

The main improvements in version 12.6.0 are to XSPEC's plotting capabilities:

- Multi-panel plotting is now supported for all combinations except
contour plots. For example, "plot data model resid ratio" will
produce a 4-panel plot on a single page. Up to 6 panels can be
plotted in this manner.

- There are many choices for axis units. These can be selected
using the "setplot energy" and "setplot wave" commands. For
example, "setplot energy GeV" uses GeV on the x- and y-axes.
"setplot wave" also has a new "perhz" option for displaying
the Y-axis in 1/Hz units.

- The "setplot" command has a new "redshift " option for shifting
displayed energies to the source frame.

Other new features:

- New models :
ireflect is a convolution model based on the pexriv code.
sirf is a multiblackbody self-irradiated funnel

- The normalizations on all power-law models (ie. powerlaw,
bknpow, bkn2pow, cutoffpl)can be changed to a flux over an
energy range by setting POW_EMIN and POW_EMAX keywords in "xset".
The powerlaw model then becomes equivalent to the pegpwlw model.

- The Compton reflection models (b/p)exr(a/i)v and (i)reflect have
been restructured to use adaptive Gauss-Kronrod quadrature for
the Greens' function integrals. The precision to which the
integrals are calculated can be set allowing a trade-off between
speed and precision.

- The wrapper functions additiveTable and multiplicativeTable
give external C++ models access to XSPEC's table model interpolation
routines (equivalent to the xsatbl and xsmtbl functions for Fortran

- The display of link expressions has been simplified to show only the
parameter numbers and not the extraneous component information.
Also "show model" will now only display the model components and
not the individual parameters. The parameters can be seen with
"show par".

Additional enhancements previously released as patches to 12.5.1:

- Added the solar abundance data set of Asplund, Grevesse, and Sauval
(2006) to the list of available tables accessed with the "abund"

- New "tclout nchan" option for returning the number of channels in a

- The "save" command now stores relative rather than absolute paths to
allow easier porting to other machines.

- The recorn model component has been converted from a mixing to a
multiplicative type. This allows a model to define multiple recorn

- A warning message is now issued if a user attempts to load a
response for a source n when there are still slots to fill for
source n-1. This is intended to catch cases where a user mistakenly
reverses the source and spectrum number input to the "response"

All bug fixes to v12.5.1 released as patches a - o are included in
v12.6.0. In addition the following problems have been corrected:

- It was possible for the addition of a systematic model error to
actually decrease the overall variance, when it was applied to a
zero-variance bin that was artificially increased by XSPEC for chi-
square fitting.

- Bug in "plot ratio" when using "setplot wave" with Hz units. Y-axis
model values < 10^-20 were not displayed in plot.

- The comptt model no longer stops and prompts the user when it fails
during its incomplete gamma calculation.

- The powerlaw model has been modified to avoid a numerical
instability that could occur if the index were within 10^-12 to
10^-15 of 1.0.