Randomness: Difference between revisions

From Helpful
Jump to navigation Jump to search
(Created page with "<!-- When we say 'random', people have different specific senses. The main one is probably '''unpreadictable'''. Sequences that have effects but no cause, if you will....")
 
mNo edit summary
 
(2 intermediate revisions by the same user not shown)
Line 5: Line 5:
When we say 'random', people have different specific senses.
When we say 'random', people have different specific senses.


The main one is probably '''unpreadictable'''.  
 
The main one is probably '''unpredictable'''.


Sequences that have effects but no cause, if you will.
Sequences that have effects but no cause, if you will.
Line 16: Line 17:
This is arguably the mathematical or philosophical view.
This is arguably the mathematical or philosophical view.


Another is '''not like last time'''
With a lot of choices, that's likely to happen.
But
Consider putting a playlist on random. If it picked a new song randomly each time, it might pick the same thing twice in a row.
If it didn't, that would be a pattern and less ''technically'' random.
But people will question it, plus it's not the functionality we wanted here.
So music players tend to shuffle, or at the very least just keep a memory of the last few played songs.
Consider picking eight numbers between 1 and 100
5,5,5,5,5,5,5,5
is exactly as likely as every other sequence of eight numbers.
However, 99.999+% of the other 100 million don't look like a pattern to us,
so our eyes draw past those as noise and we don't question them.
But we do question this one.




Line 21: Line 40:
Another is '''evenly spread'''
Another is '''evenly spread'''


This is sort of implied from the last: if all outcomes weren't equally likely,
This is sort of implied from 'unpredictable': if all outcomes weren't equally likely,
that would be ''some'' sort  of pattern, and on average you would be albe to guessing the next event some of the time.
that would be ''some'' sort  of pattern. You wouldn't be able to guess the next output,
but you would be able to guess which ones would appear more often.


Unpredictable ''roughly'' implies evenly spread, but that only goes in one direction.
Unpredictable ''roughly'' implies evenly spread.
(this only goes in one direction: evenly spread does not mean random. Sometimes obvious, sometimes worth noting).




That said, there is such a thing as weighed randomness.  
 
There is such a thing as weighed randomness.  
Say, if you know the probability of an event has a gaussian probability, and/or gaussian error,
Say, if you know the probability of an event has a gaussian probability, and/or gaussian error,
and you want to simulate that, then it is very useful to get random numbers that, when you make a histogram of them,
and you want to simulate that, then it is very useful to get random numbers that, when you make a histogram of them,
Line 34: Line 56:
This is arguably the statistical view.
This is arguably the statistical view.


In fact, you can do this not only with gaussian, but with any distribution.
A [[probability mass function]] is basically already the input you want: a list of (probability, value) pairs.




Is there a difference?


Absolutely.
 
 
 
Do these distinctions really matter?
 
Depending on the application, absolutely.


Consider [[pseudo-random number generators]].  
Consider [[pseudo-random number generators]].  
They give a very good spread (and, in a practical sense, give numbers very quickly), yet are fully deterministic.  
They give a very good spread (and, in a practical sense, give numbers very quickly), yet are fully deterministic.  


You would need to learn something you cannot easily determine from just a few numbers of output (or even a lot),
In a practical sense it is not necessarily easy to learn from just observation where it is in that deterministic process.
yet once you do, you can fully predict what it will output next.  
Yet once you do, you can fully predict what it will output next. And after that, etc.


In e.g. testing some functions with some data, this is not at all an issue.  It's fast, it did the testing.


In e.g. cryptography, ''this is not good enough'' (depending a little on what you're doing).
In e.g. cryptography, ''this is not good enough'' (depending a little on what you're doing).


Which is roughly why people make a big fuss of hardware based randomness.
Which is roughly why people make a big fuss of hardware-based randomness.
It's not perfect, but it's a lot better
It's not perfect, but it's a lot better






-->
-->

Latest revision as of 17:35, 18 April 2024