Kaprekar number

From HandWiki
Short description: Base-dependent property of integers


In mathematics, a natural number in a given number base is a p-Kaprekar number if the representation of its square in that base can be split into two parts, where the second part has p digits, that add up to the original number. For example, in base 10, 45 is a 2-Kaprekar number, because 45² = 2025, and 20 + 25 = 45. The numbers are named after D. R. Kaprekar.

Definition and properties

Let n be a natural number. We define the Kaprekar function for base b>1 and power p>0 Fp,b: to be the following:

Fp,b(n)=α+β,

where β=n2modbp and

α=n2βbp

A natural number n is a p-Kaprekar number if it is a fixed point for Fp,b, which occurs if Fp,b(n)=n. 0 and 1 are trivial Kaprekar numbers for all b and p, all other Kaprekar numbers are nontrivial Kaprekar numbers.

The earlier example of 45 satisfies this definition with b=10 and p=2, because

β=n2modbp=452mod102=25
α=n2βbp=45225102=20
F2,10(45)=α+β=20+25=45

A natural number n is a sociable Kaprekar number if it is a periodic point for Fp,b, where Fp,bk(n)=n for a positive integer k (where Fp,bk is the kth iterate of Fp,b), and forms a cycle of period k. A Kaprekar number is a sociable Kaprekar number with k=1, and a amicable Kaprekar number is a sociable Kaprekar number with k=2.

The number of iterations i needed for Fp,bi(n) to reach a fixed point is the Kaprekar function's persistence of n, and undefined if it never reaches a fixed point.

There are only a finite number of p-Kaprekar numbers and cycles for a given base b, because if n=bp+m, where m>0 then

n2=(bp+m)2=b2p+2mbp+m2=(bp+2m)bp+m2

and β=m2, α=bp+2m, and Fp,b(n)=bp+2m+m2=n+(m2+m)>n. Only when nbp do Kaprekar numbers and cycles exist.

If d is any divisor of p, then n is also a p-Kaprekar number for base bp.

In base b=2, all even perfect numbers are Kaprekar numbers. More generally, any numbers of the form 2n(2n+11) or 2n(2n+1+1) for natural number n are Kaprekar numbers in base 2.

Set-theoretic definition and unitary divisors

We can define the set K(N) for a given integer N as the set of integers X for which there exist natural numbers A and B satisfying the Diophantine equation[1]

X2=AN+B, where 0B<N
X=A+B

An n-Kaprekar number for base b is then one which lies in the set K(bn).

It was shown in 2000[1] that there is a bijection between the unitary divisors of N1 and the set K(N) defined above. Let Inv(a,c) denote the multiplicative inverse of a modulo c, namely the least positive integer m such that am=1modc, and for each unitary divisor d of N1 let e=N1d and ζ(d)=d Inv(d,e). Then the function ζ is a bijection from the set of unitary divisors of N1 onto the set K(N). In particular, a number X is in the set K(N) if and only if X=d Inv(d,e) for some unitary divisor d of N1.

The numbers in K(N) occur in complementary pairs, X and NX. If d is a unitary divisor of N1 then so is e=N1d, and if X=dInv(d,e) then NX=eInv(e,d).

Kaprekar numbers for Fp,b

b = 4k + 3 and p = 2n + 1

Let k and n be natural numbers, the number base b=4k+3=2(2k+1)+1, and p=2n+1. Then:

  • X1=bp12=(2k+1)i=0p1bi is a Kaprekar number.
  • X2=bp+12=X1+1 is a Kaprekar number for all natural numbers n.

b = m2k + m + 1 and p = mn + 1

Let m, k, and n be natural numbers, the number base b=m2k+m+1, and the power p=mn+1. Then:

  • X1=bp1m=(mk+1)i=0p1bi is a Kaprekar number.
  • X2=bp+m1m=X1+1 is a Kaprekar number.

b = m2k + m + 1 and p = mn + m − 1

Let m, k, and n be natural numbers, the number base b=m2k+m+1, and the power p=mn+m1. Then:

  • X1=m(bp1)4=(m1)(mk+1)i=0p1bi is a Kaprekar number.
  • X2=mbp+14=X3+1 is a Kaprekar number.

b = m2k + m2m + 1 and p = mn + 1

Let m, k, and n be natural numbers, the number base b=m2k+m2m+1, and the power p=mn+m1. Then:

  • X1=(m1)(bp1)m=(m1)(mk+1)i=0p1bi is a Kaprekar number.
  • X2=(m1)bp+1m=X1+1 is a Kaprekar number.

b = m2k + m2m + 1 and p = mn + m − 1

Let m, k, and n be natural numbers, the number base b=m2k+m2m+1, and the power p=mn+m1. Then:

  • X1=bp1m=(mk+1)i=0p1bi is a Kaprekar number.
  • X2=bp+m1m=X3+1 is a Kaprekar number.

Kaprekar numbers and cycles of Fp,b for specific p, b

All numbers are in base b.

Base b Power p Nontrivial Kaprekar numbers n0, n1 Cycles
2 1 10
3 1 2, 10
4 1 3, 10
5 1 4, 5, 10
6 1 5, 6, 10
7 1 3, 4, 6, 10
8 1 7, 10 2 → 4 → 2
9 1 8, 10
10 1 9, 10
11 1 5, 6, A, 10
12 1 B, 10
13 1 4, 9, C, 10
14 1 D, 10
15 1 7, 8, E, 10

2 → 4 → 2

9 → B → 9

16 1 6, A, F, 10
2 2 11
3 2 22, 100
4 2 12, 22, 33, 100
5 2 14, 31, 44, 100
6 2 23, 33, 55, 100

15 → 24 → 15

41 → 50 → 41

7 2 22, 45, 66, 100
8 2 34, 44, 77, 100

4 → 20 → 4

11 → 22 → 11

45 → 56 → 45

2 3 111, 1000 10 → 100 → 10
3 3 111, 112, 222, 1000 10 → 100 → 10
2 4 110, 1010, 1111, 10000
3 4 121, 2102, 2222, 10000
2 5 11111, 100000

10 → 100 → 10000 → 1000 → 10

111 → 10010 → 1110 → 1010 → 111

3 5 11111, 22222, 100000 10 → 100 → 10000 → 1000 → 10
2 6 11100, 100100, 111111, 1000000

100 → 10000 → 100

1001 → 10010 → 1001

100101 → 101110 → 100101

3 6 10220, 20021, 101010, 121220, 202202, 212010, 222222, 1000000

100 → 10000 → 100

122012 → 201212 → 122012

2 7 1111111, 10000000

10 → 100 → 10000 → 10

1000 → 1000000 → 100000 → 1000

100110 → 101111 → 110010 → 1010111 → 1001100 → 111101 → 100110

3 7 1111111, 1111112, 2222222, 10000000

10 → 100 → 10000 → 10

1000 → 1000000 → 100000 → 1000

1111121 → 1111211 → 1121111 → 1111121

2 8 1010101, 1111000, 10001000, 10101011, 11001101, 11111111, 100000000
3 8 2012021, 10121020, 12101210, 21121001, 20210202, 22222222, 100000000
2 9 10010011, 101101101, 111111111, 1000000000

10 → 100 → 10000 → 100000000 → 10000000 → 100000 → 10

1000 → 1000000 → 1000

10011010 → 11010010 → 10011010

Extension to negative integers

Kaprekar numbers can be extended to the negative integers by use of a signed-digit representation to represent each integer.

See also

Notes

  1. 1.0 1.1 Iannucci (2000)

References