Last change
on this file since 546 was
474,
checked in by garnier, 17 years ago
|
r553@wl-72148: laurentgarnier | 2007-05-15 16:01:10 +0200
|
File size:
546 bytes
|
Rev | Line | |
---|
[474] | 1 | # $Id: rndmSeed.mac,v 1.1 2003/01/27 17:55:47 maire Exp $ |
---|
| 2 | # |
---|
| 3 | # This macro illustrates how to save and reset the random number seed |
---|
| 4 | # |
---|
| 5 | # inform the RunManager to systematically save the seed |
---|
| 6 | # |
---|
| 7 | /random/setSavingFlag 1 |
---|
| 8 | # |
---|
| 9 | # run 0 |
---|
| 10 | # |
---|
| 11 | /run/beamOn 7 |
---|
| 12 | #look at what is saved |
---|
| 13 | /control/shell ls |
---|
| 14 | # |
---|
| 15 | # run 1 |
---|
| 16 | # |
---|
| 17 | /run/beamOn |
---|
| 18 | #save the seed of this current run |
---|
| 19 | /random/saveThisRun |
---|
| 20 | /control/shell ls |
---|
| 21 | # |
---|
| 22 | # run 2 |
---|
| 23 | # |
---|
| 24 | /run/beamOn 4 |
---|
| 25 | # |
---|
| 26 | # restart run 2 |
---|
| 27 | # |
---|
| 28 | /random/resetEngineFrom currentRun.rndm |
---|
| 29 | /run/beamOn 4 |
---|
| 30 | # |
---|
| 31 | # restart run 1 |
---|
| 32 | # |
---|
| 33 | /random/resetEngineFrom run1.rndm |
---|
| 34 | /run/beamOn |
---|
Note: See
TracBrowser
for help on using the repository browser.