pyrex.CylindricalGenerator¶
-
class
pyrex.
CylindricalGenerator
(dr, dz, energy, shadow=False, flavor_ratio=(1, 1, 1), source='cosmogenic', interaction_model=<class 'pyrex.particle.CTWInteraction'>, earth_model=<pyrex.earth_model.PREM object>)¶ Class to generate neutrino vertices in a cylindrical ice volume.
Generates neutrinos in a cylinder with given radius and height.
- Parameters
- drfloat
Radius of the ice volume. Neutrinos generated within (0, dr).
- dzfloat
Height of the ice volume in the z-direction. Neutrinos generated within (-dz, 0).
- energyfloat or function
Energy (GeV) of the neutrinos. If
float
, all neutrinos have the same constant energy. Iffunction
, neutrinos are generated with the energy returned by successive function calls.- shadowbool, optional
Whether Earth shadowing effects should be used to reject events. If
True
then neutrinos which don’t survive transit through the Earth will be skipped when creating events. IfFalse
then all events are allowed and assigned a weight to scale their probability of occurrence.- flavor_ratioarray_like, optional
Flavor ratio of neutrinos to be generated. Of the form [electron, muon, tau] neutrino fractions.
- sourceoptional
Source type of neutrinos to be generated. Used in the determination of per-flavor neutrino/antineutrino fractions.
- interaction_modeloptional
Class to use to describe interactions of the generated particles. Should inherit from (or behave like) the base
Interaction
class.
See also
pyrex.particle.Interaction
Base class for describing neutrino interaction attributes.
- Attributes
- countint
Number of neutrinos produced by the generator, including those not returned due to Earth shadowing or other effects.
- drfloat
Radius of the ice volume. Neutrinos generated within (0, dr).
- dzfloat
Height of the ice volume in the z-direction. Neutrinos generated within (-dz, 0).
- get_energyfunction
Function returning energy (GeV) of the neutrinos by successive function calls.
- shadowbool
Whether Earth shadowing effects will be used to reject events.
- rationdarray
(Normalized) flavor ratio of neutrinos to be generated. Of the form [electron, muon, tau] neutrino fractions.
source
Generator.SourceTypeValue of the source type.
- interaction_modelInteraction
Class to use to describe interactions of the generated particles.
volume
Generation volume (m^3) in which event vertices are produced.
solid_angle
Generation solid angle (sr) in which event directions are produced.
Methods
SourceType
(value)Enum containing possible sources for neutrinos.
Generate a neutrino event in the ice volume.
Get the direction of the next particle to be generated.
get_exit_points
(particle)Get the intersections of the particle path with the ice volume edges.
Get the particle type of the next particle to be generated.
Get the vertex of the next particle to be generated.
get_weights
(particle)Get the weighting factors to be applied to the particle.