Dear Kotoyo,
It sounds like you want to make cross section plots (or something that
you can easily calculate given the cross section, like events in a given
exposure in your detector). For that you'll need the cross section
spline file. I found it easier to work with a ROOT version of the spline
file, which you can create from the XML spline file using gspl2root.
With the total cross section given by the spline, along with your flux,
you can calculate the expected total number of events as flux*(cross
section), and use it to scale your event histogram.
This gets a little tricky when your detector contains multiple elements,
because you have to get multiple splines, and weight them correctly, so
I wonder if any of the GENIE developers know an easier way (or some
existing tools that do this).
Hope that helps,
Phil
On 02/19/2013 07:17 PM, Kotoyo Hoshina wrote:
> Hello,
>
> I'm a new beginner of genie neutrino generator, and have a question about how to weight genie events.
> The "weight" I mean is NOT same thing as the field I can get from EventRecord with following function
> evt->Weight();
> which for now I set always 1.
>
> I generated 2000 genie event with gevgen command, and converted result .root file to gst format root file.
> When I draw 1D histogram of El parameter (energy of final-state lepton), the vertical axis will be number of generated events per energy bin. This is just unweighted MC histogram and can't be used for physics analysis.
> Now I want to convert this number to physics plot, number of interactions actually happened per 2000 primary neutrinos. Due to the small cross section, the vertical axis should become very small (~1e-36).
>
> According to Genie user manual, genie is using internal global probability scale which is chosen from highest input energy and longest path length. At first, I thought this number will be the constant event weight to get actual number of events :
>
> event_weight = gmcj_driver->GlobProbScale()
> ...
> gst->Draw("El", event_weight);
>
> but after I read GMCJDriver carefully I noticed it won't work, because the event loop inside GMCJDriver actually loops much more than 2000. There is no way to know how many neutrinos are actually injected, thus no way to get normalization factor.
> It is always simple to calculate event weight of a specific event : it's just the interaction probability (and easy to obtain from EventRecord), but weighting entire MC sets strongly depends on how these MC sets are generated...
> and I couldn't find any document about weighting procedures, instead, I found re-weighting staff (which currently I don't need.)
>
> Is there any document or example code?
>
> thank you,
> kotoyo
>
|