cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A228091 Numbers n for which there exists such a natural number k < n that k + bitcount(k) = n + bitcount(n), where bitcount(k) (A000120) gives the number of 1's in binary representation of nonnegative integer k.

This page as a plain text file.
%I A228091 #18 Oct 12 2013 22:01:46
%S A228091 4,12,16,17,20,28,32,34,36,44,48,49,52,60,65,68,76,80,81,84,92,96,98,
%T A228091 100,108,112,113,116,124,128,129,130,131,132,140,144,145,148,156,160,
%U A228091 162,164,172,176,177,180,188,193,196,204,208,209,212,220,224,226,228
%N A228091 Numbers n for which there exists such a natural number k < n that k + bitcount(k) = n + bitcount(n), where bitcount(k) (A000120) gives the number of 1's in binary representation of nonnegative integer k.
%C A228091 In other words, all such terms A228236(n) which satisfy A228236(n) > A228086(A092391(A228236(n))), which means that the sequence contains all natural numbers n such that A228085(A092391(n)) > 1 and n > A228086(A092391(n)).
%C A228091 Note: 124 is the first term that occurs both here and in A228237.
%H A228091 Antti Karttunen, <a href="/A228091/b228091.txt">Table of n, a(n) for n = 1..10000</a>
%H A228091 <a href="/index/Coi#Colombian">Index entries for Colombian or self numbers and related sequences</a>
%e A228091 For cases 0 + A000120(0) = 0, 1 + A000120(1) = 2, 2 + A000120(2) = 3, 3 + A000120(3) = 5 there are no smaller solutions yielding the same result.
%e A228091 However, for 4 + A000120(4) = 5, we already saw the case 3+A000120(3) giving the same result, thus 4 is the first term of this sequence.
%e A228091 Next time this occurs for 12, as 12 + A000120(12) = 14 = 11 + A000120(11), and 11 < 12.
%o A228091 (Scheme, with _Antti Karttunen_'s IntSeq-library)
%o A228091 (define A228091 (MATCHING-POS 1 1 (lambda (n) (> n (A228086 (A092391 n))))))
%Y A228091 Subset of A228236. Cf. also A228237. Complement of this sequence gives the nonzero terms of A228086 in ascending order.
%Y A228091 Cf. A228085, A228086, A092391.
%K A228091 nonn
%O A228091 1,1
%A A228091 _Antti Karttunen_, Aug 09 2013