play and relax: games for kids games
  Cut the knot: learn to enjoy mathematics
A math books store at a unique math study site. Learn to enjoy mathematics.
Google
Web CTK
Try our no ads browsing

Sites for teachers
Sites for parents
Terms of use
Awards

Interactive Activities
CTK Exchange
CTK Insights - a blog

Games & Puzzles
What Is What
Arithmetic/Algebra
Geometry
Probability
Outline Mathematics
Make an Identity
Book Reviews
Stories for Young
Eye Opener
Analog Gadgets
Inventor's Paradox
Did you know?...
Proofs
Math as Language
Things Impossible
Visual Illusions
My Logo
Math Poll
Cut The Knot!
MSET99 Talk
Other Math sites
Front Page
Movie shortcuts
Personal info
Privacy Policy

Guest book
News sites

Recommend this site

Games to relax

Tutor Match Tutoring and Homework Help

Sites for teachers
Sites for parents

Education & Parenting

Manifesto: what CTK is about Buying a book is a commitment to learning Table of content Try our no ads browsing Things you can find on CTK Chronology of updates Email to Cut The Knot Recommend this page

Right Replacement

The applet below illustrates a problem from The American Mathematical Monthly (Vol. 75, No. 3. (Mar., 1968), pp. 299-301) proposed by D. W. Burns, Woodstock, Ill.

  Given a finite sequence of nonnegative integers, consider the process of replacing each of the integers by the number of integers to its right which are smaller. Repeat the process in turn on each of the sequences obtained. Show that one will finally obtain a sequence such that repetition of the process makes no further change, i.e.,each integer equals the number of smaller integers to its right.

Many solutions were submitted, two have been published. One by induction and another so general that it prompted me to consider a few modifications of the problem. The problem requires to compare integers with those lying on their right. The applet allows to modify the condition of comparison from "smaller than" (LT) to "smaller than or equal to" (LE), "greater than" (GT), "greater than or equal to" (GE). The behavior of the iterations is different in every case, remarkably so in the last one, GE.

 

This applet requires Sun's Java VM 2 which your browser may perceive as a popup. Which it is not. If you want to see the applet work, visit Sun's website at http://www.java.com/en/download/index.jsp, download and install Java VM and enjoy the applet.


Buy this applet
What if applet does not run?

Discussion

Copyright © 1996-2008 Alexander Bogomolny

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Solution 1

This solution is by E. S. Langford, U. S. Naval Postgraduate School.

An n-sequence (xl, x2, ... , xn) is stable if further iteration (as described in the problem) produces no change in the sequence. We show that every finite sequence is ultimately stable. An inductive argument is suggested since the stability of the (n-1)-sequence (x2, x3, ... , xn) is not affected by the value of xl.

The ultimate stability of 1-sequences is trivial, so suppose that every k-sequence is ultimately stable, and consider the (k+1)-sequence (xl, x2, ... , xk+1). Iterate until the k-sequence (x2, x3, ... , xk+1) is stable; suppose that the sequence becomes (x'1, x'2, ... , x'k+1). Iterate again to get (x''1, x'2, ... , x'k+1).

Suppose first that x''1 ≥ x'1. Iterate again to get (x'''1, x'2, ... , x'k+1).; evidently x'''1 ≥ x''1, hence the sequence (x'1, x''1, x'''1, ... ) is nondecreasing. But this sequence is bounded above (by k), so it must be ultimately constant. That is, the original (k+1)-sequence must be ultimately stable.

A similar argument holds if x''1 < x'1, since the sequence (x'1, x''1, x'''1, ... ) is bounded below by 0.

An associated combinatorial problem would be to enumerate all stable k-sequences.

A similar problem suggests itself when we replace "smaller" by "smaller than or equal to" in the statement of the problem. In this case we can give the following more complete answer: Every n-sequence terminates ultimately in the following particular stable sequence (n-1, n-2, ... , 0) after at most n iterations.

The proof is by induction on the following statement: Let the initial n-sequence be (xl(0), x2(0), ... , xn(0)). If after k iterations (1 ≤ k ≤ n) we reach the sequence (xl(k), x2(k), ... , xn(k)), then

  x1(k)≥ k-1, x2(k)≥ k-1, ... xn-k(k)≥ k-1,
  xn-k+1(k)= k-1, xn-k+2(k)= k-2, ... xn(k)= 0.

Solution 2

This solution by C. B. A. Peck, Ordnance Research Laboratory, State College, Pa. We generalize the problem as follows: Given a finite sequence of objects from a set S, consider the process of replacing each object by an object in S depending only on the collection of objects to its right, the number of times an object occurs in the collection being taken into account. Repeat the process, etc.

The empty set is such a collection, and the first object (counting right to left) in the second sequence is thus determined and fixed thereafter. In general the nth object in the final sequence is determined by at most the nth sequence after the first.

It is not necessary that the process be applied to each object of the sequence, provided that some change results at each application. Furthermore, the arrangement of the objects in the sequence could be changed, if the same change is applied to all the sequences.

The change in the problem from "smaller than" to "greater than" makes iteration converge to a (stable) sequence of all zeros. (The last element becomes 0 on the first iteration and then others, perhaps a few at a time, also vanish for a similar reason.)

However, a change to "greater than or equal to" engenders a different behavior. In all examples I ran, the iterations settled to a 2-cycle, a repeating pattern of two sequences. This is obvious if we start with a monotone nonincreasing sequence. The next iteration will result in a sequence with all the terms 0 and the next one will then be

 (n - 1, n - 2, n - 3, ..., 2, 1, 0)

which again leads to the 0 sequence. In a more general case, one of the sequences in the 2-cycle consists of groups of contiguous nonincreasing sequences whereas the other one parallels the first but in which the (same) groups consist of nondecreasing sequences.

The second solution above purports to encompass such situation but wrongly predicts convergence of the iterations.

Copyright © 1996-2008 Alexander Bogomolny

30724646Page copy protected against web site content infringement by Copyscape


Search:
Keywords:



Latest on CTK Exchange
try this puzzle ?/?? + ?/?? + ?/? ...
Posted by albert1950
5 messages
12:40 PM, Nov-18-08

Help me find Hisashi ABE, Pythago ...
Posted by likesmath
2 messages
11:11 AM, Oct-06-08

triangle construction
Posted by Elianto84
12 messages
07:06 PM, Oct-30-08

Gardner's Torus cutting puzzle... ...
Posted by itineracy
3 messages
11:22 PM, Nov-02-08

Three Concurrent Circles
Posted by billmillar
2 messages
12:26 PM, Oct-28-08

disjoint sets
Posted by jay_shark
0 messages
07:36 PM, Nov-13-08

Error in Fractal Curves and Dimen ...
Posted by miguemate22
1 messages
08:51 AM, Nov-16-08