OPSim: A custom tool for optical photon simulation in Geant4

Dear Geant4 users,
I have developed a new tool to make the development of optical photon applications much easier and to increase the flexibility and maintainability of developed applications. With this tool,

  1. The functionality of the G4MaterialPropertiesTable and G4OpticalSurface classes have been extended to simplify their implementation and allow users to control the entire process through user interface commands.
  2. Users can provide energy-dependent inputs required for the simulation in the desired units order both as a function of energy and wavelength.
  3. The provided abstract classes in this tool allow users to develop standalone, portable, and reusable scintillator build code while working on their own projects.
  4. This tool presents an elegant way of preparing a predefined scintillator for Geant4 and paves the way for the future creation of a scintillator database.
  5. This tool encourages users to write clean, modular, and reusable code.
  6. The usage and advantages of this tool are demonstrated on OPNovice, one of the examples in Geant4’s optical category.
    For more information, please see the related article and code: