How does uranium processing not cause desync?

Post all other topics which do not belong to any other category.
slippycheeze
Fast Inserter
Fast Inserter
Posts: 220
Joined: Sun Jun 09, 2019 10:40 pm
Contact:

Re: How does uranium processing not cause desync?

Post by slippycheeze » Thu Jul 04, 2019 1:16 pm

Zavian wrote:
Thu Jul 04, 2019 9:59 am
Ranger_Aurelien wrote:
Wed Jul 03, 2019 8:44 pm
As far as I recall the only other pseudorandom event in the game is the cooldown between sending out of settlement biters (each time randomly between 4-30 minutes).
https://wiki.factorio.com/World_generator
I thought that terrain generation and resource generation also used pseudo-random numbers.
They do. I presume that ranger meant "during play" rather than during world generation. ...but, ultimately, the answer to any of those things is that the same input means the same output for the PRNG that Factorio uses, and they use an absolutely deterministic sequence for updating things, so every client consumes the same random number output at the same time.

bobucles
Smart Inserter
Smart Inserter
Posts: 1578
Joined: Wed Jun 10, 2015 10:37 pm
Contact:

Re: How does uranium processing not cause desync?

Post by bobucles » Thu Jul 04, 2019 9:23 pm

Don't forget to check out the FFFs. The devs have talked about many of the obstacles they have overcome in game development. You may find some things on keeping random number generation not so random.

I don't know enough about factorio under the hood to say how they did it, but I imagine the answer is something like "very carefully". :lol: As long as you track all the values involved, protect them from unusual influences and include them in the save data, it's a good starting point.

User avatar
MeduSalem
Smart Inserter
Smart Inserter
Posts: 1339
Joined: Sun Jun 08, 2014 8:13 pm
Contact:

Re: How does uranium processing not cause desync?

Post by MeduSalem » Fri Jul 05, 2019 3:30 pm

slippycheeze wrote:
Tue Jul 02, 2019 10:16 pm
mmmPI wrote:
Tue Jul 02, 2019 10:05 pm
Rakshasa wrote:
Tue Jul 02, 2019 9:52 pm
Also computer can easily do random, just use the lowest bits from a camera feed. Enough quantum magic going on there.
Isn't that cheating like picking up random numbers from the lottery ? It feels to me like what would be random there would be the output of the feed, but that wouldn't require quantum magic.

I thought computers couldn't do true random, just non-predictable without so much time machine that it is considered safe enough to assume it look like random.
slippycheeze wrote:
Tue Jul 02, 2019 10:03 pm
Various tricks with tiny unconnected capacitors and stuff work too, and modern CPUs and/or motherboard chipsets have high quality randomness generators too.
Is that using quantum mechanics ?
The former, I understand yes. The later I don't know, but something close enough. It *could* be an NSA planted PRNG with a known key/seed using cryptography to generate apparently random output, but probably not. Like, maybe 80 percent. :)

Ultimately, like the camera feed deal, there are lots of things where quantum randomness is available, and we keep finding more confirmation that you can't fully know a quantum system externally.
From what I have read into CPU design documents 15 years ago when I was studying the field as a hobby most of them use temperature differences in a chip to various degrees with sensors or with capacitors/transistors that react differently fast with decreasing/increasing local temperature.

At least as far as I know none of them do really use quantum mechanical effects for it. So if there's like only one such "sensor" per core and the load constant then with a constant temperature the results might eventually become predictable though.

That said with the smaller facbrication nodes quantum mechanical effects like quantum tunneling come into play and maybe that effect can be used or is already used by newer CPUs... like if through the temperature differences the size of the gate shrinks/grows and then more or less electrons tunnel to the other side and cause leakage currents and stuff like that which can probably be measured and used for calculation.

In my opinion a better approach if it isn't used already by modern multicore CPUs would be if the random number generator would pick temperatures from several locations on the chip and manipulate it with another second locale temp from the local core so that other cores have it harder to predict the random number that other cores might generate. With multicore CPUs they are never equal everywhere and the load is also more unpredictable with dozens of processes running across the cores.


But to be honest, even if it might be against the accepted phyiscs science knowledge I kinda believe in a fully deterministic universe... and that there is no true randomness on quantum level, just our bad understanding of it.

Enough off-topic for one day.

slippycheeze
Fast Inserter
Fast Inserter
Posts: 220
Joined: Sun Jun 09, 2019 10:40 pm
Contact:

Re: How does uranium processing not cause desync?

Post by slippycheeze » Fri Jul 05, 2019 8:06 pm

MeduSalem wrote:
Fri Jul 05, 2019 3:30 pm
slippycheeze wrote:
Tue Jul 02, 2019 10:16 pm
mmmPI wrote:
Tue Jul 02, 2019 10:05 pm
Rakshasa wrote:
Tue Jul 02, 2019 9:52 pm
Also computer can easily do random, just use the lowest bits from a camera feed. Enough quantum magic going on there.
Isn't that cheating like picking up random numbers from the lottery ? It feels to me like what would be random there would be the output of the feed, but that wouldn't require quantum magic.

I thought computers couldn't do true random, just non-predictable without so much time machine that it is considered safe enough to assume it look like random.
slippycheeze wrote:
Tue Jul 02, 2019 10:03 pm
Various tricks with tiny unconnected capacitors and stuff work too, and modern CPUs and/or motherboard chipsets have high quality randomness generators too.
Is that using quantum mechanics ?
The former, I understand yes. The later I don't know, but something close enough. It *could* be an NSA planted PRNG with a known key/seed using cryptography to generate apparently random output, but probably not. Like, maybe 80 percent. :)

Ultimately, like the camera feed deal, there are lots of things where quantum randomness is available, and we keep finding more confirmation that you can't fully know a quantum system externally.
From what I have read into CPU design documents 15 years ago when I was studying the field as a hobby most of them use temperature differences in a chip to various degrees with sensors or with capacitors/transistors that react differently fast with decreasing/increasing local temperature.

At least as far as I know none of them do really use quantum mechanical effects for it. So if there's like only one such "sensor" per core and the load constant then with a constant temperature the results might eventually become predictable though.

That said with the smaller facbrication nodes quantum mechanical effects like quantum tunneling come into play and maybe that effect can be used or is already used by newer CPUs... like if through the temperature differences the size of the gate shrinks/grows and then more or less electrons tunnel to the other side and cause leakage currents and stuff like that which can probably be measured and used for calculation.

In my opinion a better approach if it isn't used already by modern multicore CPUs would be if the random number generator would pick temperatures from several locations on the chip and manipulate it with another second locale temp from the local core so that other cores have it harder to predict the random number that other cores might generate. With multicore CPUs they are never equal everywhere and the load is also more unpredictable with dozens of processes running across the cores.


But to be honest, even if it might be against the accepted phyiscs science knowledge I kinda believe in a fully deterministic universe... and that there is no true randomness on quantum level, just our bad understanding of it.

Enough off-topic for one day.
It is. Turns out the answer is "thermal is significantly involved, rarely the sole source, but it is complicated"; there is a bunch of information on the basic design out there on the web if anyone cares to know. Ivy Bridge is especially well documented, apparently. Thanks for encouraging me to go refresh my knowledge. :)

Post Reply

Return to “General discussion”

Who is online

Users browsing this forum: Google [Bot], sentetsu