This site is supported by donations to The OEIS Foundation.

Weird numbers

From OeisWiki
Jump to: navigation, search

This article page is a stub, please help by expanding it.

A weird number is an abundant number that is not pseudoperfect (semiperfect). For example, the proper divisors of 70 (the first weird number) are 1, 2, 5, 7, 10, 14, 35, and these add up to 74, which is 4 more than 70, meaning that 70 is abundant. But there is no sum of two or more proper divisors of 70 that adds up to 70, so 70 is not pseudoperfect and is thus called a weird number. (A018270 gives the divisors of 70.)

A006037 Weird numbers: abundant (A005101) but not pseudoperfect (A005835).

{70, 836, 4030, 5830, 7192, 7912, 9272, 10430, 10570, 10792, 10990, 11410, 11690, 12110, 12530, 12670, 13370, 13510, 13790, 13930, 14770, 15610, 15890, 16030, 16310, 16730, ...}

All the known weird numbers are even, see below about the search for odd weird numbers. A weird number multiplied by a prime larger than its sum of divisors is again weird, so there are infinitely many weird numbers. Primitive weird numbers are those which do not have a weird proper divisor,

A002975 = {70, 836, 4030, 5830, 7192, 7912, 9272, 10792, 17272, 45356, 73616, 83312, 91388, 113072, 243892, 254012, 338572, 343876, 388076, 519712, 539744, 555616, 682592, 786208, 1188256, 1229152, 1713592, 1901728, 2081824, 2189024, 3963968, 4128448, ...}.

From what follows it seems evident that this set is infinite, and this has been shown under quite weak conditions, e.g., assuming Cramer's conjecture, [Melfi 2015], but it is not yet unconditionally proved.

Odd weird numbers

All the known weird numbers are even. Robert A. Hearn has verified that there are no odd weird numbers up to [reference ?] Several distributed computation projects have pushed the search limit to 10^21, see the external links for "Odd weird search" and Oproject.

Primitive weird numbers

A weird number multiplied by a large prime again yields a weird number, therefore most studies focus on primitive weird numbers A002975 which do not have a weird proper divisor.

A weird number must have at least three distinct prime divisors, since any number of the form p^k q^m is either deficient (A005100) or pseudoperfect (A005835).

Therefore the set A002975 can be split up into the well studied subset A258882 of terms of the form 2^k*p*q where p and q are odd primes, and the complement A258401 of all other terms, i.e., having at least 3 odd prime factors, counted with multiplicity. The latter has subsets A258883 (2^k*p*q*r), A258884 (2^k*p*q*r*s), A258885 (six distinct prime factors) and others.

The smallest primitive weird numbers with n prime factors are listed in A258374 (n distinct prime divisors) and A258375 (n prime factors counted with multiplicity). The former has only four known terms, a(3) through a(6), while the latter seems to coincide with the sequence of the smallest weird number of the form 2^(n-2) p q.

As of today, no weird number divisible by 3 is known. Sequence A265727 lists the least primitive weird number divisible by the n-th prime, for n >= 3.

Weird numbers of the form 2^k p q

Let us denote by W2(k) the set of weird numbers of the form 2^k*p*q with odd primes p, q. Such weird numbers are always primitive. The two odd prime factors are necessarily distinct, and by convention we will tacitly understand that p < q. We have

Sequence A258882 is the union of all W2(k).

Sequence A258333 = (1, 1, 5, 3, 10, 23, 29, 53, 115, ...) counts the number of terms in W2(k), known to be finite for all k. It is known that the primes p and q verify

and also

We find that all weird numbers of the form 2^k p q have p very close to this upper limit, i.e., the elements of W2(k) lie close to the (shifted) parabola p = M + M²/(q - M), 2M < q < M(M+1).

[insert a plot here?]

If we let d = q - 2 M then we find , so distance(p*, 2M) = distance(q, 2M) as long as d² < M.

If we define γ = q/M then we get : We already saw that p ~ 2M when q ~ 2M, and we find p* ~ q/2 when q = 3M, p* ~ q/3 when q = 4M, p* ~ q/4 when q = 5M, etc. (One finds that only for such special values of q, we may have "holes" in the list of p values which yield weird 2^k p q for given q. In the general case, if both 2^k p q and 2^k p' q are weird, then 2^k p" q is weird for all p" between p and p'.)

The following facts are well confirmed by experiment, but not unconditionally proved:

For all k, the largest term in W2(k) is of the form 2^k p q with p = nextprime(M+1). So there is always at least one weird 2^k p q with this prime p. Moreover, for larger k, there are increasingly more terms in (among the largest terms in that set) having this p as a factor.

Example: For k = 5, nextprime(M+1) = 67, and we see that the three largest terms in do have p = 67.

  • For k = 1, 2, 3, 4, the smaller odd prime factor of max W2(k) is 5 = nextprime(4), 11 = nextprime(8), 17 = nextprime(16) and 37 = nextprime(32). (Note that even when M is a (Mersenne) prime, p cannot take this value.)

Most values of q which yield some weird 2^k p q, do yield a weird 2^k p q for . For all terms listed above, i.e., k <= 5, one always has .

Weird numbers with more odd prime factors

We recall that A258401 is the set of primitive weird numbers not of the form 2^k*p*q, i.e., having at least 3 odd prime factors, counted with multiplicity. It includes as somehow "simplest" elements the weird numbers of the form 2^k p^2 q, where p and q are odd primes, e.g., A258401(45) = 2319548096 = 2^6 * 137^2 * 1931 or A258401(143) = 232374697216 = 2^8 * 797^2 * 1429. Other subsets are A258883 (2^k*p*q*r: four distinct prime factors), A258884 (2^k*p*q*r*s: five distinct prime factors) and A258885 (six distinct prime factors).

As already mentioned, A258374 lists the least primitive weird number with n distinct prime factors.

Melfi et al. (2015) have found primitive weird numbers with many prime factors.

Other Sequences

A005835 Pseudoperfect (or semiperfect) numbers : some subset of the proper divisors of sums to . (Perfect numbers and pseudoperfect [abundant] numbers.)

{6, 12, 18, 20, 24, 28, 30, 36, 40, 42, 48, 54, 56, 60, 66, 72, 78, 80, 84, 88, 90, 96, 100, 102, 104, 108, 112, 114, 120, 126, 132, 138, 140, 144, 150, 156, 160, 162, 168, ...}

Note that 945 (the 233rd pseudoperfect number) is the first odd pseudoperfect number, all odd numbers less than 945 being deficient (obviously a deficient number can't be pseudoperfect!).

The set union of A005835 (pseudoperfect numbers) and A006037 (weird numbers) gives the nondeficient numbers (perfect numbers and abundant numbers).

See also



  • G. Melfi, On the conditional infiniteness of primitive weird numbers, Journal of Number Theory, Volume 147, February 2015, Pages 508-514.
  • S. J. Benkoski and P. Erdős, On weird and pseudoperfect numbers, Math. Comp., 28 (1974), pp. 617-623 (and 1975 corrigendum).
  • Douglas E. Iannucci, On primitive weird numbers of the form 2^k*p*q, arXiv:1504.02761 [math.NT], 2015.

External links


Cite this as

D. Forgues, M. F. Hasler and others, Weird numbers. — From the On-Line Encyclopedia of Integer Sequences® (OEIS®) wiki. (Available at