PerfectNumber

PerfectNumber[n]

gives the n^(th) perfect number.

Details

  • A perfect number is a positive integer that is equal to half the sum of its divisors.
  • In PerfectNumber[n], n must be a positive integer.
  • As of this version of the Wolfram Language, only 51 perfect numbers are known. PerfectNumber[n] will attempt to find perfect numbers for any n, but cannot be expected to return results in a reasonable time for .
  • PerfectNumber[n,"Even"] gives the n^(th) even perfect number. As of this version of the Wolfram Language, the first 48 even perfect numbers are known, and 3 more whose position n is not yet certain. PerfectNumber[n,"Even"] will attempt to find even perfect numbers for , but cannot be expected to return results in a reasonable time.
  • PerfectNumber[n,"Odd"] will attempt to find the n^(th) odd perfect number. As of this version of the Wolfram Language, no odd perfect number is known, and PerfectNumber[n,"Odd"] cannot be expected to return a result. There are no odd perfect numbers less than the 18^(th) even perfect number.

Examples

open allclose all

Basic Examples  (1)

Return the first 10 perfect numbers:

Scope  (1)

PerfectNumber automatically threads over lists:

Properties & Relations  (4)

Even perfect numbers are related to Mersenne prime exponents:

Even perfect numbers are triangular numbers related to Mersenne prime exponents:

Even perfect numbers are also hexagonal numbers related to Mersenne prime exponents:

All even perfect numbers greater than 6 are of the following form for some value of k:

Even perfect numbers end in either 6 or 28:

Plot the integer length of the first 47 even perfect numbers:

Possible Issues  (2)

As of this version of the Wolfram Language, no odd perfect number is known:

As of this version of the Wolfram Language, the first 48 even perfect numbers are known:

But in total, 51 even perfect numbers are known:

Wolfram Research (2016), PerfectNumber, Wolfram Language function, https://reference.wolfram.com/language/ref/PerfectNumber.html (updated 2024).

Text

Wolfram Research (2016), PerfectNumber, Wolfram Language function, https://reference.wolfram.com/language/ref/PerfectNumber.html (updated 2024).

CMS

Wolfram Language. 2016. "PerfectNumber." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2024. https://reference.wolfram.com/language/ref/PerfectNumber.html.

APA

Wolfram Language. (2016). PerfectNumber. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/PerfectNumber.html

BibTeX

@misc{reference.wolfram_2024_perfectnumber, author="Wolfram Research", title="{PerfectNumber}", year="2024", howpublished="\url{https://reference.wolfram.com/language/ref/PerfectNumber.html}", note=[Accessed: 22-November-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_perfectnumber, organization={Wolfram Research}, title={PerfectNumber}, year={2024}, url={https://reference.wolfram.com/language/ref/PerfectNumber.html}, note=[Accessed: 22-November-2024 ]}