473,397 Members | 1,960 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

Induction question, help needed.

Help needed on this question. Any help is appreciated. Thanks in
advance.

Given a binary string (i.e. a finite sequence of 0's and 1's) we
choose any two digit substring 01 and replace it by a string of the
form 100...0 using an arbitrary (but finite) number of zeros. Prove
by induction that this transformation can not be performed infinitely
many times, i.e. this sequence of transformations must terminate for
any input string.
Jul 17 '05 #1
6 2651
On Tue, 23 Sep 2003, Jack Smith wrote:
Given a binary string (i.e. a finite sequence of 0's and 1's) we
choose any two digit substring 01 and replace it by a string of the
form 100...0 using an arbitrary (but finite) number of zeros. Prove
by induction that this transformation can not be performed infinitely
many times, i.e. this sequence of transformations must terminate for
any input string.

That is any finite string.
Transform the string into a polynomial
a_n x^n + ... + a_1 x + a_0
where a_j is the number of 0's before x^j which represents a 1.

Now every transformation preserves the number of 1's.
Thus the exponents of the polynomial are unchanged.
A transformation upon 01 for the j^th 1 is
a_j x^j + a_(j-1) x^(j-1) -> (a_j - 1)x^j + (a_(j-1) + c)x^(j-1)
for positive integer c.

This reminds me of Goodstein's theorem, the simplest theorem
independent of Peano's axioms.

The induction is complex. Every transformation increases a coefficient at
the cost of decreasing by one the previous coefficient.

One way to proceed is to consider the polynomial in x as an ordinal
polynomial in w. Thus every transformation decreases the ordinal
represented by the polynomial. If the transformations could proceed
forever then there would be an infinite descending sequences of ordinals,
which is impossible as the ordinals are well ordered with a first
element.

--
Another way to think the same is let the string be
(a_n, ... a_1, a_0) where
a_j is the number of 0's before the j-th 1 and a_0 is the number of
trailing 0's.

Now well order the n+1-tuples lexigraphically with the higher index being
given the greater dominance. IE (1,3,2) < (1,4,1)
Again the same reasoning, for each transformation h on a string s
h(s) < s
and h(s) is like s, an n+1-tuple.
This can't continue downward forever as the tuples are well ordered.

----
Jul 17 '05 #2

In article <20**************************@posting.google.com >,
st*******@yahoo.com (Jack Smith) writes:
Help needed on this question. Any help is appreciated. Thanks in
advance.

Given a binary string (i.e. a finite sequence of 0's and 1's) we
choose any two digit substring 01 and replace it by a string of the
form 100...0 using an arbitrary (but finite) number of zeros. Prove
by induction that this transformation can not be performed infinitely
many times, i.e. this sequence of transformations must terminate for
any input string.


This is a well-known (solved) type of termination problem in string
rewriting, a subfield of term rewriting. Here are some related links:

term rewriting homepage:
http://rewriting.loria.fr/
journal paper (AAECC 2000) by Zantema/Geser on this topic:
pdf:
http://www.springerlink.com/app/home...1&pagecount=25
abstract:
http://www.springerlink.com/app/home...ts,id:100499,1
conference paper (RTA 1995) on this topic:
http://www.informatik.uni-trier.de/~...tml#ZantemaG95
technical report version (1994) from Zantema's homepage:
ftp://ftp.cs.ruu.nl/pub/RUU/CS/techr.../1994-44.ps.gz
Hans Zantema's homepage:
http://www.win.tue.nl/~hzantema/
Alfons Geser's homepage:
http://research.nianet.org/~geser/

Hope this helps,
Bernhard Gramlich.

================================================== ======================
Bernhard Gramlich Vienna University of Technology
e-mail: gr******@logic.at www: http://www.logic.at/staff/gramlich
================================================== ======================
--
================================================== ======================
Bernhard Gramlich Vienna University of Technology
e-mail: gr******@logic.at www: http://www.logic.at/staff/gramlich
================================================== ======================
Jul 17 '05 #3
On Tue, 23 Sep 2003 22:18:31 -0700, Jack Smith wrote:
Help needed on this question. Any help is appreciated. Thanks in
advance.

Given a binary string (i.e. a finite sequence of 0's and 1's) we
choose any two digit substring 01 and replace it by a string of the
form 100...0 using an arbitrary (but finite) number of zeros. Prove
by induction that this transformation can not be performed infinitely
many times, i.e. this sequence of transformations must terminate for
any input string.

Hey donkey-

Why'd don't you do one of two things:
- pick up a CS book and expend brain power to determine how to solve your
CS assignment
- reboot your computer, launch MS Windows, and switch to a major other than
computer science.
You brain dead idiots that mistakenly believe you can find solutions to your CS
assignments on usenet are the reason why our profession is filled with
dimwitted neandethrals.

Here's a quarter - go to your career center and switch majors to something
that will allow you to play XBox, PS2, or whatever the hell other gaming
system that you mistaked for "computer science".
People like you make me sick,
-c
Jul 17 '05 #4
Now I have been working on the question...and I decided to do
induction on the length of the binary string.

So for the base case x=0 or x=1...which obviously terminates.

then I assumed for k>=0 it terminates for all |x|<=k

Now I am trying to prove the Induction Step...but I am having trouble.
ANy hints on how I can prove this?? Or maybe I am performing induction
on the wrong property? Any help is appreciated. Thanks.
Jul 17 '05 #5
Jack Smith wrote:
Now I have been working on the question...and I decided to do
induction on the length of the binary string.

So for the base case x=0 or x=1...which obviously terminates.

then I assumed for k>=0 it terminates for all |x|<=k

Now I am trying to prove the Induction Step...but I am having trouble.

ANy hints on how I can prove this?? Or maybe I am performing induction
on the wrong property? Any help is appreciated. Thanks.


Try induction on the number of 1s in the string and prove also
that after a finite number of replacements, a 1 will show up at the
left (use the induction hypothesis for that)
if you chop off that leftmost 1, you have a string with one 1 less ...

Cheers

Bart Demoen

Jul 17 '05 #6
"Christopher Blunck" <bl****@gst.com> wrote in message news:<pa****************************@gst.com>...
On Tue, 23 Sep 2003 22:18:31 -0700, Jack Smith wrote:
Help needed on this question. Any help is appreciated. Thanks in
advance.

Given a binary string (i.e. a finite sequence of 0's and 1's) we
choose any two digit substring 01 and replace it by a string of the
form 100...0 using an arbitrary (but finite) number of zeros. Prove
by induction that this transformation can not be performed infinitely
many times, i.e. this sequence of transformations must terminate for
any input string.

Hey donkey-

Why'd don't you do one of two things:
- pick up a CS book and expend brain power to determine how to solve your
CS assignment
- reboot your computer, launch MS Windows, and switch to a major other than
computer science.
You brain dead idiots that mistakenly believe you can find solutions to your CS
assignments on usenet are the reason why our profession is filled with
dimwitted neandethrals.

Here's a quarter - go to your career center and switch majors to something
that will allow you to play XBox, PS2, or whatever the hell other gaming
system that you mistaked for "computer science".
People like you make me sick,
-c

Why don't you tell us how you really feel.
Jul 17 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Johannes Bauer | last post by:
Hi group, I've got a question concerning inclusion of .hpp files. Currently I'm including all needed header files in the .cpp file. This means all dependencies of the package and all...
13
by: Axel Panning | last post by:
Hallo, ich hab bei einem Programm bei mir festgestellt, daß das "deleten" von Feldern erheblich länger dauert, als das Anlegen von Feldern. p. Bei einem Programm von mir werden oft große...
5
by: Don Vaillancourt | last post by:
Hello all, Over the years as I design more database schemas the more I come up with patterns in database design. The more patterns I recognize the more I want to try to design some kind of...
55
by: Steve Jorgensen | last post by:
In a recent thread, RKC (correctly, I believe), took issue with my use of multiple parameters in a Property Let procedure to pass dimensional arguments on the basis that, although it works, it's...
4
by: GGarramuno | last post by:
I have a program that expects its input in a specific format. Mainly, it expects floating-point values to be formatted in the form: 1.32 1. 3. 3.2345 In case you missed it, all floating...
7
by: Kevin | last post by:
Hi al I have an interesting question.... I am working witha Win API this is the Function Public Declare Function EnumJobs Lib "winspool.drv" Alias "EnumJobsA" (ByVal hPrinter As Long, ByVal...
2
by: Rouben Rostamian | last post by:
The main() function in the following code defines an m by n matrix, assigns value(s) to its elements, then passes the matrix to function foo(). For whatever it's worth, I have declared foo() so...
23
by: novice | last post by:
I dint find a proper group to post this, so i'm asking this question. If you think this question is irrelevent then dont answer, but i expect good replies from experts. I wondor, how these guys...
7
by: heddy | last post by:
I have an array of objects. When I use Array.Resize<T>(ref Object,int Newsize); and the newsize is smaller then what the array was previously, are the resources allocated to the objects that are...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.