Geant4 electromagnetic physics progress

The Geant4 electromagnetic (EM) physics sub-packages are a component of LHC experiment simulations. During long shutdown 2 for LHC, these packages are under intensive development and we report progress of EM physics in Geant4 versions 10.5 and 10.6, which includes faster computation, more accurate EM models, and extensions to the validation suite. New approaches are developed to simulate radiation damage for silicon vertex detectors and for configuration of multiple scattering per detector region. Improvements in user interfaces developed for low-energy and the Geant4-DNA project are used also for LHC simulation optimisation. * Corresponding author: Vladimir.Ivantchenko@cern.ch © The Authors, published by EDP Sciences. This is an open access article distributed under the terms of the Creative Commons Attribution License 4.0 (http://creativecommons.org/licenses/by/4.0/). EPJ Web of Conferences 245, 02009 (2020) CHEP 2019 https://doi.org/10.1051/epjconf/202024502009


Introduction
EM physics sub-libraries [1,2] are an important component of the Geant4 toolkit [3][4][5], which affects both Monte Carlo (MC) simulation accuracy and CPU performance of LHC detector simulations. In this work, we report on recent progress in EM model developments and on updates of user interfaces, which are included in the Geant4 versions 10.5 and 10.6. In our previous reports [5][6][7][8], earlier Geant4 versions were described. Combined configurations of Geant4-DNA and standard models were described in Refs. [2,9,10]. Common validation efforts for high and low-energy use-cases allow improving quality of EM simulation in general.

EM physics progress
Two recent Geant4 versions, 10.5 and 10.6, were released during the large shutdown of LHC between data taking periods Run-2 and Run-3. In these Geant4 versions, all EM physics developments are included into the toolkit without any restriction. EM physics updates are focused on improving of accuracy and speed of MC simulations.

Updates for Geant4 10.5
The Geant4 default model G4UrbanMscModel [5] for electron and positron multiple scattering (MSC) was tuned to backscattering data at low energies from different targets (full set of references in [7]). Above 100 MeV, a combination of the G4eCoulombScatteringModel single scattering model and the G4WentzelVIModel multiple scattering model was used [5]. For these models Mott corrections were added using a pre-existing data class, which was also optimized for more effective usage of precomputed data.
For gamma conversion and bremsstrahlung, the default angular generator was updated to G4ModifiedTsai. For gamma conversion, the main models (G4BetheHeitlerModel and G4PairProductionRelModel) were reviewed. Several improvements were introduced for the screening function approximation, Landau-Pomeranchuk-Migdal function approximation, and selection of elements in compounds. A new option was added to G4SeltzerBergerModel for bremsstrahlung: a mechanism of sampling of final state using a sampling table instead of differential cross section table.
New EM model classes were added: • G4BetheHeitler5DModel (5D) -sampling of final state for gamma conversion considering nuclear recoil and linear polarisation of primary gamma [8], which is used in gamma-ray astronomy and may be applied for LHC simulations. This model is more accurate but is slower than the default model. • Optional ICRU90 data for stopping powers of protons and alpha, requested for simulation of proton/ion therapy.
• G4LindhardSorensenModel -parametrized ion ionisation model above 10 MeV/u based on Lindhard-Sorensen theory [11], also alternative models G4AtimaEnergyLossModel and G4AtimaFluctuations, which are C++ implementations of the ATIMA code. Both new models are used for relativistic ion transport simulations.
• G4eplusTo2GammaOKVIModel and G4eplusTo3GammaOKVIModel classes implement 2-gamma and 3-gamma positron annihilation in flight and at rest, essential for positron tomography simulations.
These models are not included in the default EM configuration (Opt0) but are available in the alternative EM physics configuration (Opt4) prepared for accurate simulations including medical and space applications of Geant4, it is also called EMZ in reference Physics Lists.

Updates for Geant4 10.6
In this version of Geant4, previously introduced models were updated and substantial effort went to speed up computations in EM physics. Kernel classes used for handling of data tables were reviewed, and several optimizations were introduced into the toolkit. The most critical is the reduction of the number of calls to the logarithm function. This improvement was possible because EM tables are logarithmic over particle kinetic energy. At every step of every track, energy loss, ranges, and cross sections are recomputed using internal tables. The main optimization was to only compute the logarithm once, unless the particle energy changes. Also, the interpolation code was optimized such that number of lines of code at each call was reduced nearly a factor of 10. Benchmark results for speed up of simulation for CMS geometry without hit creation: • ~8% faster for Mac Book Pro (Mac OS 10.13.2) 2.8 GHz i7; • ~5% faster for AMD (SLC6 gcc8.2.0) 3.5 GHz. Another optimisation was implemented as "general" process for gamma (Fig.1). This approach means that Geant4 kernel sees the transportation process and only one physical process, which combines all 6 different gamma interactions implemented in Geant4. In this case, only one integral interaction length is calculated at a step of a gamma. At the interaction point, the concrete process is selected randomly according to partial cross sections. The CPU advantage of this approach depends on the concrete geometry and may be estimated on level of 5% for HEP applications. It is expected that similar EM results will be obtained with Geant4 10.5 and 10.6. This may be illustrated using ATLAS type simplified calorimeter response (Fig.2). For Geant4 10.4 visible energy was lower for ~1% and the resolution was wider for ~2%.
The process class G4GammaConversionToMuons has been available for a long time, but was recommended only for the ultra-relativistic case [12]. Due to the request of the Gamma Factory design group [13], the applicability area of this process was extended down to the muon pair production threshold (Fig.3). For that, recently introduced 5D-model has been extended for the case of the muon pair production, which required a revision of sampling algorithm to increase its efficiency.
For radiation damage studies [14] a new helper class G4NIELCalculator has been introduced for computation of non-ionizing energy loss (NIEL). This class may be used in user classes at each step of a particle in silicon detector. The advantage of this method is in independence of computations of crystal displacement on Geant4 cuts and stepping algorithm. Also, the model of displacement probability may be customized by users. Fig. 2. Simulation of the response of simplified ATLAS type EM calorimeter for 10 GeV gamma as a function of cut in range (Geant4 tracking parameter, see description in [1,3]) for different Geant4 versions from 10.4 to 10.6: top -visible energy, bottom -resolution. GS is the EM physics configuration where the default MSC model for e ± is substituted by the Goudsmit-Saunderson model [7]. EMY is the EM physics configuration used for medical and other low-energy applications. For this type of calorimeter for cut value 1 mm, in Geant4 10.5 and 10.6 compared to 10.4 visible energy increases by 1.5% and resolution decreases by 1.5%.

Low-energy EM physics
Geant4-DNA example applications relevant for the simulation of track structures (TS) in liquid water were reviewed [15]. These examples serve for evaluating Geant4-DNA physics models performance. We have also undertaken calculations on the influence of some userdefined simulation parameters (tracking and production cuts and maximum step size) in liquid water medium using some of the condensed history (CH) and TS models of Geant4 [16]. Using the TS models as reference, it was shown that Livermore inelastic models offer the best performance among the CH models for nanoscale electron transport.
Apart from lineal and specific energy simulated in Geant4 with the extended example "microyz", another fundamental description of the energy deposition pattern is obtained through the differential proximity function of tracks [17]. These functions are defined as the mean energy deposited to a spherical shell of given radius and thickness centred at a randomly chosen energy-transfer point in the shower of tracks induced by a primary particle and all its secondaries. In Geant4 version 10.6 a new Geant4-DNA application is implemented dedicated to the simulation of proximity functions in liquid water.

Validation of EM physics
Validation of EM physics is carried out permanently for each reference development version and each release using the EM testing suite [5][6][7][8]. The response and resolution for various calorimeter setups, response of tracking devices, backscattering of electrons and transmission via absorbers are controls. For Geant4 10.6 EM physics tests become a part of the geant4-val tool [17], which allows a significant improvement in the statistics of these tests and in the number of variants of EM calorimeter configurations.

Customisation of EM physics
Geant4 distributions include a sub-library of Physics Lists components. The recommended physics list for HEP applications is FTFP_BERT, which includes the default EM physics constructor. In order to reach desired optimum between simulation accuracy and CPU speed, the user may customise EM physics by varying values of cuts in range (Fig.2), changing the EM physics constructor, defining alternative EM physics models per detector region, and changing EM parameters [5][6][7][8].
In Geant4 10.6, modifications in the default EM physics compared to 10.5 are the lateral displacement algorithm in Urban multiple scattering model and the angular generator for bremsstrahlung and pair production. For applications which require high simulation accuracy, it is recommended to use the Opt4 (EMZ) EM physics configuration, which includes more strong step limitations, the Goudsmit-Saunderson (GS) model of MSC for electrons and positrons below 100 MeV, 5D-model of gamma conversion, and a more accurate model for the Compton scattering. A significant CPU penalty compared with the default EM physics is expected depending on geometry and primary energies. It may be more than factor 2 for LHC experiment simulations. However, this EM configuration is recommended as an alternative to the default for estimation of systematic uncertainty of the simulation.
For simulations where CPU efficiency is essential, there are more options which can be applied on top of the default EM physics. First, Opt1 (EMV) and Opt2 (EMY) EM physics constructors include simplified step limitations for MSC. This may be recommended for simulation of crystal calorimeters but not for sampling calorimeters, for which several parameters of electron multiple scattering are available: • RangeFactor -defines step size in vicinity of geometry boundary.
• GeomFactor -defines number of steps in thin layers for the Urban model. • Stepping algorithm -type of step limitation.
• LateralDisplacement flag enabling lateral displacement of an end point at each step.
• SafetyFactor -additional step limitation factor for the Urban model. • LambdaLimit -parameter for the Urban model sensitive to material density. These parameters are different for the default, EMY, and EMZ configurations. They may be changed via C++ interface or by Geant4 UI commands. This should be done before Geant4 initializes physics models.
For the case where a detector consists of several different calorimeters, it is possible to configure electron MSC for each calorimeter separately. For that, a new instance of the MSC model object should be created and desired parameters should be set only for this object and this object should be locked from further changes of parameters. This method should be implemented in custom EM physics constructor, for example, as is implemented for the CMS simulation [19]. Note, that such customisations may be performed both to speed-up simulation and to improve its accuracy.

Summary
The Geant4 version 10.6 includes several new EM models and helper classes which allow extend Geant4 capabilities for LHC experiments simulations. Geant4 10.6 is faster than previous Geant4 versions. New instruments are also available for customisation of MSC parameters per calorimeter region, which allows further increases in speed.