This is the first time you have learned the concept of Pigeon nest for a long time to solve a practical problem. It is very beautiful.
This is an exercise in a textbook. The original Article of the subject is: proving that two rational numbers are mutually exclusive, so there must be a circular summary. In fact, in elementary school, this thought flashed in my mind. Of course, it was just a flash. Maybe it's a fate. This time we will prove it.
Set two rational numbers A and B, and a/B, without losing the general rule, you can also specify that A is greater than B. We can make a/B = B * I1 +
R1, where I1 is the integral part of the quotient after a/B, while R1 is the remainder part. As division is not exhausted, Division operations of a/B continue. Based on the Division calculation method, the second time should be r1
/B. Similarly, this time can also be written as R1/B = B * I2
+ R2, where I2 is the integer part of the quotient after R1/B Division, while R2 is the remainder part. Since there is still no division, the next step is to calculate R2/B. So division will continue this way, and
After each division, the system returns the integer and remainder parts of a quotient.
Assume that such division is performed n consecutive times, and N is the smallest integer greater than. So we get n I and n r. Obviously, the N remainder is smaller than a, and the number of R is greater than a. Therefore, according to the Pigeon nest principle, there must be two remainder in the N remainder, which is the same. The remainder of the two numbers is Ri and rk.
Then, the remainder of RI + 1 is obtained by RI/B, and the remainder of RI + 1 is obtained by rk/B. Therefore, when Ri is equal to rk, then RI + 1 must be equal to rk + 1. Similarly, we can
To RI + 2 is equal to rk + 2, RI + 3 is equal to rk + 3 .... When this sequence is increased to N, namely RI + 1, RI + 2,..., RI + N, RI + N will
The remainder in RI + 1, RI + 2,..., RI + N-1 is equal, so we can find such a sequence. Obviously, each time this sequence is increased to N, it will match the one in the previous sequence.
The remainder of the current sequence is equal to the remainder of the previous sequence. So a Summary of the cycle appears. Pass.