Repairing a Machine
Source: Iran 3rd round 2014 - final exam problem 7
September 27, 2014
functionalgorithmcombinatorics unsolvedcombinatorics
Problem Statement
We have a machine that has an input and an output. The input is a letter from the finite set and the output is a lamp that at each moment has one of the colors of the set .
At each moment the machine has an inner state that is one of the members of finite set . The function is a surjective function defining that at each state, what color must the lamp be, and the function is a function defining how does giving each input at each state changes the state. We only shall see the lamp and we have no direct information from the state of the car at current moment.
In other words a machine is such that are finite, , and is surjective. It is guaranteed that for each two different inner states, there's a sequence of inputs such that the color of the lamp after giving the sequence to the machine at the first state is different from the color of the lamp after giving the sequence to the machine at the second state.
(a) The machine has different inner states. Prove that for each two different inner states, there's a sequence of inputs of length no more than such that the color of the lamp after giving the sequence to the machine at the first state is different from the color of the lamp after giving the sequence to the machine at the second state.
(b) Prove that for a machine with different inner states, there exists an algorithm with no more than inputs that starting at any unknown inner state, at the end of the algorithm the state of the machine at that moment is known.
Can you prove the above claim for ?