%I #49 Feb 25 2021 21:19:18
%S 2,25,95,111,119,123,125,169,187,219,221,247,289,335,365,411,415,445,
%T 485,493,505,629,655,685,695,697,731,767,815,841,871,943,949,965,985,
%U 1003,1139,1207,1241,1261,1263,1273,1343,1387,1465,1469,1507,1513,1529,1563
%N A000120-perfect numbers.
%C Let A(n), n>=1, be an infinite positive sequence.
%C We call a number n:
%C A-deficient if Sum{d|n, d<n} A(d) < A(n),
%C A-abundant if Sum{d|n, d<n} A(d) > A(n),
%C and
%C A-perfect if Sum{d|n, d<n} A(d) = A(n),
%C depending on the sum over the proper divisors of n.
%C The definition generalizes the standard nomenclature of deficient (A005100), abundant (A005101) and perfect numbers (A000396), which is recovered by setting A(n) = n = A000027(n).
%C Conjecture: if there exist infinitely many A-deficient numbers and infinitely many A-abundant numbers, then there exist infinitely many A-perfect numbers.
%C Note that the sequence contains squares of all Fermat primes larger than 3 (see A019434). [This would also hold for squares of any hypothetical Fermat primes after the fifth one, 65537. Comment clarified by _Antti Karttunen_, May 14 2015]
%C A192895(a(n)) = 0. - _Reinhard Zumkeller_, Jul 12 2011
%H Amiram Eldar, <a href="/A175522/b175522.txt">Table of n, a(n) for n = 1..10000</a> (terms 1..1000 from Reinhard Zumkeller)
%e Proper divisors of 119 are 1,7,17. Since A000120(1)+A000120(7)+A000120(17)=A000120(119), then 119 is in the sequence.
%t binw[n_] := DigitCount[n, 2, 1]; Select[Range[1500], binw[#] == DivisorSum[#, binw[#1] &]/2 &] (* _Amiram Eldar_, Dec 14 2020 *)
%o (Sage) A000120 = lambda x: x.digits(base=2).count(1)
%o is_A175522 = lambda x: sum(A000120(d) for d in divisors(x)) == 2*A000120(x)
%o A175522 = filter(is_A175522, IntegerRange(1, 10**4))
%o # _D. S. McNeil_, Dec 04 2010
%o (Haskell)
%o import Data.List (elemIndices)
%o a175522 n = a175522_list !! (n-1)
%o a175522_list = map (+ 1) $ elemIndices 0 a192895_list
%o -- _Reinhard Zumkeller_, Jul 12 2011
%o (PARI) is(n)=sumdiv(n,d,hammingweight(d))==2*hammingweight(n) \\ _Charles R Greathouse IV_, Jan 28 2016
%o (Python)
%o from sympy import divisors
%o def A000120(n): return bin(n).count('1')
%o def aupto(limit):
%o alst = []
%o for m in range(1, limit+1):
%o if A000120(m) == sum(A000120(d) for d in divisors(m)[:-1]): alst += [m]
%o return alst
%o print(aupto(1563)) # _Michael S. Branicky_, Feb 25 2021
%Y Cf. A175524 (deficient version), A175526 (abundant version), A000120, A000396.
%Y Subsequence of A257691 (non-abundant version).
%Y Positions of zeros in A192895.
%Y Cf. A019434, A253204.
%K nonn
%O 1,1
%A _Vladimir Shevelev_, Dec 03 2010
%E More terms from _Amiram Eldar_, Feb 18 2019