Message: understand weird random seed issue Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None understand weird random seed issue 

Forum: Event and Track Management
Date: 14 Nov, 2015
From: Zhiyi Liu <Zhiyi Liu>


I am trying to change random generator seeds for each run. I am experiencing very weird random seed issue.

In my main file, I have the following code:

  G4Random::setTheEngine(new CLHEP::RanecuEngine);
  G4long seed = time(NULL);
  G4cout << "Seed: " << CLHEP::HepRandom::getTheSeed() << G4endl;

For sure, I submitted my jobs using an interval more than 1 second. However, I realized that different seeds give repeated results!

I tried other seeds such as 1, 2, 5, 15 etc. Some of them also give repeated results such as 5 and 15.... which I cannot find any 'rule'.

If am I doing wrong things here? Any hint?

Thanks, Zhiyi. (geant4.10.01.p02 installed and Ubuntu 14.04)

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

1 Feedback: Re: understand weird random seed issue   (Gumplinger Peter - 16 Nov, 2015)
1 Agree: Re: understand weird random seed issue   (Zhiyi Liu - 16 Nov, 2015)
2 Question: Re: understand weird random seed issue   (Azam Zabihi - 14 Feb, 2016)
 Add Message Add Message
to: "understand weird random seed issue"

 Subscribe Subscribe

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

[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]