# # Example Macro for simulating electrons in SNO+ # # run_electrons_snoplus.mac # Date: 01/12/2008 # contact: J. Wilson, Oxford # # Don't care about hadrons or muons so quicker not to initialise these processes /rat/physics_list/OmitMuonicProcesses true /rat/physics_list/OmitHadronicProcesses true # Select the snoplus geometry file (should be default) /rat/db/set DETECTOR geo_file "geo/snoplus.geo" /run/initialize # BEGIN EVENT LOOP /rat/proc frontend /rat/proc trigger /rat/proc eventbuilder /rat/proc count /rat/procset update 10 /rat/proc calibratePMT /rat/proclast outroot /rat/procset file "snoplus_electrons_labppo.root" # END EVENTLOOP # Use the simple gun vertex generator, combined with the fill position generator and poisson timing /generator/add combo gun:fill:poisson # Select particle type and momentum direction (0,0,0 = isotropic) and energy in MeV /generator/vtx/set e- 0 0 0 1.0 # Define a position in the centre of the scintillator region to select this one to be filled. /generator/pos/set 0.0 0.0 0.0 # Rate of 1 per second /generator/rate/set 1 # The above simulates electrons in the scintillator, if we want them in the AV and H2O too add more generators # (one for each defined geometry region) to list /generator/add combo gun:fill:poisson /generator/vtx/set e- 0 0 0 5.0 # Define a position in the AV to select this one to be filled. /generator/pos/set av # Rate of 0.028 per second (scale by relative volume to scintillator region = (6000^3-5945^3)/(5945^3)) # Not quite exact since we didn't consider the neck though /generator/rate/set 0.028 #/generator/rate/set 0. /generator/add combo gun:fill:poisson /generator/vtx/set e- 0 0 0 1.0 # Define a position in the cavity region to select this one to be filled. /generator/pos/set cavity # Rate of 1.693 per second (scale by relative volume to scintillator region = (8300^3-6000^3)/(5945^3)) # Not quite exact since we didn't consider the neck though /generator/rate/set 1.693 #/generator/rate/set 0.0 # generate 100 events /rat/run/start 10 exit