OFFSET
1,2
COMMENTS
4879 and 5292 are in this sequence but not in A053816.
Digital root is either 1 or 9. - Ezhilarasu Velayutham, Jul 27 2019
Named after the Indian recreational mathematician Dattatreya Ramchandra Kaprekar (1905-1986). - Amiram Eldar, Jun 19 2021
REFERENCES
D. R. Kaprekar, On Kaprekar numbers, J. Rec. Math., Vol. 13 (1980-1981), pp. 81-82.
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
David Wells, The Penguin Dictionary of Curious and Interesting Numbers, Penguin Books, NY, 1986, p. 151.
LINKS
Robert Gerbicz, Table of n, a(n) for n = 1..51514 [T. D. Noe computed terms 1 - 1019, Nov 10 2007; R. Gerbicz computed the first 51514 terms, Jul 28 2011]
Santanu Bandyopadhyay, Kaprekar Number, Indian Institute of Technology Bombay (Mumbai, India, 2020).
Nicholas John Bizzell-Browning, LIE scales: Composing with scales of linear intervallic expansion, Ph. D. Thesis, Brunel Univ. (UK, 2024). See p. 142.
Ömer Eğecioğlu and Bünyamin Şahi̇n, On Twin EP Numbers, Trans. Comb. (2024).
Douglas E. Iannucci, The Kaprekar Numbers, Journal of Integer Sequences, Vol. 3 (2000), Article 1.2,
Douglas E. Iannucci and Bertrum Foster, Kaprekar Triples, Journal of Integer Sequences, Vol. 8 (2005), Article 05.4.8.
Robert Munafo, Kaprekar Sequences.
Rosetta Code, Kaprekar numbers.
Walter Schneider, Kaprekar Numbers, 2002.
Gérard Villemin's Almanach of Numbers, Nombres de Kaprekar
Eric Weisstein's World of Mathematics, Kaprekar Number.
Wikipedia, Kaprekar number.
FORMULA
a(n) = A194218(n) + A194219(n) and A194218(n) concatenated with A194219(n) gives a(n)^2. - Reinhard Zumkeller, Aug 19 2011
EXAMPLE
703 is a Kaprekar number because 703 = 494 + 209, 703^2 = 494209.
MATHEMATICA
(* This Mathematica code computes five additional powers in order to be sure that all the Kaprekar numbers have been computed. This fix works for mx <= 50, which includes terms computed by Gerbicz. *)
Inv[a_, b_] := PowerMod[a, -1, b]; mx = 20; t = {1}; Do[h = 10^k - 1; d = Divisors[h]; d2 = Select[d, GCD[#, h/#] == 1 &]; If[Log[10, h] < mx, AppendTo[t, h]]; Do[q = d2[[i]]*Inv[d2[[i]], h/d2[[i]]]; If[Log[10, q] < mx, AppendTo[t, q]], {i, 2, Length[d2] - 1}], {k, mx + 5}]; t = Union[t] (* T. D. Noe, Aug 17 2011, Aug 18 2011 *)
kaprQ[\[Nu]_] := Module[{n = \[Nu]^2},
MemberQ[Plus @@ # & /@
Select[Table[{Floor[n/10^j], 10^j*FractionalPart[n/10^j]}, {j,
IntegerLength@n - 1}], #[[2]] != 0 &], \[Nu]]];
Select[Range@1000000, kaprQ] (* Hans Rudolf Widmer, Oct 22 2021 *)
PROG
(Haskell) -- See A194218 for another version
a006886 n = a006886_list !! (n-1)
a006886_list = 1 : filter chi [4..] where
chi n = read (reverse us) + read (reverse vs) == n where
(us, vs) = splitAt (length $ show n) (reverse $ show (n^2))
-- Reinhard Zumkeller, Aug 18 2011
CROSSREFS
KEYWORD
nonn,nice,base,easy,changed
AUTHOR
EXTENSIONS
More terms from Michel ten Voorde, Apr 11 2001
4879 and 5292 added by Larry Reeves (larryr(AT)acm.org), Apr 24 2001
38962 added by Larry Reeves (larryr(AT)acm.org), May 23 2002
STATUS
approved