# Random number

> Mediated Wiki article. Canonical URL: https://mediated.wiki/source/Random_number
> Markdown URL: https://mediated.wiki/source/Random_number.md
> Source: https://en.wikipedia.org/wiki/Random_number
> Source revision: 1353785739
> License: Creative Commons Attribution-ShareAlike 4.0 International (https://creativecommons.org/licenses/by-sa/4.0/)

{{Short description|Number generated by a random process}}
{{Use mdy dates|date=July 2020}}
{{Use American English|date=July 2020}}

[[File:Two red dice 01.svg|thumb|[Dice](/source/Dice) are an example of a mechanical hardware random number generator. When a cubical die is rolled, a random number from 1 to 6 is obtained.|alt=]]

A '''random number''' is generated by a random ([stochastic](/source/Stochastic_process)) process such as throwing dice. Individual numbers cannot be predicted, but the likely result of generating a large quantity of numbers can be predicted by specific mathematical series and [statistics](/source/statistics).

==Algorithms and implementations==
Random numbers are frequently used in [algorithm](/source/algorithm)s such as [Knuth's](/source/Donald_Knuth) 1964-developed [algorithm](/source/algorithm)<ref>{{cite journal |author=Richard Durstenfeld
|title=Algorithm 235: Random permutation |doi=10.1145/364520.364540
|journal=[Communications of the ACM](/source/Communications_of_the_ACM)
|volume=7 |issue=7 |page=420 |date=July 1964}}</ref> for shuffling lists. (popularly known as ''the [Knuth](/source/Donald_Knuth) shuffle'' or ''the [Fisher–Yates shuffle](/source/Fisher%E2%80%93Yates_shuffle)'', based on work they did in 1938).

In 1999, a new feature was added to the [Pentium III](/source/Pentium_III): a hardware-based [random number generator](/source/random_number_generator).<ref name=Random.NetwCom99>
   {{cite magazine  |magazine=[Network Computing](/source/Network_Computing)
   |title=Privacy's Random Nature
   |author=Robert Moscowitz  |date=July 12, 1999}}</ref><ref name=RandomPenIII.Wired99>{{cite magazine  |magazine=[Wired](/source/Wired_(magazine))
|url=https://www.wired.com/1999/01/hardwiring-security
|title=Hardwiring Security  |date=January 1999}}</ref> It has been described as "several [oscillators](/source/oscillators) combine their outputs and that odd waveform is sampled asynchronously."<ref>{{cite web
   |url=http://www.ciphersbyritter.com/NEWS4/PENTRAND.HTM
   |author=Terry Ritter  |date=January 21, 1999
   |title=The Pentium III RNG}}</ref> These numbers, however, were only 32 bit, at a time when export controls were on 56 bits and higher, so they were not state of the art.<ref>{{cite web 
|url=https://www.irisa.fr/caps/projects/hipsor/misc.php
|title=Unpredictable Randomness Definition |website=IRISA}}</ref>

==Common understanding==
In common understanding, "1 2 3 4 5" is not as random as "3 5 2 1 4" and certainly not as random as "47 88 1 32 41" but "we can't say authoritavely that the first sequence is not random ... it could have been generated by chance."<ref name=RandomArticle.SS1998>
{{cite magazine |magazine=Sun Server
    |title=Javatalk: Horseshoes, hand grenades and random numbers
    |author=Jonathan Knudson |date=January 1998 |pages=16–17}}</ref>

When a police officer claims to have done a "random .. door-to-door" search, there is a certain expectation that members of a jury will have.<ref>
{{cite news  
   |newspaper=[Los Angeles Times](/source/Los_Angeles_Times)
   |url=https://www.latimes.com/archives/la-xpm-1995-04-16-mn-55166-story.html
   |title=NYPD Bad Cop's Illegal Search Mars Career
   |author=Tom Hays  |date=April 16, 1995}}</ref><ref>A pre-compiled list of apartment numbers would be a violation thereof.</ref>{{examples|date=December 2022}}

==Real world consequences==
Flaws in ''randomness'' have real-world consequences.<ref name=RandomArticle_Encr.NYT2012>{{cite news
   |newspaper=[New York Times](/source/New_York_Times)
   |url=https://www.nytimes.com/2012/02/15/technology/researchers-find-flaw-in-an-online-encryption-method.html
   |title=Flaw Found in an Online Encryption Method
   |author=John Markoff  |date=February 14, 2012}}</ref><ref name=RandomArticle_Lott.NYT2012>{{cite news
|newspaper=[New York Times](/source/New_York_Times)
|url=https://www.nytimes.com/interactive/2018/05/03/magazine/money-issue-iowa-lottery-fraud-mystery.html
|title=The man who cracked the lottery
|author=Reid Forgrave  |date=May 3, 2018}}</ref>

A 99.8% randomness was shown by researchers to negatively affect an estimated 27,000 customers of a large service<ref name=RandomArticle_Encr.NYT2012/> and that the problem was not limited to just that situation.{{clarify|date=December 2022}}

==See also==
* [Algorithmically random sequence](/source/Algorithmically_random_sequence)
* [Quasi-random sequence](/source/Quasi-random_sequence)
* [Random number generation](/source/Random_number_generation)
** [Non-uniform random number generation](/source/Non-uniform_random_number_generation)
* [Random real](/source/Random_real)
* [Random sequence](/source/Random_sequence)
* [Random variable](/source/Random_variable)
* [Random variate](/source/Random_variate)

==References==
{{Reflist}}

{{Authority control}}

Category:Permutations

---
Adapted from the Wikipedia article [Random number](https://en.wikipedia.org/wiki/Random_number) by Wikipedia contributors ([contributor history](https://en.wikipedia.org/wiki/Random_number?action=history)). Available under [Creative Commons Attribution-ShareAlike 4.0 International](https://creativecommons.org/licenses/by-sa/4.0/). Changes may have been made.
