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.
%I A242100 #13 May 14 2014 19:43:27 %S A242100 6,10,12,18,20,24,30,34,36,40,42,48,56,66,68,72,80,84,90,96,108,110, %T A242100 130,132,136,144,150,156,160,182,192,210,222,240,246,252,258,260,264, %U A242100 270,272,288,306,320,324,342,350,380,384,392,420,462,506,514,516,520 %N A242100 Numbers of the form m = b^i + b^j, where b > 1 and i > j > 0. %C A242100 If m is a term, then there is a base b > 1 such that the base-b representation of m has digital sum = 2. %C A242100 The base b for which m = b^i + b^j is not uniquely determined. Example: 12 = 2^3+2^2 = 3^2 +3^1. %H A242100 Hieronymus Fischer, <a href="/A242100/b242100.txt">Table of n, a(n) for n = 1..10000</a> %F A242100 a(n) < n^2 for n > 4. %F A242100 lim a(n)/n^2 = 1, for n --> infinity. %e A242100 a(1) = 6, since 2 = 2^2 + 2^1. %e A242100 a(7) = 30, since 30 = 3^3 + 3^1. %e A242100 a(10) = 40. %e A242100 a(10^2) = 1722. %e A242100 a(10^3) = 377610. %e A242100 a(10^4) = 70635620. %e A242100 a(10^5) = 8830078992. %e A242100 a(10^6) = 951958292172. %e A242100 a(10^7) = 97932587392010. %e A242100 a(10^8) = 9908034917287656. %e A242100 a(10^9) = 995834160614903742. %o A242100 (Smalltalk) %o A242100 distinctPowersWithOffset: d %o A242100 "Answers an array which holds the first n numbers of the form b^i + b^j + d, i>j>0, where b is any natural number > 1, d is any integer number, and n is the receiver (d=0 for this sequence). %o A242100 Usage: n distinctPowersWithOffset: 0 %o A242100 Answer: #(6 10 12 ...) [first n terms]" %o A242100 | n terms m | %o A242100 terms := SortedCollection new. %o A242100 n := self. %o A242100 m := n squared max: 20. %o A242100 terms := m floorDistinctPowersWithOffset: d. %o A242100 ^terms copyFrom: 1 to: n %o A242100 ---------- %o A242100 floorDistinctPowersWithOffset: d %o A242100 "Answers an array which holds the numbers < n of the form b^i + b^j + d, i>j>0, where b is any natural number > 1, d is any integer number, and n is the receiver (d=0 for this sequence). %o A242100 Usage: n floorDistinctPowersWithOffset: 0 %o A242100 Answer: #(6 10 12 18 ...) [all terms < n]" %o A242100 | bmax p q n m terms a | %o A242100 terms := OrderedCollection new. %o A242100 n := self. %o A242100 bmax := ((4 * (n - d) + 1) sqrtTruncated - 1) // 2. %o A242100 2 to: bmax %o A242100 do: %o A242100 [:b | %o A242100 p := b * b. %o A242100 q := b. %o A242100 a := p + q + d. %o A242100 [a < n] whileTrue: %o A242100 [[q < p and: [a < n]] whileTrue: %o A242100 [terms add: a. %o A242100 q := b * q. %o A242100 a := p + q + d]. %o A242100 p := b * p. %o A242100 q := b. %o A242100 a := p + q + d]]. %o A242100 ^terms asSet asOrderedCollection sorted %Y A242100 Cf. A001597, A018900, A239709, A239710. %K A242100 nonn %O A242100 1,1 %A A242100 _Hieronymus Fischer_, May 04 2014