Re: Random.. not actually random
What do you mean by different random generators? You mean algorithms? And even so you are going to need different seeds otherwise your algorithms will end up always producing the same thing.
For example, let's say that you were using time as your seed and your first algorithm will start one second past midnight.
Algo 1) Takes the Seed of 1 and produces 5 (Multiplies by 5)
Algo 2) Takes the return of Algo 1 as a seed, 5, and produces 25 (Squares the Value)
Algo 3) Takes the return of Algo 2 as a seed, 25, and produces 18 (Subtracts 7)
Algo 4) Takes the return of Algo 3, as a seed, 18, and produces 9 (Divides by 2)
Okay do you finally end up with 2.
Now you might be saying okay that is more random because it went through more algorithms, but it's not because each algorithm depended on the first seed which is always going to be dependent on time. So basically everytime that it is one second past midnight you are going to get 2, just as if you had used the regular random function the value will always be the same.
That being said, you are best off finding a good seed. And if that is not good enough writing your own algorithm that can produce psuedo-random integers. But using multiple algorithms is pointless because they depend on eachother. Which will all lead back to the original seed.
|