Unary Representation Natural Numbers Represents Number N N 1 1 S Fo 15136525705r Example N Q37153310

The unary representation of natural numbers represents thenumber n by (n+1) 1’s.   Fo+15136525705r example, thenumber 3 is represented by 1111, the number 5 by 111111 and thenumber 0 by 1.

Design a one or two tape (your choice) deterministic Turingmachine that does the following computation.

Input: representation of natural number n

Result: representation of 2n on the tape in the input position.The remainder of the tape(s) is/are blank.

a) Briefly describe the strategy of your machine.

b) Give the state diagram for your machine.


Solution


Bl Changed t。 北 6.

Bl Changed t。 北 6.

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.