#include <GRBurst.h>
Inheritance diagram for GRBurst::

Public Methods | |
| GRBurst () | |
| Constructor. | |
| GRBurst (const std::vector< std::string > ¶mVector) | |
| Constructor. | |
| GRBurst (HepRandomEngine *engine, const double duration, const int npuls, const double flux, const double fraction, const double alpha, const double beta, const double epeak, const double specnorm, const bool flag) | |
| Constructor. | |
| virtual | ~GRBurst () |
| Destructor. | |
| GRBurst (const GRBurst &right) | |
| Copy Constructor. | |
| GRBurst & | operator= (const GRBurst &right) |
| Assignment Operator. | |
| std::pair< float, float > | dir () const |
| double | univFWHM () const |
| const std::vector< double > & | specnorm () const |
| long | nphoton () const |
| const std::vector< TimeEnergy > & | photonlist () const |
| GlobalData * | globalData () const |
| void | setSpecnorm (const std::vector< double > &specnorm) |
| void | createGRB (HepRandomEngine *engine, const std::string &prefix, const std::string &dir=0) |
| Create "n" GRBs where "n" is specified in GRBobsConstants.h file. More... | |
| void | createGRB (HepRandomEngine *engine, const double duration, const int npuls, const double flux, const double fraction, const double alpha, const double beta, const double epeak, const double specnorm, const bool flag) |
| Create burst for specified input parameters. | |
Protected Methods | |
| std::vector< TimeEnergy > & | photonlist () |
| Pointer to burst specific data (duration, flux etc.). | |
| virtual long | calcNphoton (HepRandomEngine *engine) |
| Calculate number of photons to be generated by the burst. | |
| void | makeTimes (HepRandomEngine *engine, const double ethres) |
| Make BATSE-like burst time profiles, placing GLAST photons a la cumulative BATSE intensity, but in narrower pulses. More... | |
Protected Attributes | |
| std::pair< float, float > | m_grbdir |
| double | m_univFWHM |
| Direction of the burst. | |
| std::vector< double > | m_specnorm |
| Universal width for the pulses within the current burst. | |
| long | m_nphoton |
| Spectral normalization. | |
| std::vector< TimeEnergy > | m_photonlist |
| Number of photons generated by a burst. | |
| GlobalData * | m_globalData |
| Burst data ((time,energy) pair for each photon. | |
Friends | |
| class | GRBobsSpectrum |
| std::ifstream & | operator>> (std::ifstream &is, GRBurst &grb) |
If the user specified burst parameters (duration, number of pulses, flux, fraction, broken power law indices, and peak energy), it creates the burst for specified parameters.
If the class was instantiated with no parameters or only a directory name, it creates n GRBs where n is specified in the GRBobsConstants.h file.
If a directory name is specified, the GRBs are written to files in that directory; otherwise, they are written to files in the current working directory.
The user can also specify names of directory and file containing burst data in which case, it simply reads the data from the file to make it available for the simulation.
|
||||||||||||||||
|
Create "n" GRBs where "n" is specified in GRBobsConstants.h file.
|
|
||||||||||||
|
Make BATSE-like burst time profiles, placing GLAST photons a la cumulative BATSE intensity, but in narrower pulses.
(1) m_npuls = number of pulses, proportional to BATSE duration. (2) pulse peak amplitude is random (0.0=>1.0); sort amps in descending amp order. (3) scramble amps of {1st,2nd} halves of pulses, separately (leaves profile assymmetric). (4) center of pulse time is random within duration. sort the times in ascending order. (5) pulse width is drawn from BATSE width distribution for bright bursts (attributes paper), scaled to GLAST energies using width ~E^-0.333. (6) make m_npuls pulses with "bisigma" shapes => sum to produce time profile. (7) form cumulative distribution of BATSE-like intensity. (8) distribute the m_nphoton photons according to cumulative intensity => GRBtimes. (9) offset the photon times according to (a) energy dependence, width ~E^-0.333 and (b) time of peak, also proportional to E^-0.333. |
1.2.13.1 written by Dimitri van Heesch,
© 1997-2001