Re: simple_gpile3

From: Manfred Hanke <Manfred.Hanke_at_email.domain.hidden>
Date: Fri, 25 Apr 2014 17:11:24 +0200
Dear Chandra gratings pile-up analyzers,

I'd also like to advertise simple_gpile3, available at
http://www.sternwarte.uni-erlangen.de/git.public/?p=isisscripts;a=blob_plain;f=src/fitting/fit-functions/simple_gpile/simple_gpile3.sl
(see also http://www.sternwarte.uni-erlangen.de/isis/):

simple_gpile2 parameterizes pileup in terms of "beta" in units of
[s*A/cts] -- which is the \gamma of Eq. (4) in
http://adsabs.harvard.edu/abs/2009ApJ...690..330H -- that is expected to
be close to
	beta0 = 3 * \Delta\lambda * t_frame
where \Delta\lambda is the resolution of the spectrometer (i.e. 5.5 mÅ
or 11 mÅ for the MEG or the HEG, respectively) and t_frame is the frame
time used for the observation.

I found it inconvenient to have a parameter that differs between MEG and
HEG (because of \Delta\lambda) and possibly also between different
observations (because of t_frame). Since both the MEG/HEG information
and t_frame are available within ISIS, simple_gpile3 is able to
parameterize pileup in terms of beta in units of beta0, which is
therefore expected to be close to 1 -- for any spectrum and observation.

Cheers,

Manfred


On 04/24/14 15:34, Michael Nowak wrote:
> Hi Maria-
> 
> I've taken the liberty of signing you up in the isis-users mail list, so you can 
> post further questions and get replies.  (Not to worry - it's a low key group 
> without tons of postings.)
> 
> The issue is that simple_gpile2 is a convolution model, which has the syntax:
> 
> 	generic_model(#)*other_generic_model(#) + convolution_model ( #, other_model_expression )
> 
> Note the positioning of the model identifier # and the parantheses, with the
> model expression to be convolved inside the convolution model
> parantheses.
> 
> So, in the below, I would do:
> 
> 	fit_fun("simple_gpile2(Isis_Active_Dataset, constant(Isis_Active_Dataset)*tbabs(1)*diskbb(1))");
> 
> (fit_fun being the ISIS command, "model" being the alias I also use for it 99.9% 
> of the time, but  I just wanted to be clear on what's generic ISIS and what's from
> scripts.)  I'm not sure what you're using the constant for (MEG/HEG crossnorm?),
> but you likely want that part of the pileup modeling.
> 
> Note that convolution models are the only ones that have a special syntax in 
> ISIS.  It otherwise makes no distinction between "additive" and "multiplicative"
> models.  Models are just vectors of numbers, which you can use however
> you want.  If they're a model from XSPEC, there's probably a way they were
> meant to be used, but some like "constant" I have certainly used both
> as additive and multiplicative.
> 
> To get hyper-technical with simple_gpile2, you would renormalize the HEG
> and MEG ARFs, since we put some of the effective area into the RMFs, and
> not the ARFs.  (I.e., gratings RMFs are not unit normalized.)  In the absence
> of pileup, ARF*RMF = response works fine, but in simple_gpile2 we want all
> the effective area in the ARFs.  
> 
> I've got this  described in the appendix of Nowak et al. 2008, ApJ 689, p. 1199. 
> We put on order of 5% of the effective area into the RMFs, so assuming an 
> ~20% pileup correction, doing this change might be something like a 5%*20% 
> ~ 1% change to the total spectrum.
> 
> Anyhow, write back to isis-users if you need more help.
> 
> -Mike
> 
> Begin forwarded message:
> 
>> Dear ISIS experts,
>>
>> I am trying to use the simple_gpile2 routine in ISIS to correct for 
>> pile-up in my HETGS observations.
>> I have loaded HEG1 and MEG1 spectra and fitted them with a simple model. 
>> Then, I add
>> simple_gpile2 to the model as follows:
>>
>> model("constant(Isis_Active_Dataset)*simple_gpile2(Isis_Active_Dataset)*tbabs(1)*diskbb(1)");
>>
>> Then, I thaw the parameter called beta for both datasets and try to make 
>> a fit. However, I get the
>> error below, which is really cryptic to me.
>>
>> Could you please advise me or point me to some documentation on the use 
>> of this routine? (I already
>> checked the pileup ABC guide and Hanke 2009 paper, but I still don't 
>> understand what may be causing
>> the error).
>>
>> Many thanks in advance,
>>
>> Maria
>>
>> Error: /Users/mdiaztri/SciSW/isis-1.6.2/src/fit-cmds.c:2328
>> Error: /Users/mdiaztri/SciSW/isis-1.6.2/src/fit-cmds.c:2328
>> Stack Underflow Error
>> ***string***:1:__isis_tmp_ffname__:Stack Underflow Error
>> Error encountered while executing __isis_tmp_ffname__
>> Error :/Users/mdiaztri/SciSW/isis-1.6.2/src/fit-cmds.c:1869
>> Failed: evaluating model
>> Error :/Users/mdiaztri/SciSW/isis-1.6.2/src/fit-cmds.c:1869
>> Failed: evaluating model
>> Traceback: _fit
>> /Users/mdiaztri/SciSW/isis/1.6.2/share/fit-cmds.sl:1176:_do_eval_fit:Stack 
>> Underflow Error
>>   Local variables for _do_eval_fit:
>>     Ref_Type _do_eval = &_isis->_fit
>>     Integer_Type data_type = 0
>>     String_Type msg = "s = fit_counts ([&info_struct])"
>>     Integer_Type nargs = 0
>>     Struct_Type tmp = Struct_Type with 4 fields
>>     Ref_Type ref = Local variable reference
>>     Integer_Type response_type = 0
>>     Integer_Type saved_fit_verbose = 0
>>     Null_Type fit_verbose = NULL
>>     Undefined_Type status = Undefined_Type
>> /Users/mdiaztri/SciSW/isis/1.6.2/share/fit-cmds.sl:1191:fit_counts:Stack 
>> Underflow Error
>>   Local variables for fit_counts:
>>     String_Type msg = "s = fit_counts ([&info_struct])"
>> <stdin>:42:<top-level>:Stack Underflow Error

----
You received this message because you are
subscribed to the isis-users list.
To unsubscribe, send a message to
isis-users-request_at_email.domain.hiddenwith the first line of the message as:
unsubscribe
Received on Fri Apr 25 2014 - 11:11:43 EDT

This archive was generated by hypermail 2.3.0 : Thu May 01 2014 - 08:23:53 EDT