Skip to content

KaprekarNumbers ​

The Kaprekar numbers 1,9,45,55,99,297,…1, 9, 45, 55, 99, 297, …: nn whose square splits into a left and a (nonzero) right part that sum back to nn.

KaprekarNumbersthe nn for which some split of n2n^2's decimal digits sums back to nn, an infinite indexed collection.

Domain: Collections

Details
  • A lazy indexed collection: Count(KaprekarNumbers)=+∞Count(KaprekarNumbers) = +\infty -- every repunit-of-nines 10k−110^k - 1 qualifies, since (10k−1)2(10^k-1)^2 splits at position kk into 10k−210^k - 2 and the last kk digits, summing to 10k−110^k - 1. OEIS A006886.
  • At(KaprekarNumbers,k)At(KaprekarNumbers, k) unranks by scanning forward from the last cached match, trying every split position (the split isn't always at nn's own digit count -- 48792=238046414879^2 = 23804641 splits as 238+4641238 + 4641, not 2380+46412380+4641) -- At(KaprekarNumbers,3)=45At(KaprekarNumbers, 3) = 45 (452=2025→20+2545^2=2025 \to 20+25).
  • Membership goes through Element: Element(297,KaprekarNumbers)Element(297, KaprekarNumbers) is true (2972=88209→88+209=297297^2=88209 \to 88+209=297), Element(298,KaprekarNumbers)Element(298, KaprekarNumbers) is false.

Enumeration

Examples

1 more kept as data, checked against the oracles
About
Examples1
CrosswalkOEIS

See also: Count, At, Element, NarcissisticNumbers