The Geant4 toolkit includes several fully coded examples that demonstrate the implementation of the user classes required to build a customized simulation.
The new "basic" examples cover the most typical use-cases of a Geant4 application while keeping simplicity and ease of use. They are provided as a starting point for new Geant4 application developers.
A set of "extended" examples range from the simulation of a non-interacting particle and a trivial detector to the simulation of electromagnetic and hadronic physics processes in a complex detector. Some of these examples require some libraries in addition to those of Geant4.
The "advanced" examples cover the use-cases typical of a "toolkit"-oriented kind of development, where real complete applications for different simulation studies are provided.
All examples can be compiled and run without modification. Most
of them can be run both in interactive and batch mode using the
input macro files (
*.in) and reference output files
*.out) provided. Most examples are run routinely as
part of the validation, or testing, of official releases of the Geant4
The previous set of examples oriented to novice users, "novice", has been refactored in "basic" and "extended" examples sets in Geant4 10.0. The information about the original set of these examples can be found at the last section of this chapter.<-- 9.5. g4tools 10.2. Basic Examples --> "