Computes the equivalent width of an emission or absorption line in source or background data.
sherpa> [B]EQWIDTH [# [ID]] (<continuum_stack>,
<continuum_plus_line_stack>)
EQWIDTH is used for computing equivalent widths in source datasets,
while BEQWIDTH is used for computing equivalent widths in background
datasets.
# specifies the dataset over which the source model is evaluated. The
ID modifier is used only for computing background dataset equivalent
widths, and then if and only if the Sherpa state object variable
multiback is set to 1, i.e., if more than one background dataset is to
be associated with a single source dataset. The ID modifier may be any
unreserved string (e.g., A, foo, etc.), i.e., a string that is not a
parsable command.
<continuum_stack> represents one or more models (or user-defined model
stacks) that describe the continuum, while <continuum_plus_line_stack>
represents two or more models (or user-defined model stacks) that
describe the continuum plus line.
To compute the equivalent width, an integral
over the energy/wavelength range of the dataset is performed.
At each point,
the <continuum_stack> (C)
and <continuum_plus_line_stack>
([C+L]) are evaluated;
the integrand is then ([C+L] - C) / C.
The models are specified on-the-fly in the same manner that
SOURCE or
BACKGROUND model
stacks are defined, as algebraic combinations of previously defined
model components. The examples below illustrate this point.
The user must specify the models in this manner, because
(a) Sherpa cannot identify
whether a particular model component should be associated with
the continuum or with the line, and (b) multiple line components
may be specified in the SOURCE model stack, so that
it cannot be used in place of
<continuum_plus_line_stack> to compute equivalent widths.
Equivalent widths may also be computed using the
Sherpa/S-Lang module functions
get_eqwidth and
get_beqwidth.
Model a continuum and emission line complex using a power-law and
normalized Gaussian, then compute the equivalent width:
sherpa> SOURCE = POW[cont]+NGAUSS[eline]
...
sherpa> FIT
...
sherpa> EQWIDTH 1 (cont,cont+eline)
EW = 0.535073 keV
Define continuum and line model stacks; use these in the equivalent
width calculation:
sherpa> BBODY[modela]
sherpa> POWLAW1D[modelb]
sherpa> NGAUSS[line1]
sherpa> NGAUSS[line2]
sherpa> NGAUSS[line3]
...
sherpa> CONT = modela+modelb
sherpa> ELINE = line1
sherpa> SOURCE = CONT + ELINE + line2 + ...
sherpa> FIT
...
sherpa> EQWIDTH 1 (CONT,CONT+ELINE)
EW = 0.454946 keV
- chandra
-
guide
- sherpa
-
bye,
calc_kcorr,
dataspace,
dcounts,
dollarsign,
echo,
eflux,
erase,
flux,
get,
get_dcounts_sum,
get_dir,
get_eflux,
get_eqwidth,
get_filename,
get_flux2d,
get_flux_str,
get_lfactorial,
get_mcounts_sum,
get_pflux,
get_source_components,
get_verbose,
groupbycounts,
guess,
is,
journal,
list,
list_par,
mcounts,
numbersign,
paramest,
plot_eprof,
plot_rprof,
prompt,
reset,
run,
set,
set_analysis,
set_axes,
set_coord,
set_dataspace,
set_dir,
set_verbose,
setplot,
sherpa-module,
sherpa_plotfns,
sherpa_utils,
show,
simspec,
use,
version
|