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 A006887 M4478 #58 Mar 11 2025 08:33:56 %S A006887 1,8,45,297,2322,2728,4445,4544,4949,5049,5455,5554,7172,27100,44443, %T A006887 55556,60434,77778,143857,208494,226071,279720,313390,324675,329967, %U A006887 346060,368928,395604,422577,427868,461539,472823,478115,488214,494208 %N A006887 Kaprekar triples: q such that q = x + y + z and q^3 = x*10^2n + y*10^n + z, where z < 10^n and n is the number of digits in q. q is not a power of 10 (except q=1). %C A006887 The initial term a(1) = 1 is somewhat conventional: it is the only term with x = y = 0 and q = z = 10^k, which is explicitly allowed only for k = 0 and forbidden for k > 0. In all other cases, 0 < x, y, z < q, and q^3 has the same number of digits as x*10^2n. - _M. F. Hasler_, Aug 24 2017 %D A006887 N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence). %D A006887 David Wells, The Penguin Dictionary of Curious and Interesting Numbers, Penguin Books, NY, 1986, p. 151. %H A006887 Jack Brennen and Hans Havermann, <a href="/A006887/b006887.txt">Table of n, a(n) for n = 1..1000</a> (first 200 terms from Giovanni Resta) %H A006887 Futility Closet's "Math Notes", <a href="https://www.futilitycloset.com/2017/08/21/math-notes-116/">Shows the cubes of a(9) to a(13)</a> %H A006887 Shyam Sunder Gupta, <a href="https://doi.org/10.1007/978-981-97-2465-9_9">On Some Marvellous Numbers of Kaprekar</a>, Exploring the Beauty of Fascinating Numbers, Springer (2025) Ch. 9, 275-315. %H A006887 Hans Havermann, <a href="http://gladhoboexpress.blogspot.ca/2017/08/cube-wonders.html">Cube wonders</a> %H A006887 Douglas E. Iannucci and Bertrum Foster, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL8/Iannucci/iannucci45.html">Kaprekar Triples</a>, Journal of Integer Sequences, Vol. 8 (2005), Article 05.4.8. %H A006887 Robert Munafo, <a href="http://www.mrob.com/pub/seq/kaprekar.html">Kaprekar Sequences</a> %e A006887 1 = 0 + 0 + 1 and 1^3 = (00)1 (cf. comment), %e A006887 8 = 5 + 1 + 2 and 8^3 = 512, %e A006887 45 = 9 + 11 + 25, and 45^3 = 91125. - _M. F. Hasler_, Aug 24 2017 %t A006887 ok[n_] := n==1 || Block[{k = 10^IntegerLength[n], m = n^3}, n == Mod[m, k] + Floor[ m/k^2] + Mod[Floor[m/k], k] && ! IntegerQ@ Log10@ n]; Select[ Range@ 500000, ok] (* _Giovanni Resta_, Aug 23 2017 *) %o A006887 (PARI) m=1;for(n=1,6,for(q=m+(n>1),-1+m*=10,q==sumdigits(q^3,m)&&print1(q","))) \\ _M. F. Hasler_, Aug 24 2017 %Y A006887 Cf. A291461. %K A006887 nonn,base %O A006887 1,2 %A A006887 _Robert Munafo_ %E A006887 Entry revised by Larry Reeves (larryr(AT)acm.org), Apr 25 2001 and Dec 08 2002