Source analysis

Module type name (to be used for the module commands): source

Description

The source analysis module has been conceived for the monitoring of the primary generator, so that the user can cross check the input GPS macro input versus the position, energy and direction of the particles finally used by GRAS for the simulation.

The distributions for source kinetic energy, momentum, direction angles phi/theta and weight are saved to histograms in the CSV output, normalised to 1.

Script example:

/gras/analysis/source/addModule source1
/gras/analysis/source/source1/setMaxEventID 1000

Available Units

The module accepts as units all the G4 units under the “Energy” category.

Specific Module commands

/gras/analysis/source/<moduleName>/setMaxEventID <NbOfEvents>

Set the max event ID for the events to be saved in the output. By default, source particle properties will be stored for the first 10000 particles. It is suggested to first perform a detailed monitoring of the source properties with a sufficient statistics, and subsequently limit the number of stored primary particles for production runs. The module saves the results to a tuple, with event-by-event information. The output file size can therefore be significant if a large size of particles is used for the simulation.

Output

Scalars (only in CSV file)

No scalars are reported.

Histograms (in CSV and ROOT files)

Controlled by the bookHisto command (default is active).

kine DISTRIBUTION

  • Name (for the setHistoByName command): <moduleName>_kine

  • Spectrum of the kinetic energy of the primary particle

  • Always active

phi DISTRIBUTION

  • Name (for the setHistoByName command): <moduleName>_phi

  • Spectrum of the phi of the primary particle

  • Always active

theta DISTRIBUTION

  • Name (for the setHistoByName command): <moduleName>_theta

  • Spectrum of the theta of the primary particle

  • Always active

mom DISTRIBUTION

  • Name (for the setHistoByName command): <moduleName>_mom

  • Spectrum of the momentum of the primary particle

  • Always active

weight DISTRIBUTION

  • Name (for the setHistoByName command): <moduleName>_weight

  • Spectrum of the weight of the primary particle

  • Always active

Tuples (only in ROOT file)

Controlled by the bookTuples (default is active).

<moduleName> Information from the Primary Generator

  • Name: <moduleName>_tuple_source

  • TID (or Energy Depostion) information by event

  • Columns:
    • pdg: pdg of the primary particle

    • mass: mass of the primary particle

    • x: x position of the primary particle

    • y: y position of the primary particle

    • z: z position of the primary particle

    • px: momentum projection on x of the primary particle

    • py: momentum projection on y of the primary particle

    • pz: momentum projection on z of the primary particle

    • theta: theta of the primary particle

    • phi: phi of the primary particle

    • kine: kinetic energy of the primary particle

    • time: time of the primary particle

    • weight: weight of the primary particle

  • Always active


GRAS/trunk/r2242