|
From: | Paul Johnson |
Subject: | Re: random generator |
Date: | Fri, 07 Jun 2002 09:06:41 -0500 |
User-agent: | Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.9) Gecko/20020516 |
./heatbugs -sIf you are using your own random generators, I think the easiest thing to do is type in your own seed values at the command line. That way programs that run the sim over and over can directly adjust the seed how they like. In newer editions of Swarm, the -S flag can be used, as in
./heatbugs -S2342123 Margo wrote:
Typically you would seed the random number with the system time, at the beginning of your simulation. That would constantly be a different seed. Margo Serban LASCU hotmail wrote:hello! i'm using uniformDblRand and uniformIntRand in ObjectiveC, but they are generating the same numbers every time. how can i initialize the random generator to get a really random series? thanks, bye! ==================================
Paul E. Johnson email: address@hidden Dept. of Political Science http://lark.cc.ku.edu/~pauljohn University of Kansas Office: (785) 864-9086 Lawrence, Kansas 66045 FAX: (785) 864-5700 ================================== Swarm-Support is for discussion of the technical details of the day to day usage of Swarm. For list administration needs (esp. [un]subscribing), please send a message to <address@hidden> with "help" in the body of the message.
[Prev in Thread] | Current Thread | [Next in Thread] |