Message: Master thread seed ignored in working threads Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Master thread seed ignored in working threads 

Forum: Multithreading
Date: 11 Apr, 2018
From: Mikhail <Mikhail>

I have a problem with MT random number generation (ver.10.03): I initialized in the main() seed from an input file:
        CLHEP::RanluxEngine myEngine( 1234567, 4 );
        G4Random::setTheEngine(&myEngine);
        G4Random::setTheSeed(myseed,4);
        G4Random::showEngineStatus()
and I am looking on the seeds of the worker threads. It appears to me that the worker threads have seeds independent of the master thread seed. Tried both:
/run/eventModulo 1000 0
and
/run/eventModulo 1000 1
there is a difference, but still result is independent on input seed.
Any idea what am I doing wrong?

/run/eventModulo 1000 0
--------- Ranlux engine status ---------
 Initial seed = 284691130
Event 0 starts with initial seeds (99999994,99999994).
Event 1000 starts with initial seeds (5383604,39023584).
Event 2000 starts with initial seeds (83042079,11906903).
Event 3000 starts with initial seeds (77931690,53547024).
--------- Ranlux engine status ---------
 Initial seed = 81465912
Event 0 starts with initial seeds (99999994,99999994).
Event 1000 starts with initial seeds (5383604,39023584).
Event 2000 starts with initial seeds (83042079,11906903).
Event 3000 starts with initial seeds (77931690,53547024).

/run/eventModulo 1000 1
--------- Ranlux engine status ---------
 Initial seed = 54045319
Event 0 starts with initial seeds (99999994,99999994).
Event 1000 starts with initial seeds (99999994,99999994).
G4WT111 > --> Event 2000 starts with initial seeds (99999994,99999994).
G4WT55 > --> Event 3000 starts with initial seeds (99999994,99999994).
G4WT52 > --> Event 4000 starts with initial seeds (99999994,99999994).
G4WT5 > --> Event 5000 starts with initial seeds (99999988,99999994).
G4WT240 > --> Event 6000 starts with initial seeds (99999994,99999994).
G4WT65 > --> Event 7000 starts with initial seeds (99999994,99999994).
G4WT120 > --> Event 8000 starts with initial seeds (99999994,99999994).
G4WT88 > --> Event 9000 starts with initial seeds (99999994,99999994).
G4WT128 > --> Event 10000 starts with initial seeds (99999988,99999994).
G4WT168 > --> Event 11000 starts with initial seeds (99999994,99999994).
G4WT31 > --> Event 12000 starts with initial seeds (5,99982225).
G4WT134 > --> Event 13000 starts with initial seeds (99999994,99985867).
G4WT76 > --> Event 14000 starts with initial seeds (99999994,9089).
G4WT184 > --> Event 15000 starts with initial seeds (0,26029).
--------- Ranlux engine status ---------
 Initial seed = 27545372
G4WT16 > --> Event 0 starts with initial seeds (99999994,99999994).
G4WT149 > --> Event 1000 starts with initial seeds (99999994,99999994).
G4WT104 > --> Event 2000 starts with initial seeds (99999994,99999994).
G4WT135 > --> Event 3000 starts with initial seeds (99999994,99999994).
G4WT204 > --> Event 4000 starts with initial seeds (99999994,99999994).
G4WT14 > --> Event 5000 starts with initial seeds (99999988,99999994).
G4WT201 > --> Event 6000 starts with initial seeds (99999994,99999994).
G4WT233 > --> Event 7000 starts with initial seeds (99999994,99999994).
G4WT61 > --> Event 8000 starts with initial seeds (99999994,99999994).
G4WT0 > --> Event 9000 starts with initial seeds (99999994,99999994).
G4WT165 > --> Event 10000 starts with initial seeds (99999988,99999994).
G4WT30 > --> Event 11000 starts with initial seeds (99999994,99999994).
G4WT205 > --> Event 12000 starts with initial seeds (5,99982225).
G4WT108 > --> Event 13000 starts with initial seeds (99999994,99985867).
G4WT220 > --> Event 14000 starts with initial seeds (99999994,9089).
G4WT71 > --> Event 15000 starts with initial seeds (0,26029).

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 Feedback: Re: Master thread seed ignored in working threads   (Andrea Dotti - 11 Apr, 2018)
(_ Question: Re: Master thread seed ignored in working threads   (Mikhail - 12 Apr, 2018)
(_ Warning: Re: Master thread seed ignored in working threads   (Mikhail - 12 Apr, 2018)
(_ Warning: Re: Master thread seed ignored in working threads   (Andrea Dotti - 12 Apr, 2018)
(_ Note: Re: Master thread seed ignored in working threads   (Mikhail - 13 Apr, 2018)
 Add Message Add Message
to: "Master thread seed ignored in working threads"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews