A binary linear-feedback shift register of degree has a state
and recurrenceIts feedback polynomial is
and recurrenceIts feedback polynomial is
There are states, and the zero state is fixed. A nonzero periodic orbit therefore visits at most the other states, proving the period bound for a linear-feedback shift register.
For a maximal orbit with , the all-one state cannot itself be fixed. From that state the incoming bit is in . If an odd number of the were one, the incoming bit would be one and the all-one state would be fixed. Hence an even number of the are one; including the leading coefficient, the feedback polynomial has an odd number of nonzero coefficients. This is the feedback-polynomial parity condition for maximal period.
The given prefix has seven consecutive zeros followed by a one. Any register of degree at most seven would therefore enter the all-zero state before producing the final one, which is impossible. Degree eight is attained bywith initial state . It produces the next bit and has feedback polynomialThus this is the minimal linear-feedback shift register for the prefix 100000001.
Solved by gpt-5.6-sol high.
Codex Wiki