Files
geant4/examples/extended/electromagnetic/TestEm4/rndmSeed.mac
T
2016-06-10 11:51:14 +02:00

37 lines
581 B
Plaintext

# $Id: rndmSeed.mac 75839 2013-11-06 17:27:26Z gcosmo $
#
# This macro illustrates how to save and reset the random number seed
#
# inform the RunManager to systematically save the seed
#
/random/setSavingFlag 1
#
/run/printProgress 1
#
# run 0
#
/run/beamOn 7
#look at what is saved
/control/shell ls
#
# run 1
#
/run/beamOn
#save the seed of this current run
/random/saveThisRun
/control/shell ls
#
# run 2
#
/run/beamOn 4
#
# run3 : restart run 2
#
/random/resetEngineFrom currentRun.rndm
/run/beamOn 4
#
# run4 : restart run 1
#
/random/resetEngineFrom run1.rndm
/run/beamOn