1
|
import os
|
2
|
|
3
|
geometry_root_dir = os.environ['ERIT_ROOT']
|
4
|
|
5
|
verbose_level = 0
|
6
|
physics_processes = "none"
|
7
|
|
8
|
simulation_geometry_filename = os.path.join(geometry_root_dir, "maus", "erit_geometry.dat")
|
9
|
geant4_visualisation = False
|
10
|
visualisation_viewer = "OGLIXm"
|
11
|
visualisation_theta = 90.
|
12
|
visualisation_phi = 90.
|
13
|
|
14
|
spill_generator_number_of_spills = 1
|
15
|
beam_defs = []
|
16
|
n_particles = 101
|
17
|
for particle_index in range(n_particles):
|
18
|
if n_particles == 1:
|
19
|
radius = 2350.
|
20
|
else:
|
21
|
radius = 2350.-260.+520.*float(particle_index)/float(n_particles-1)
|
22
|
beam_defs.append({
|
23
|
"reference":{
|
24
|
"position":{"x":radius, "y":-0.0, "z":-500.0},
|
25
|
"momentum":{"x":0.0, "y":0.0, "z":1.0},
|
26
|
"particle_id":2112, "energy":10000., "time":0.0, "random_seed":1, # neutrons
|
27
|
},
|
28
|
"random_seed_algorithm":"incrementing_random", # algorithm for seeding MC
|
29
|
"n_particles_per_spill":1, # probability of generating a particle
|
30
|
"transverse":{
|
31
|
"transverse_mode":"pencil", # transverse distribution matched to constant solenoid field
|
32
|
},
|
33
|
"longitudinal":{
|
34
|
"longitudinal_mode":"pencil", # longitudinal distribution sawtooth in time
|
35
|
"momentum_variable":"p", # Gaussian in total momentum (options energy, pz)
|
36
|
}, # end time of sawtooth
|
37
|
"coupling":{"coupling_mode":"none"} # no dispersion
|
38
|
})
|
39
|
|
40
|
beam = {
|
41
|
"particle_generator":"counter", # routine for generating empty primaries
|
42
|
"random_seed":0, # random seed for beam generation; controls also how the MC
|
43
|
# seeds are generated
|
44
|
"definitions":beam_defs
|
45
|
}
|
46
|
|