This program is not a simulation. It prints the cross sections and stopping power used by the standard electromagnetic package, via G4EmCalculator which extracts these data from the PhysicsTables.
The program can be used in batch or interactively.
% TestEm0 TestEm0.in
% TestEm0 .... Idle> /run/initialize ... Idle> /testem/det/setMat Silicon Idle> /run/setCut 100 um Idle> /gun/particle e- Idle> /gun/energy 10 MeV Idle> /run/beamOn
The last command triggers BuildPhysicsTable() and executes the program.
Macros provided in this example:
DirectAccess.cc is a small batch program which shows how to compute the same basic data directly from the processes (indeed the models).