Movatterモバイル変換


[0]ホーム

URL:


Jump to content
WikipediaThe Free Encyclopedia
Search

2,147,483,647

From Wikipedia, the free encyclopedia

Natural number
2147483647
Cardinaltwo billion one hundred forty-seven million four hundred eighty-three thousand six hundred forty-seven
Ordinal2147483647th
(two billion one hundred forty-seven million four hundred eighty-three thousand six hundred forty-seventh)
Factorizationprime
Prime105,097,565th
Greek numeralMκαδψμη{\displaystyle {\stackrel {\kappa \alpha \delta \psi \mu \eta }{\mathrm {M} }}}͵γχμζ´
Roman numeralN/A,n/a
Binary11111111111111111111111111111112
Ternary121121222121102021013
Senary5530320055316
Octal177777777778
Duodecimal4BB2308A712
Hexadecimal7FFFFFFF16
By 1772,Leonhard Euler had proven that 2,147,483,647 is aprime.

Thenumber2147483647 is the eighthMersenne prime, equal to 231 − 1. It is one of only four knowndouble Mersenne primes.[1]

Theprimality of this number was proven byLeonhard Euler, who reported the proof in a letter toDaniel Bernoulli written in 1772.[2] Euler usedtrial division, improving onPietro Cataldi's method, so that at most 372 divisions were needed.[3] It thus improved upon the previous record-holding prime, 6,700,417 – also discovered by Euler – forty years earlier. The number 2,147,483,647 remained thelargest known prime until 1867.[4]

In computing, this number is the largest value that asigned32-bit integer field can hold.

Barlow's prediction

[edit]

At the time of its discovery, 2,147,483,647 was thelargest known prime number. In 1811,Peter Barlow wrote (inAn Elementary Investigation of the Theory of Numbers):

Euler ascertained that 231 − 1 = 2147483647 is a prime number; and this is the greatest at present known to be such, and, consequently, the last of the aboveperfect numbers [i.e., 230(231 − 1)], which depends upon this, is the greatest perfect number known at present, and probably the greatest that ever will be discovered; for as they are merely curious, without being useful, it is not likely that any person will attempt to find one beyond it.[5]

He repeated this prediction in his work from 1814,A New Mathematical and Philosophical Dictionary.[6][7]

A larger prime, 67,280,421,310,721, was discovered in 1855 byThomas Clausen, but he did not provide a proof. In 1867, the number 3,203,431,780,337 was proven to be prime.[4]

In computing

[edit]

The number 2,147,483,647 (orhexadecimal 7FFFFFFF16) is the maximum positive value for a32-bitsigned binary integer incomputing. It is therefore the maximum value for variables declared as integers (e.g., asint) in many programming languages.

The data typetime_t, used on operating systems such asUnix, is a signed integer counting the number of seconds since the start of theUnix epoch (midnightUTC of 1 January 1970), and is often implemented as a 32-bit integer.[8] The latest time that can be represented in this form is 03:14:07 UTC on Tuesday, 19 January 2038 (corresponding to 2,147,483,647 seconds since the start of the epoch). This means that systems using a 32-bittime_t type are susceptible to theYear 2038 problem.[9]

On 1 January 2022, a bug was reported forMicrosoft Exchange systems where email delivery would fail. An internal malware scanner (enabled by default since 2013) used the date and time as a signed 32-bit integer. The integer would change during the new year to 2,201,010,001 (with the first two digits representing the year), surpassing the maximum value for this data type.[10]

In video games

[edit]

The number 2,147,483,647 often becomes a hard limit for various statistics in video games, such as points or money, if they are represented by signed 32-bit integers (rather thanfloating-point,double-precision orarbitrary-precision).[11][12] Going over this limit by legitimate means, or by modding or hacking the game, results in many different outcomes caused byinteger overflow.[13] The most common outcome is the number "wrapping" into the negatives. Another potential outcome isgame crashing, thus meaning there was no failsafe implemented in the event the value exceeds the signed 32-bit limit—generally if the underlying engine has undefined behavior, instead of a wraparound behavior, for integer overflow. A well-known example in video games is that ofOld School RuneScape andGrand Theft Auto V, where the number is used as the maximum amount of coins (or any other item) that a player can hold at once with normal methods, known as a "max cash stack".[14][15] In similar cases, where anunsigned instead of signed 32-bit integer is used, the limit might be extended to4,294,967,295.[11]

References

[edit]
  1. ^Weisstein, Eric W."Double Mersenne Number".MathWorld. Wolfram Research. Retrieved29 January 2018.
  2. ^Dunham, William (1999).Euler: the master of us all. The Dolciani mathematical expositions. Washington, D.C.:Mathematical Association of America. p. 4.ISBN 978-0-88385-328-3.
  3. ^Gautschi, Walter (1994). Gautschi, Walter (ed.).Mathematics of computation, 1943-1993: a half-century of computational mathematics ; Mathematics of Computation 50th Anniversary Symposium, August 9-13, 1993, Vancouver, British Columbia. Proceedings of symposia in applied mathematics. Vol. 48. Providence, RI:American Mathematical Society. p. 486.ISBN 978-0-8218-0291-5.
  4. ^abCaldwell, Chris (8 December 2009)."The Largest Known Prime by Year: A Brief History".The Prime Pages. University of Tennessee at Martin. Retrieved29 January 2018.
  5. ^Barlow, Peter (1811).An Elementary Investigation of the Theory of Numbers. London: J. Johnson & Co. p. 43.OCLC 1191003275.
  6. ^Barlow, Peter (1814).A New Mathematical and Philosophical Dictionary: Comprising an Explanation of Terms and Principles of Pure and Mixed Mathematics, and Such Branches of Natural Philosophy as Are Susceptible of Mathematical Investigation. London: G. and S. Robinson.OCLC 889473251.
  7. ^Shanks, Daniel (2001).Solved and Unsolved Problems in Number Theory (4th ed.). Providence, Rhode Island:American Mathematical Society. p. 495.ISBN 978-0-8218-2824-3.
  8. ^"The Open Group Base Specifications Issue 6 IEEE Std 1003.1, 2004 Edition (definition of epoch)".IEEE andThe Open Group.The Open Group. 2004.Archived from the original on 19 December 2008. Retrieved7 March 2008.
  9. ^"The Year-2038 Bug".Archived from the original on 18 March 2009. Retrieved9 April 2009.
  10. ^Abrams, Lawrence (1 January 2022)."Microsoft Exchange year 2022 bug in FIP-FS breaks email delivery".Bleeping Computer. Retrieved2 January 2022.
  11. ^abLever, Nik (6 August 2012).Director MX 2004 Games: Game Development with Director. Taylor & Francis.ISBN 978-1-136-14525-4.
  12. ^Cockfield, Bryan (19 September 2018)."Final Fantasy Exploit Teaches 32-bit Integer Math".Hackaday. Retrieved25 September 2022.
  13. ^Byrne, Michael (12 April 2015)."32-Bit Integers and Why Old Computers Matter".Vice. Retrieved25 September 2022.
  14. ^"Coins".Runescape Official Wiki.
  15. ^Wood, Austin (12 July 2018)."Old School Runescape pulled offline as billions of gold appear out of nowhere".PC Gamer. Retrieved25 September 2022.it's appropriate to check that the calculation doesn't overflow the max integer limit of the game's language (2.1 billion). Unfortunately, the logic used for this calculation was incorrect, and when executed on stacks of other items (not the pouch itself) the result was to convert the stack to 2.1b coins.

External links

[edit]
Retrieved from "https://en.wikipedia.org/w/index.php?title=2,147,483,647&oldid=1287350527"
Category:
Hidden categories:

[8]ページ先頭

©2009-2025 Movatter.jp