<?xml version="1.0"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "mathml.dtd"
[
<!-- <!ENTITY InvisibleTimes "&#59550;" > --> <!--UE89E marks multiplication when it is understood without a mark -->
<!-- <!ENTITY InvisibleTimes ""> -->
<!ENTITY IndentingNewLine "">

]>

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
  <title>The proof</title>
</head>

<body>

<h2>All even-digit Kaprekar Series numbers are multiples of nine.</h2>

<p>
Let use consider a 2m-digit number, whose digits are sorted in descending order:
</p>


<math xmlns="&mathml;">
  <mrow>
    <msub>
      <mi>n</mi>
      <mn>1</mn>
    </msub>

    <mo> = </mo>

    <!-- 10^(2m-1) x1-->
    <msup>
      <mn>10</mn>
      <mrow>
        <mo> ( </mo>
        <mrow>
          <mn> 2 </mn>
          <!-- <mo> &InvisibleTimes; </mo> -->
          <mn> m </mn>
          <mo> - </mo>
          <mn> 1 </mn>
        </mrow>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mn>1</mn>
    </msub>

    <mo> + </mo>

    <!-- 10^(2m-2) x2 -->
    <msup>
      <mn>10</mn>
      <mrow>
        <mo> ( </mo>
        <mrow>
          <mn> 2 </mn>
          <!-- <mo> &InvisibleTimes; </mo> -->
          <mn> m </mn>
          <mo> - </mo>
          <mn> 2 </mn>
        </mrow>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> 2 </mn>
    </msub>

    <mo> + </mo>
    <mi> ... </mi>
    <mo> + </mo>

    <!-- 10^(2m-i) xi -->
    <msup>
      <mn>10</mn>
      <mrow>
        <mo> ( </mo>
        <mrow>
          <mn> 2 </mn>
          <!-- <mo> &InvisibleTimes; </mo> -->
          <mn> m </mn>
          <mo> - </mo>
          <mn> i </mn>
        </mrow>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>

    <mo> + </mo>
    <mi> ... </mi>
    <mo> + </mo>

    <!-- 10 x(2m-1) -->
    <mn>10</mn>
    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msub>

    <mo> + </mo>

    <!-- x2m -->
    <msub>
      <mi> x </mi>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
      </mrow>
    </msub>

  </mrow>
</math>

<p>
sorted in ascending order, the number would be
</p>

<math xmlns="&mathml;">
  <mrow>
    <msub>
      <mi> n </mi>
      <mn> 2 </mn>
    </msub>

    <mo> = </mo>

    <!-- 10^(2m-1) x2m -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mrow>
        <mn>2</mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
      </mrow>
    </msub>

    <mo> + </mo>

    <!-- 10^(2m-2) x(2m-1) -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> - </mo>
        <mn> 2 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mrow>
        <mo> ( </mo>
        <mn>2</mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msub>

    <mo> + </mo>
    <mi> ... </mi>
    <mo> + </mo>

    <!-- 10^(i-1) xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> i </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mn> i </mn>
    </msub>

    <mo> + </mo>
    <mi> ... </mi>
    <mo> + </mo>

    <!-- 10 x2 -->
    <mn> 10 </mn>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mn> 2 </mn>
    </msub>

    <mo> + </mo>

    <msub>
      <mi>x</mi>
      <mn> 1 </mn>
    </msub>
  </mrow>
</math>

<p>
The difference between the two numbers
</p>

<math mode="display" xmlns="&mathml;">
  <mrow>
    <msub>
      <mi>Diff</mi>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
      </mrow>
    </msub>

    <mo> = </mo>

    <msub>
      <mi> n </mi>
      <mn> 1 </mn>
    </msub>

    <mo> - </mo>

    <msub>
      <mi> n </mi>
      <mn> 2 </mn>
    </msub>

  </mrow>

  <!-- This should be in the next line! -->
  <mrow>
    <mo> = </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> 1 </mn>
      </mrow>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
      </mrow>
    </munderover>

    <!-- 10^(2m-i) xi -->
    <msup>
      <mn>10</mn>
      <mrow>
        <mo> ( </mo>
        <mrow>
          <mn> 2 </mn>
          <!-- <mo> &InvisibleTimes; </mo> -->
          <mn> m </mn>
          <mo> - </mo>
          <mn> i </mn>
        </mrow>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>

    <mo> - </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> 1 </mn>
      </mrow>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
      </mrow>
    </munderover>

    <!-- 10^(i-1) xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> i </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mn> i </mn>
    </msub>

  </mrow>

  <!-- This should be in the next line! -->
  <mrow>
    <mo> = </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> 1 </mn>
      </mrow>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
      </mrow>
    </munderover>

    <mo> { </mo>

    <!-- 10^(2m-i) xi -->
    <msup>
      <mn>10</mn>
      <mrow>
        <mo> ( </mo>
        <mrow>
          <mn> 2 </mn>
          <!-- <mo> &InvisibleTimes; </mo> -->
          <mn> m </mn>
          <mo> - </mo>
          <mn> i </mn>
        </mrow>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>

    <mo> - </mo>

    <!-- 10^(i-1) xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> i </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mn> i </mn>
    </msub>

    <mo> } </mo>

  </mrow>

  <!-- This should be in the next line! -->
  <mrow>

    <mo> = </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> 1 </mn>
      </mrow>
      <mrow>
        <mn> m </mn>
      </mrow>
    </munderover>

    <!-- 10^(i-1) {10^(2m - 2i + 1) - 1} xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> i </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> { </mo>

    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> - </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> i </mn>
        <mo> + </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>

    <mo> } </mo>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>

    <mo> - </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
      </mrow>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
      </mrow>
    </munderover>

    <!-- 10^(2m-i) {10^(2i - 2m - 1) - 1} xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> - </mo>
        <mn> i </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> { </mo>

    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> i </mn>
        <mo> - </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>

    <mo> } </mo>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>
  </mrow>
</math>

<p>Lets take a closer look at part of the above expression</p>

<math xmlns="&mathml;">
  <mrow>
    <mo> ( </mo>
    <mn> 2 </mn>
    <!-- <mo> &InvisibleTimes; </mo> -->
    <mn> m </mn>

    <mo> - </mo>

    <mn> 2 </mn>
    <!-- <mo> &InvisibleTimes; </mo> -->
    <mn> i </mn>

    <mo> + </mo>
    <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>

  <mtext> is a positive number here when </mtext>

  <mrow>
    <mn> 1 </mn>
    <mo> &le; </mo>
    <mn> i </mn>
    <mo> &le; </mo>
    <mn> m </mn>
  </mrow>
</math>

<p></p>

<math xmlns="&mathml;">
  <mrow>
    <mo> ( </mo>
    <mn> 2 </mn>
    <!-- <mo> &InvisibleTimes; </mo> -->
    <mn> i </mn>

    <mo> - </mo>

    <mn> 2 </mn>
    <!-- <mo> &InvisibleTimes; </mo> -->
    <mn> m </mn>

    <mo> - </mo>
    <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>

  <mtext> is a positive number for </mtext>

  <mrow>
    <mrow>
      <mo> ( </mo>
      <mn> m </mn>
      <mo> + </mo>
      <mn> 1 </mn>
      <mo> ) </mo>
    </mrow>
    <mo> &le; </mo>
    <mn> i </mn>
    <mo> &le; </mo>
    <mrow>
      <mn> 2 </mn>
      <!-- <mo> &InvisibleTimes; </mo> -->
      <mn> m </mn>
    </mrow>
  </mrow>
</math>

<p></p>

<p>So our task is reduced to proving that

<math xmlns="&mathml;">
  <!-- (10^j - 1) -->
  <mrow>
    <mo> ( </mo>
      <msup>
        <mn> 10 </mn>
        <mn> j </mn>
      </msup>
      <mo> - </mo>
      <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>
</math>

is divisible by 9 for a positive j.</p>

<p>Let us assume that this is true for a positive j.</p>

<p>i.e.

<math xmlns="&mathml;">
  <!-- (10^j - 1) -->
  <mrow>
    <mo> ( </mo>
      <msup>
        <mn> 10 </mn>
        <mn> j </mn>
      </msup>
      <mo> - </mo>
      <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>
</math>

is divisible by 9 for a positive j.
</p>

<p>Consider the next number (j + 1). For this number, the expression changes to</p>

<math xmlns="&mathml;">
  <!-- (10^(j+1) - 1) -->
  <mrow>
    <mo> ( </mo>
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> j </mn>
        <mo> + </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>
</math>
<br/>
<math xmlns="&mathml;">
  <mo> = </mo>
  <!-- 10 (10^j - 1) + 9 -->
  <mrow>
    <mn> 10 </mn>
    <!-- <mo> &InvisibleTimes; </mo> -->

    <mo> ( </mo>
    <msup>
      <mn> 10 </mn>
      <mn> j </mn>
    </msup>
    <mo> - </mo>
    <mn> 1 </mn>
    <mo> ) </mo>

    <mo> + </mo>
    <mn> 9 </mn>
  </mrow>
</math>

<p>Now since
<math xmlns="&mathml;">
  <!-- (10^j - 1) -->
  <mrow>
    <mo> ( </mo>
      <msup>
        <mn> 10 </mn>
        <mn> j </mn>
      </msup>
      <mo> - </mo>
      <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>
</math>
is divisible by 9,
<math xmlns="&mathml;">
  <!-- (10^(j+1) - 1) -->
  <mrow>
    <mo> ( </mo>
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> j </mn>
        <mo> + </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>
</math>
would also be divisible by nine.</p>

<p>Lets consider the case of j = 1. For this value of j, the expression reduces to</p>

<math xmlns="&mathml;">
  <!-- (10^j - 1) -->
  <mrow>
    <mo> ( </mo>
      <msup>
        <mn> 10 </mn>
        <mn> j </mn>
      </msup>
      <mo> - </mo>
      <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>

  <mrow>
    <mo> = </mo>
    <mo> ( </mo>
      <msup>
        <mn> 10 </mn>
        <mn> 1 </mn>
      </msup>
      <mo> - </mo>
      <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>

  <mrow>
    <mo> = </mo>
    <mn> 9 </mn>
  </mrow>
</math>

<p>which obviously is divisible by 9.</p>

<p>Hence, by mathematical induction,
<math xmlns="&mathml;">
  <!-- (10^j - 1) -->
  <mrow>
    <mo> ( </mo>
      <msup>
        <mn> 10 </mn>
        <mn> j </mn>
      </msup>
      <mo> - </mo>
      <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>
</math>
is divisible by 9 for all positive integers.</p>

<p>Hence
<math xmlns="&mathml;">
  <!-- (n2 - n1) -->
  <mrow>
    <mo> ( </mo>
      <msub>
        <mi> n </mi>
        <mn> 2 </mn>
      </msub>
      <mo> - </mo>
      <msub>
        <mi> n </mi>
        <mn> 1 </mn>
      </msub>
    <mo> ) </mo>
  </mrow>
</math>
is divisible by nine for all even-digit numbers. Since every number in the Kaprekar series is obtained by subtracting two numbers, with the same digits, sorted in descending and ascending orders; we come to the conclusion that all numbers in an even-digit Kaprekar series is divisible by 9.</p>



<h2>All odd-digit Kaprekar Series numbers are multiples of ninety nine.</h2>


<p>Let use consider a 2m+1-digit number, whose digits are sorted in descending order:</p>

<math xmlns="&mathml;">
  <mrow>
    <msub>
      <mi>n</mi>
      <mn>1</mn>
    </msub>

    <mo> = </mo>

    <!-- 10^2m x1-->
    <msup>
      <mn>10</mn>
      <mrow>
        <mrow>
          <mn> 2 </mn>
          <!-- <mo> &InvisibleTimes; </mo> -->
          <mn> m </mn>
        </mrow>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mn>1</mn>
    </msub>

    <mo> + </mo>

    <!-- 10^(2m-1) x2 -->
    <msup>
      <mn>10</mn>
      <mrow>
        <mo> ( </mo>
        <mrow>
          <mn> 2 </mn>
          <!-- <mo> &InvisibleTimes; </mo> -->
          <mn> m </mn>
          <mo> - </mo>
          <mn> 1 </mn>
        </mrow>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> 2 </mn>
    </msub>

    <mo> + </mo>
    <mi> ... </mi>
    <mo> + </mo>

    <!-- 10^(2m+1-i) xi -->
    <msup>
      <mn>10</mn>
      <mrow>
        <mo> ( </mo>
        <mrow>
          <mn> 2 </mn>
          <!-- <mo> &InvisibleTimes; </mo> -->
          <mn> m </mn>
          <mo> + </mo>
          <mn> 1 </mn>
          <mo> - </mo>
          <mn> i </mn>
        </mrow>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>

    <mo> + </mo>
    <mi> ... </mi>
    <mo> + </mo>

    <!-- 10 x2m -->
    <mn>10</mn>
    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
      </mrow>
    </msub>

    <mo> + </mo>

    <!-- x2m+1 -->
    <msub>
      <mi> x </mi>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
      </mrow>
    </msub>

  </mrow>
</math>

<p>sorted in ascending order, the number would be</p>

<math xmlns="&mathml;">
  <mrow>
    <msub>
      <mi> n </mi>
      <mn> 2 </mn>
    </msub>

    <mo> = </mo>

    <!-- 10^2m x2m+1 -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mrow>
        <mn>2</mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
      </mrow>
    </msub>

    <mo> + </mo>

    <!-- 10^(2m-1) x2m -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mrow>
        <mn>2</mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
      </mrow>
    </msub>

    <mo> + </mo>
    <mi> ... </mi>
    <mo> + </mo>

    <!-- 10^(i-1) xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> i </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mn> i </mn>
    </msub>

    <mo> + </mo>
    <mi> ... </mi>
    <mo> + </mo>

    <!-- 10 x2 -->
    <mn> 10 </mn>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mn> 2 </mn>
    </msub>

    <mo> + </mo>

    <msub>
      <mi>x</mi>
      <mn> 1 </mn>
    </msub>
  </mrow>
</math>

<p>The difference between the two numbers</p>

<math mode="display" xmlns="&mathml;">
  <mrow>
    <msub>
      <mi>Diff</mi>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
      </mrow>
    </msub>

    <mo> = </mo>

    <msub>
      <mi> n </mi>
      <mn> 1 </mn>
    </msub>

    <mo> - </mo>

    <msub>
      <mi> n </mi>
      <mn> 2 </mn>
    </msub>

  </mrow>

  <!-- This should be in the next line! -->
  <mrow>
    <mo> = </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> 1 </mn>
      </mrow>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
      </mrow>
    </munderover>

    <!-- 10^(2m+1-i) xi -->
    <msup>
      <mn>10</mn>
      <mrow>
        <mo> ( </mo>
        <mrow>
          <mn> 2 </mn>
          <!-- <mo> &InvisibleTimes; </mo> -->
          <mn> m </mn>
          <mo> + </mo>
          <mn> 1 </mn>
          <mo> - </mo>
          <mn> i </mn>
        </mrow>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>

    <mo> - </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
      </mrow>
      <mn> 1 </mn>
    </munderover>

    <!-- 10^(i-1) xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> i </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi>x</mi>
      <mn> i </mn>
    </msub>

  </mrow>

  <!-- This should be in the next line! -->
  <mrow>
    <mo> = </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> 1 </mn>
      </mrow>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
      </mrow>
    </munderover>

    <mo> { </mo>

    <!-- 10^(2m+1-i) -->
    <msup>
      <mn>10</mn>
      <mrow>
        <mo> ( </mo>
        <mrow>
          <mn> 2 </mn>
          <!-- <mo> &InvisibleTimes; </mo> -->
          <mn> m </mn>
          <mo> + </mo>
          <mn> 1 </mn>
          <mo> - </mo>
          <mn> i </mn>
        </mrow>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> - </mo>

    <!-- 10^(i-1) -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> i </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> } </mo>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>

  </mrow>

  <!-- This should be in the next line! -->
  <mrow>

    <mo> = </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> 1 </mn>
      </mrow>
      <mrow>
        <mn> m </mn>
      </mrow>
    </munderover>

    <!-- 10^(i-1) {10^(2m - 2i + 2) - 1} xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> i </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> { </mo>

    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> - </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> i </mn>
        <mo> + </mo>
        <mn> 2 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>

    <mo> } </mo>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>

    <mo> - </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> m </mn>
        <mo> + </mo>
        <mn> 2 </mn>
      </mrow>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
      </mrow>
    </munderover>

    <!-- 10^(2m+1-i) {10^(2i - 2m - 2) - 1} xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
        <mo> - </mo>
        <mn> i </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> { </mo>

    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> i </mn>
        <mo> - </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> - </mo>
        <mn> 2 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>

    <mo> } </mo>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>
  </mrow>

  <!-- This should be in the next line! -->
  <mrow>

    <mo> = </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> 1 </mn>
      </mrow>
      <mrow>
        <mn> m </mn>
      </mrow>
    </munderover>

    <!-- 10^(i-1) {10^2(m - i + 1) - 1} xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mi> i </mi>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> { </mo>

    <msup>
      <mn> 10 </mn>
      <mrow>
        <mn> 2 </mn>
        <mo> ( </mo>
        <mn> m </mn>
        <mo> - </mo>
        <mn> i </mn>
        <mo> + </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>

    <mo> } </mo>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>

    <mo> - </mo>

    <munderover>
      <mo> &sum; </mo>
      <mrow>
        <mi> i </mi>
        <mo> = </mo>
        <mn> m </mn>
        <mo> + </mo>
        <mn> 2 </mn>
      </mrow>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
      </mrow>
    </munderover>

    <!-- 10^(2m+1-i) {10^2(i - m - 1) - 1} xi -->
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mo> ( </mo>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> m </mn>
        <mo> + </mo>
        <mn> 1 </mn>
        <mo> - </mo>
        <mn> i </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> { </mo>

    <msup>
      <mn> 10 </mn>
      <mrow>
        <mn> 2 </mn>
        <mo> ( </mo>
        <mn> i </mn>
        <mo> - </mo>
        <mn> m </mn>
        <mo> - </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>

    <mo> } </mo>

    <!-- <mo> &InvisibleTimes; </mo> -->

    <msub>
      <mi> x </mi>
      <mn> i </mn>
    </msub>
  </mrow>
</math>

<p>Notice that
<math xmlns="&mathml;">
  <mrow>
    <mo> ( </mo>
    <mn> m </mn>
    <mo> - </mo>
    <mn> i </mn>
    <mo> + </mo>
    <mn> 1 </mn>
    <mo> ) </mo>
    <mo> &ge; </mo>
    <mn> 0 </mn>
  </mrow>
</math>
for
<math xmlns="&mathml;">
  <mrow>
    <mn> 1 </mn>
    <mo> &le; </mo>
    <mn> i </mn>
    <mo> &le; </mo>
    <mn> m </mn>
  </mrow>
</math>
And
<math xmlns="&mathml;">
  <mrow>
    <mo> ( </mo>
    <mn> i </mn>
    <mo> - </mo>
    <mn> m </mn>
    <mo> - </mo>
    <mn> 1 </mn>
    <mo> ) </mo>
    <mo> &gt; </mo>
    <mn> 0 </mn>
  </mrow>
</math>
for
<math xmlns="&mathml;">
  <mrow>
    <mn> m </mn>
    <mo> + </mo>
    <mn> 2 </mn>
    <mo> &le; </mo>
    <mn> i </mn>
    <mo> &le; </mo>
    <mn> 2 </mn>
    <!-- <mo> &InvisibleTimes; </mo> -->
    <mn> m </mn>
    <mo> + </mo>
    <mn> 1 </mn>
  </mrow>
</math>
And that the expression is zero for
<math xmlns="&mathml;">
  <mrow>
    <mn> i </mn>
    <mo> = </mo>
    <mn> m </mn>
    <mo> + </mo>
    <mn> 1 </mn>
  </mrow>
</math>
</p>

<p>So, the problem is reduced to proving that
<math xmlns="&mathml;">
  <!-- (10^2j - 1) -->
  <mrow>
    <mo> ( </mo>
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> j </mn>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>
</math>
is divisible by 99.</p>

<p>Lets assume that this is true for a positive j.<br/>
Lets consider the next number (j + 1). The expression for (j + 1) would be</p>

<math xmlns="&mathml;">
  <!-- 10^2(j+1) - 1 -->
  <mrow>
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mn> 2 </mn>
        <mo> ( </mo>
        <mn> j </mn>
        <mo> + </mo>
        <mn> 1 </mn>
        <mo> ) </mo>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>
  </mrow>

  <!-- 100 ( 10^2j - 1) + 99 -->
  <mrow>
    <mo> = </mo>
    <mn> 100 </mn>
    <!-- <mo> &InvisibleTimes; </mo> -->
    <mo> ( </mo>
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> j </mn>
      </mrow>
    </msup>
    <mo> - </mo>
    <mn> 1 </mn>
    <mo> ) </mo>
    <mo> + </mo>
    <mn> 99 </mn>
  </mrow>
</math>

<p>Since
<math xmlns="&mathml;">
  <!-- (10^2j - 1) -->
  <mrow>
    <mo> ( </mo>
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> j </mn>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>
    <mo> ) </mo>
  </mrow>
</math>
is divisible by 99, so the expression is divisible by 99 for (j + 1) too.</p>

<p>Lets consider the case j = 1. The expression for this value is <br/>
<math xmlns="&mathml;">
  <!-- (10^2j - 1) -->
  <mrow>
    <mo> ( </mo>
    <msup>
      <mn> 10 </mn>
      <mrow>
        <mn> 2 </mn>
        <!-- <mo> &InvisibleTimes; </mo> -->
        <mn> j </mn>
      </mrow>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>
    <mo> ) </mo>

    <mo> = </mo>

    <mo> ( </mo>
    <msup>
      <mn> 10 </mn>
      <mn> 2 </mn>
    </msup>

    <mo> - </mo>
    <mn> 1 </mn>
    <mo> ) </mo>

    <mo> = </mo>
    <mn> 99 </mn>

  </mrow>
</math>
<br/>
Which is divisible by 99. Hence by mathematical induction, the expression is divisible by 99 for all positive integer j.</p>

<p>Hence
<math xmlns="&mathml;">
  <!-- (n2 - n1) -->
  <mrow>
    <mo> ( </mo>
      <msub>
        <mi> n </mi>
        <mn> 2 </mn>
      </msub>
      <mo> - </mo>
      <msub>
        <mi> n </mi>
        <mn> 1 </mn>
      </msub>
    <mo> ) </mo>
  </mrow>
</math>
is divisible by 99 for all odd-digit numbers. Since every number in the Kaprekar series is obtained by subtracting two numbers, with the same digits, sorted in descending and ascending orders; we come to the conclusion that all numbers in an odd-digit Kaprekar series is divisible by 99.</p>

</body>
</html>