A005153
Practical numbers: positive integers m such that every k <= sigma(m) is a sum of distinct divisors of m. Also called panarithmic numbers.
Original entry on oeis.org
1, 2, 4, 6, 8, 12, 16, 18, 20, 24, 28, 30, 32, 36, 40, 42, 48, 54, 56, 60, 64, 66, 72, 78, 80, 84, 88, 90, 96, 100, 104, 108, 112, 120, 126, 128, 132, 140, 144, 150, 156, 160, 162, 168, 176, 180, 192, 196, 198, 200, 204, 208, 210, 216, 220, 224, 228, 234, 240, 252
Offset: 1
- H. Heller, Mathematical Buds, Vol. 1, Chap. 2, pp. 10-22, Mu Alpha Theta OK, 1978.
- Malcolm R. Heyworth, More on Panarithmic Numbers, New Zealand Math. Mag., Vol. 17 (1980), pp. 28-34 [ ISSN 0549-0510 ].
- Ross Honsberger, Mathematical Gems, M.A.A., 1973, p. 113.
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- A. K. Srinivasan, Practical numbers, Current Science, 17 (1948), 179-180.
- James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, pages 146-147.
- Amiram Eldar, Table of n, a(n) for n = 1..10000 (terms 1..1000 from T. D. Noe)
- Thomas Bloom, Problem 18, Erdős Problems.
- Wayne Dymacek, Letter to N. J. A. Sloane, Jun 15 1978.
- David Eppstein, Egyptian fractions with practical denominators, Nov 20, 2016
- David Eppstein, Making Change in 2048, arXiv:1804.07396 [cs.DM], 2018.
- Paul Erdős, On a Diophantine equation (in Hungarian, with Russian and English summaries), Mat. Lapok, Vol. 1 (1950), pp. 192-210.
- Paul Erdős and J. H. Loxton, Some problems in partitio numerorum, Journal of the Australian Mathematical Society, Vol. 27, No. 3 (1979), pp. 319-331.
- James Grimes and Brady Haran, Practical Numbers, Numberphile video (2023).
- Harvey J. Hindin, Quasipractical numbers, IEEE Communications Magazine, Vol. 18, No. 2 (March 1980), pp. 41-45.
- Paolo Leonetti and Carlo Sanna, Practical numbers among the binomial coefficients, Journal of Number Theory, Vol. 207 (2020), pp. 145-155; arXiv preprint, arXiv:1905.12023 [math.NT], 2019.
- Maurice Margenstern, Sur les nombres pratiques, (in French), Groupe d'étude en théorie analytique des nombres, 1 (1984-1985), Exposé No. 21, 13 p.
- Maurice Margenstern, Les nombres pratiques: théorie, observations et conjectures, Journal of Number Theory, Volume 37, Issue 1 (January 1991), pp. 1-36.
- C. McLeman, Practical number, PlanetMath.org.
- Giuseppe Melfi, On two conjectures about practical numbers, J. Number Theory, Vol. 56, No. 1 (1996), pp. 205-210 [MR96i:11106].
- Giuseppe Melfi, On certain positive integer sequences, arXiv:0404555 [math.NT], 2004.
- Giuseppe Melfi, A survey on practical numbers, Rend. Sem. Mat. Univ. Politec. Torino, Vol. 53, No. 4 (1995), pp. 347-359.
- Giuseppe Melfi, Practical Numbers (old link).
- Paul Pollack and Lola Thompson, Practical pretenders, arXiv:1201.3168 [math.NT], Jan 16 2012.
- Carl Pomerance, Lola Thompson and Andreas Weingartner, On integers n for which X^n-1 has a divisor of every degree, arXiv:1511.03357 [math.NT], 2015.
- Carl Pomerance and Andreas Weingartner, On primes and practical numbers, Ramanujan J. (2021); arXiv preprint, arXiv:2007.11062 [math.NT], 2020.
- Eric Saias, Entiers à diviseurs denses 1, J. Number Theory, Vol. 62, No. 1 (1997), pp. 163-191; uses this definition.
- Carlo Sanna, Practical central binomial coefficients, arXiv:2004.05376 [math.NT], 2020.
- Sai Teja Somu, Ting Hon Stanford Li, and Andrzej Kukla, On Some Results on Practical Numbers, INTEGERS, Volume 23, A68, 2023 [MR4643065].
- Sai Teja Somu and Duc Van Khanh Tran, On Sums of Practical Numbers and Polygonal Numbers, arXiv:2403.13533 [math.NT], 2024.
- A. K. Srinivasan, Practical numbers, Current Science, 17 (1948), 179-180.
- B. M. Stewart, Sums of distinct divisors, Amer. J. Math., Vol. 76, No. 4 (1954), pp. 779-785 [MR64800]
- Zhi-Wei Sun, A conjecture on unit fractions involving primes, preprint, 2015.
- Terence Tao, Erdős problem database, see entry no. 18.
- Peter Taylor, Table of n, a(n) for n = 1..1000000.
- Andreas Weingartner, Practical numbers and the distribution of divisors, The Quarterly Journal of Mathematics, Vol. 66, No. 2 (2015), pp. 743-758; arXiv preprint, arXiv:1405.2585 [math.NT], 2014-2015.
- Andreas Weingartner, The constant factor in the asymptotic for practical numbers, Int. J. Number Theory, 16 (2020), no. 3, 629-638; arXiv preprint, arXiv:1906.07819 [math.NT], 2019.
- Andreas Weingartner, Uniform distribution of alpha*n modulo one for a family of integer sequences, arXiv:2303.16819 [math.NT], 2023.
- Eric Weisstein's World of Mathematics, Practical Number.
- Wikipedia, "Complete" sequence. [Wikipedia calls a sequence "complete" (sic) if every positive integer is a sum of distinct terms. This name is extremely misleading and should be avoided. - _N. J. A. Sloane_, May 20 2023]
- Wikipedia, Practical number.
- Robert G. Wilson v, Letter to N. J. A. Sloane, date unknown.
-
a005153 n = a005153_list !! (n-1)
a005153_list = filter (\x -> all (p $ a027750_row x) [1..x]) [1..]
where p _ 0 = True
p [] _ = False
p ds'@(d:ds) m = d <= m && (p ds (m - d) || p ds m)
-- Reinhard Zumkeller, Feb 23 2014, Oct 27 2011
-
isA005153 := proc(n)
local ifs,pprod,p,i ;
if n = 1 then
return true;
elif type(n,'odd') then
return false ;
end if;
# not using ifactors here directly because no guarantee primes are sorted...
ifs := ifactors(n)[2] ;
pprod := 1;
for p in sort(numtheory[factorset](n) ) do
for i in ifs do
if op(1,i) = p then
if p > 2 and p > 1+numtheory[sigma](pprod) then
return false ;
end if;
pprod := pprod*p^op(2,i) ;
end if;
end do:
end do:
return true ;
end proc:
for n from 1 to 300 do
if isA005153(n) then
printf("%d,",n) ;
end if;
end do: # R. J. Mathar, Jul 07 2023
-
PracticalQ[n_] := Module[{f,p,e,prod=1,ok=True}, If[n<1 || (n>1 && OddQ[n]), False, If[n==1, True, f=FactorInteger[n]; {p,e} = Transpose[f]; Do[If[p[[i]] > 1+DivisorSigma[1,prod], ok=False; Break[]]; prod=prod*p[[i]]^e[[i]], {i,Length[p]}]; ok]]]; Select[Range[200], PracticalQ] (* T. D. Noe, Apr 02 2010 *)
-
is_A005153(n)=bittest(n,0) && return(n==1); my(P=1); n && !for(i=2,#n=factor(n)~,n[1,i]>1+(P*=sigma(n[1,i-1]^n[2,i-1])) && return) \\ M. F. Hasler, Jan 13 2013
-
from sympy import factorint
def is_A005153(n):
if n & 1: return n == 1
f = factorint(n) ; P = (2 << f.pop(2)) - 1
for p in f: # factorint must have prime factors in increasing order
if p > 1 + P: return
P *= p**(f[p]+1)//(p-1)
return True # M. F. Hasler, Jan 02 2023
-
from sympy import divisors;from more_itertools import powerset
[i for i in range(1,253) if (lambda x:len(set(map(sum,powerset(x))))>sum(x))(divisors(i))] # Nicholas Stefan Georgescu, May 20 2023
More terms from Pab Ter (pabrlos(AT)yahoo.com), May 09 2004
Erroneous comment removed by
T. D. Noe, Nov 14 2010
Definition changed to exclude n = 0 explicitly by
M. F. Hasler, Jan 19 2013
A119347
Number of distinct sums of distinct divisors of n. Here 0 (as the sum of an empty subset) is excluded from the count.
Original entry on oeis.org
1, 3, 3, 7, 3, 12, 3, 15, 7, 15, 3, 28, 3, 15, 15, 31, 3, 39, 3, 42, 15, 15, 3, 60, 7, 15, 15, 56, 3, 72, 3, 63, 15, 15, 15, 91, 3, 15, 15, 90, 3, 96, 3, 63, 55, 15, 3, 124, 7, 63, 15, 63, 3, 120, 15, 120, 15, 15, 3, 168, 3, 15, 59, 127, 15, 144, 3, 63, 15, 142, 3, 195, 3, 15, 63, 63
Offset: 1
a(5)=3 because the divisors of 5 are 1 and 5 and all the possible sums: are 1,5 and 6; a(6)=12 because we can form all sums 1,2,...,12 by adding up the terms of a nonempty subset of the divisors 1,2,3,6 of 6.
Cf.
A000203,
A002093,
A005153,
A027750,
A030057,
A033630,
A093890,
A100587,
A119348,
A193279,
A225561,
A237290,
A378447,
A378450,
A378451.
Cf.
A083207 (positions of even terms).
-
import Data.List (subsequences, nub)
a119347 = length . nub . map sum . tail . subsequences . a027750_row'
-- Reinhard Zumkeller, Jun 27 2015
-
with(numtheory): with(linalg): a:=proc(n) local dl,t: dl:=convert(divisors(n),list): t:=tau(n): nops({seq(innerprod(dl,convert(2^t+i,base,2)[1..t]),i=1..2^t-1)}) end: seq(a(n),n=1..90);
-
a[n_] := Total /@ Rest[Subsets[Divisors[n]]] // Union // Length;
Array[a, 100] (* Jean-François Alcover, Jan 27 2018 *)
-
A119347(n) = { my(p=1); fordiv(n, d, p *= (1 + 'x^d)); sum(i=1,poldegree(p),(0Antti Karttunen, Nov 28 2024
-
A119347(n) = { my(c=[0]); fordiv(n, d, c = Set(concat(c,vector(#c,i,c[i]+d)))); (#c)-1; }; \\ after Chai Wah Wu's Python-code, Antti Karttunen, Nov 29 2024
-
from sympy import divisors
def A119347(n):
c = {0}
for d in divisors(n,generator=True):
c |= {a+d for a in c}
return len(c)-1 # Chai Wah Wu, Jul 05 2023
A237290
Sum of positive numbers k <= sigma(n) that are a sum of any subset of distinct divisors of n.
Original entry on oeis.org
1, 6, 8, 28, 12, 78, 16, 120, 52, 144, 24, 406, 28, 192, 192, 496, 36, 780, 40, 903, 256, 288, 48, 1830, 124, 336, 320, 1596, 60, 2628, 64, 2016, 384, 432, 384, 4186, 76, 480, 448, 4095, 84, 4656, 88, 2688, 2184, 576, 96, 7750, 228, 2976, 576, 3136, 108, 7260
Offset: 1
For n = 5, a(5) = 1 + 5 + 6 = 12 (each of the numbers 1, 5 and 6 is the sum of a subset of distinct divisors of 5).
The numbers n = 14 and 15 is an interesting pair of consecutive numbers with identical value of sigma(n) such that simultaneously a(14) = a(15) and A237289(14) = A237289(15).
a(14) = 1+2+3+7+8+9+10+14+15+16+17+21+22+23+24 = a(15) = 1+3+4+5+6+8+9+15+16+18+19+20+21+23+24 = 192.
-
isSumDist := proc(n,k)
local dvs,s ;
dvs := numtheory[divisors](n) ;
for s in combinat[powerset](dvs) do
add(m,m=op(s)) ;
if % = k then
return true;
end if;
end do:
false ;
end proc:
A237290 := proc(n)
local a;
a := 0 ;
for k from 1 to numtheory[sigma](n) do
if isSumDist(n,k) then
a := a+k;
end if;
end do:
end proc:
seq(A237290(n),n=1..20) ; # R. J. Mathar, Mar 13 2014
-
a[n_] := Plus @@ Union[Plus @@@ Subsets@ Divisors@ n]; Array[a, 54] (* Giovanni Resta, Mar 13 2014 *)
-
padbin(n, len) = {b = binary(n); while(length(b) < len, b = concat(0, b);); b;}
a(n) = {vks = []; d = divisors(n); nbd = #d; for (i=1, 2^nbd-1, b = padbin(i, nbd); onek = sum(j=1, nbd, d[j]*b[j]); vks = Set(concat(vks, onek));); sum(i=1, #vks, vks[i]);} \\ Michel Marcus, Mar 09 2014
-
A237290(n) = { my(c=[0]); fordiv(n,d, c = Set(concat(c,vector(#c,i,c[i]+d)))); vecsum(c); }; \\ after Chai Wah Wu's Python-code, Antti Karttunen, Nov 29 2024
-
from sympy import divisors
def A237290(n):
ds = divisors(n)
c, s = {0}, sum(ds)
for d in ds:
c |= {a+d for a in c}
return sum(a for a in c if 1<=a<=s) # Chai Wah Wu, Jul 05 2023
A237289
Sum of positive numbers k <= sigma(n) that are not a sum of any subset of distinct divisors of n.
Original entry on oeis.org
0, 0, 2, 0, 9, 0, 20, 0, 39, 27, 54, 0, 77, 108, 108, 0, 135, 0, 170, 0, 272, 378, 252, 0, 372, 567, 500, 0, 405, 0, 464, 0, 792, 1053, 792, 0, 665, 1350, 1148, 0, 819, 0, 902, 882, 897, 2052, 1080, 0, 1425, 1395, 2052, 1715, 1377, 0, 2052, 0, 2600, 3375, 1710
Offset: 1
For n = 5, a(5) = 2 + 3 + 4 = 9 (numbers 2, 3 and 4 are not a sum of any subset of distinct divisors of 5).
Numbers n = 14 and 15 are an interesting pair of consecutive numbers with identical value of sigma(n) such that simultaneously a(14) = a(15) and A237290(14) = A237290(15).
a(14) = 4+5+6+11+12+13+18+19+20 = a(15) = 2+7+10+11+12+13+14+17+22 = 108.
a(6) = 0 as 6 is practical; the sums into distinct divisors from 1 through 12 are 1 = 1, 2 = 2, 3 = 3, 4 = 1 + 3, 5 = 2 + 3, 6 = 1 + 2 + 3, 7 through 12 are (1 through 6) + 6. So none are not a sum distinct divisors of 6. - _David A. Corneth_, Jul 22 2025
-
isSumDist := proc(n,k)
local dvs ;
dvs := numtheory[divisors](n) ;
for s in combinat[powerset](dvs) do
add(m,m=op(s)) ;
if % = k then
return true;
end if;
end do:
false ;
end proc:
A237289 := proc(n)
local a;
a := 0 ;
for k from 1 to numtheory[sigma](n) do
if not isSumDist(n,k) then
a := a+k;
end if;
end do:
a ;
end proc:
seq(A237289(n),n=1..20) ; # R. J. Mathar, Mar 13 2014
-
a[n_] := Block[{d = Divisors@n, s}, s = Plus @@ d; s*(s + 1)/2 - Plus @@ Union[Plus @@@ Subsets@d]]; m = Array[a, 59] (* Giovanni Resta, Mar 13 2014 *)
-
from sympy import divisors
def A237289(n):
ds = divisors(n)
c, s = {0}, sum(ds)
for d in ds:
c |= {a+d for a in c}
return (s*(s+1)>>1)-sum(a for a in c if 1<=a<=s) # Chai Wah Wu, Jul 05 2023
A307223
Irregular table T(n, k) read by rows: n-th row gives number of subsets of the divisors of n which sum to k for 1 <= k <= sigma(n).
Original entry on oeis.org
1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 2, 1, 1, 2, 1, 1, 2, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1
Offset: 1
Table begins as:
1
1,1,1
1,0,1,1
1,1,1,1,1,1,1
1,0,0,0,1,1
1,1,2,1,1,2,1,1,2,1,1,1
1,0,0,0,0,0,1,1
1,1,1,1,1,1,1,1,1,1,1,1,1,1,1
1,0,1,1,0,0,0,0,1,1,0,1,1
1,1,1,0,1,1,1,1,0,1,1,1,1,0,1,1,1,1
-
T[n_,k_] := Module[{d = Divisors[n]}, SeriesCoefficient[Series[Product[1 + x^d[[i]], {i, Length[d]}], {x, 0, k}], k]]; Table[T[n, k], {n,1,10}, {k, 1, DivisorSigma[1,n]}] // Flatten
A119357
Numbers k such that the number of distinct nonzero sums of distinct divisors of k is less than 2^tau(k) - 1 (the largest number of possible distinct sums, tau(k) being the number of divisors of k (A000005)).
Original entry on oeis.org
6, 12, 18, 20, 24, 28, 30, 36, 40, 42, 45, 48, 54, 56, 60, 63, 66, 70, 72, 78, 80, 84, 88, 90, 96, 99, 100, 102, 104, 105, 108, 110, 112, 114, 117, 120, 126, 130, 132, 135, 138, 140, 144, 150, 154, 156, 160, 162, 165, 168, 170, 174, 176, 180, 182, 186, 189, 192, 195
Offset: 1
6 is in the sequence because from the divisors of 6, namely 1,2,3,6, we can form by addition 12 sums (1,2,3,...,12) and 12 < 2^tau(6)-1=2^4-1=15.
Sequence contains, for example, all multiples of 6 (1+2=3), all multiples of 20 (1+4=5), all multiples of 28 (1+2+4=7), all multiples of 63 (1+9=3+7).
-
with(numtheory): with(linalg): s:=proc(n) local dl,t:dl:=convert(divisors(n),list): t:=tau(n): nops({seq(innerprod(dl,convert(2^t+i,base,2)[1..t]),i=1..2^t-1)}) end: a:=proc(n) if s(n)<2^tau(n)-1 then n else fi end: seq(a(n),n=1..230);
-
q[n_] := Module[{d = Divisors[n], x}, Max[CoefficientList[Series[Product[1 + x^d[[i]], {i, Length[d]}], {x, 0, Total[d]}], x]] > 1]; Select[Range[200], q] (* Amiram Eldar, Jan 02 2022 *)
A193280
Triangle read by rows: row n contains, in increasing order, all the distinct sums of distinct proper divisors of n.
Original entry on oeis.org
0, 1, 1, 1, 2, 3, 1, 1, 2, 3, 4, 5, 6, 1, 1, 2, 3, 4, 5, 6, 7, 1, 3, 4, 1, 2, 3, 5, 6, 7, 8, 1, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 1, 1, 2, 3, 7, 8, 9, 10, 1, 3, 4, 5, 6, 8, 9, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
Offset: 1
Row 10 is 1,2,3,5,6,7,8 the possible sums obtained from the proper divisors 1, 2, and 5 of 10.
Triangle starts:
0;
1;
1;
1,2,3;
1;
1,2,3,4,5,6;
1;
1,2,3,4,5,6,7;
1,3,4;
1,2,3,5,6,7,8;
1;
1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16;
-
with(linalg): print(0); for n from 2 to 12 do dl:=convert(numtheory[divisors](n) minus {n}, list): t:=nops(dl): print(op({seq(innerprod(dl, convert(2^t+i, base, 2)[1..t]), i=1..2^t-1)})): od: # Nathaniel Johnston, Jul 23 2011
A377929
Quasi-practical numbers: positive integers m such that every k <= sigma(m)-m is a sum of distinct proper divisors of m.
Original entry on oeis.org
1, 2, 3, 4, 5, 6, 7, 8, 11, 12, 13, 16, 17, 18, 19, 20, 23, 24, 28, 29, 30, 31, 32, 36, 37, 40, 41, 42, 43, 47, 48, 53, 54, 56, 59, 60, 61, 64, 66, 67, 71, 72, 73, 78, 79, 80, 83, 84, 88, 89, 90, 96, 97, 100, 101, 103, 104, 107, 108, 109, 112, 113, 120, 126, 127, 128
Offset: 1
- Andrzej Kukla, Table of n, a(n) for n = 1..10000
- K. P. S. Bhaskara Rao and Yuejian Peng, On Zumkeller numbers, Journal of Number Theory, Volume 133, Issue 4, April 2013, pp. 1135-1155.
- Andrzej Kukla and Piotr Miska, On practical sets and A-practical numbers, arXiv:2405.18225 [math.NT], 2024.
-
QuasiPracticalQ[n_] := Module[{f, p, e, prod=1, ok=True}, If[n<1 || (n>1 && OddQ[n]), False, If[n==1, True, f=FactorInteger[n]; {p, e} = Transpose[f]; Do[If[p[[i]] > 1+DivisorSigma[1, prod], ok=False; Break[]]; prod=prod*p[[i]]^e[[i]], {i, Length[p]}]; ok]] || PrimeQ[n]]; Select[Range[200], QuasiPracticalQ] (* Created based on code by T. D. Noe, Apr 02 2010 *)
A385904
a(n) is the number of nonempty subsets of the divisors of n that sum to a perfect square.
Original entry on oeis.org
1, 1, 2, 2, 1, 4, 1, 3, 3, 2, 1, 11, 1, 3, 4, 5, 1, 9, 1, 9, 3, 3, 1, 27, 2, 2, 4, 8, 1, 27, 1, 7, 3, 2, 2, 49, 1, 1, 3, 22, 1, 21, 1, 7, 8, 3, 1, 77, 2, 5, 2, 4, 1, 22, 2, 21, 2, 1, 1, 248, 1, 2, 7, 11, 1, 21, 1, 4, 2, 17, 1, 235, 1, 1, 9, 7, 1, 20, 1, 64, 6, 1
Offset: 1
a(6) = 4 because exactly the 4 nonempty subsets {1}, {1, 3}, {1, 2, 6} and {3, 6} of the divisors of 6 sum to a perfect square: 1 = 1^2, 1 + 3 = 2^2, 1 + 2 + 6 = 3^2.
-
with(NumberTheory):
A385904:=proc(n)
local b,l,j;
l:=[(Divisors(n))[]]:
b:=proc(m,i)
option remember;
`if`(m=0,1,`if`(i<1,0,b(m,i-1)+`if`(l[i]>m,0,b(m-l[i],i-1))))
end;
add(b(j^2,nops(l)),j=1..floor(sqrt(sigma(n))));
end:
seq(A385904(n),n=1..82);
-
a[n_]:=Module[{nb = 0, d = Divisors[n]},Length[Select[Subsets[d],IntegerQ[Sqrt[Total[#]]]&]]]-1;Array[a,82] (* James C. McMahon, Jul 27 2025 *)
-
a(n) = my(nb=0, d=divisors(n)); forsubset(#d, s, nb+=issquare(sum(i=1, #s, d[s[i]]))); nb-1; \\ Michel Marcus, Jul 22 2025
Showing 1-9 of 9 results.
Comments