Skip to content

bobdinh139/TryYourLuckTuesday

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

powered by random.org ( librandom.org-client ), fourmilab.ch (libfourmilab.ch-client) and json-simple-1.1

It is further developed at @frychicken

Probably will not receive updates because it meets all the requirements for the lucky tuesday event.

Another loop?

I will not spam server with requests. Make another loop to check for duplicates to change the set of numbers is worthless.

I wrote the whole UI from scratch, there is no reason for me to not just write a simple loop if I think it is necessary, but it is not and it is pointless.

I have doubts

RANDOM.ORG has something to say:

You could argue that the atmospheric noise used as a source for the RANDOM.ORG numbers can be viewed as a chaotic but deterministic system.

Hence, if you knew enough about the processes that cause atmospheric noise (e.g., thunderstorms) you could potentially predict the numbers generated by RANDOM.ORG.

However, to do this, you would probably need knowledge of the position and velocity of every single molecule in the planet's weather systems.

This is of course infeasible, and the inaccuracy of weather forecasts is a good example of how difficult it is to give even a rough estimate of the behaviour of weather systems.

For this reason, it is impractical to predict random numbers from RANDOM.ORG, even for a determinist. A similar case (on a different scale) could be made for random number generators based on lava lamps.

Regarding radioactive decay

There exists the fact that: Radioactive decay is a random process. As a result, it is impossible to predict when a particular radioactive nucleus will decay.

But half-life?

According to symmetrymagazine.org

Statistically, a cesium-137 atom has a fifty-fifty chance of decaying in 30.17 years. BUT, there is absolutely, positively no way to predict exactly when any individual atom will decay.

Odd, right? While the whole batch obeys a statistic, each atom’s decay time is totally unpredictable.

How it works?

According to symmetrymagazine.org

The Hotbits program is based on the premise that since the decaying of each atom is random, the time between decay events is also random.

Hotbits measures the time between two atoms decaying, then the time between the next two atoms decaying (a total of four events, not three, to avoid a bias the author explains ). If time one is less than time two, that gets a zero.

If time two is shorter, that gets a one. The result is a sequence of genuinely random numbers.

=> Therefore, the number ranging from 0 - 255 (8 bit)

How I convert to the range of 0-20?

This method is deprecated

if the number is bigger than 20 and smaller than (or equal to) 200, divide the integer by 10, then round it. After that, subtract the number by 2, take the absolute value of it. If the number is smaller than 0, number is 0

if the number from 201 to 220, remove the first number; if the number from 221 to 240, remove the first number and subtract the remaining by 2.

if the number from 240 t0 255, generate a pseudo random number from 0 to 20 with the seed of that number.

New method

Use pseudo random number with radioactive as seed.

Check out the chart

About

For school project, basically random number generator

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages