ArticleslgStudy

mathematics

Thue–Morse sequence

Thue–Morse sequence is a mathematics topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Thue–Morse sequence rather than just read about it. In short: In mathematics, the Thue–Morse or Prouhet–Thue–Morse sequence is the binary sequence (an infinite sequence of 0s and 1s) that can be obtained by starting with 0 and successively appending the Boolean complement of the sequence obtained thus far. It is sometimes called the fair share sequence because of its applications to fair division or parity sequence.

Thue–Morse sequence — main illustration
Thue–Morse sequence — illustration

Key takeaways

  • Thue–Morse sequence belongs to mathematics; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Thue–Morse sequence to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Thue–Morse sequence from memory before moving on to harder problems.

Reference excerpt

In mathematics, the Thue–Morse or Prouhet–Thue–Morse sequence is the binary sequence (an infinite sequence of 0s and 1s) that can be obtained by starting with 0 and successively appending the Boolean complement of the sequence obtained thus far. It is sometimes called the fair share sequence because of its applications to fair division or parity sequence. The first few steps of this procedure yield the strings 0, 01, 0110, 01101001, 0110100110010110, and so on, which are the prefixes of the Thue–Morse sequence. The full sequence begins:

01101001100101101001011001101001... The sequence is named after Axel Thue, Marston Morse and (in its extended form) Eugène Prouhet.

Definition There are several equivalent ways of defining the Thue–Morse sequence.

Direct definition

To compute the nth element tn, write the number n in binary. If the number of ones in this binary expansion is odd then tn = 1, if even then tn = 0. That is, tn is the even parity bit for n. John Conway et al. deemed numbers n satisfying tn = 1 to be odious (intended to be similar to odd) numbers, and numbers for which tn = 0 to be evil (similar to even) numbers.

Fast sequence generation This method leads to a fast method for computing the Thue–Morse sequence: start with t0 = 0, and then, for each n, find the highest-order bit in the binary representation of n that is different from the same bit in the representation of n − 1. If this bit is at an even index, tn differs from tn−1, and otherwise it is the same as tn−1. In Python:

The resulting algorithm takes constant time to generate each sequence element, using only a logarithmic number of bits (constant number of words) of memory.

Recurrence relation The Thue–Morse sequence is the sequence tn satisfying the recurrence relation

t 0 = 0 , t 2 n = t n , t 2 n + 1 = 1 − t n , {\displaystyle {\begin{aligned}t_{0}&=0,\\t_{2n}&=t_{n},\\t_{2n+1}&=1-t_{n},\end{aligned}}}

for all non-negative integers n.

L-system

The Thue–Morse sequence is a morphic word: it is the output of the following Lindenmayer system:

Characterization using bitwise negation The Thue–Morse sequence in the form given above, as a sequence of bits, can be defined recursively using the operation of bitwise negation. The first element is 0. Once the first 2n elements have been specified, forming a string s, then the next 2n elements must form the bitwise negation of s. Now we have defined the first 2n+1 elements, and we recurse. Spelling out the first few steps in detail:

We start with 0. The bitwise negation of 0 is 1. Combining these, the first 2 elements are 01. The bitwise negation of 01 is 10. Combining these, the first 4 elements are 0110. The bitwise negation of 0110 is 1001. Combining these, the first 8 elements are 01101001. And so on. So

T0 = 0. T1 = 01. T2 = 0110. T3 = 01101001. T4 = 0110100110010110. T5 = 01101001100101101001011001101001. T6 = 0110100110010110100101100110100110010110011010010110100110010110. And so on. In Python:

Which can then be converted to a (reversed) string as follows:

Generating function A generating function for the sequence can be defined by:

∏ i = 0 ∞ ( 1 − x 2 i ) = ∑ j = 0 ∞ ( − 1 ) t j x j , {\displaystyle \prod _{i=0}^{\infty }\left(1-x^{2^{i}}\right)=\sum _{j=0}^{\infty }(-1)^{t_{j}}x^{j},}

where tj is the jth element if we start at j = 0.

… excerpt ends here. Continue reading the full article.

Illustrations

Thue–Morse sequence: When counting in binary, the digit sum modulo 2 is the Thue–Morse sequence
When counting in binary, the digit sum modulo 2 is the Thue–Morse sequence
Thue–Morse sequence: Thue–Morse sequence generated by an L-System
Thue–Morse sequence generated by an L-System

Worked examples

Example 1 — a first encounter with Thue–Morse sequence

Start with the simplest possible case. Write down what Thue–Morse sequence claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In mathematics, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Thue–Morse sequence before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Thue–Morse sequence ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Thue–Morse sequence

In research
Thue–Morse sequence appears in mathematics research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Thue–Morse sequence in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Thue–Morse sequence is common in secondary-school and first-year university syllabi. It links to neighbouring topics Binary sequences, Fixed points (mathematics), Parity (mathematics), so understanding it makes those chapters shorter.
In everyday life
Look for Thue–Morse sequence outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Thue–Morse sequence” →

Affiliate

Preply — study more efficiently by working with a personal tutor. 50% off.

How to study Thue–Morse sequence in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Thue–Morse sequence means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Thue–Morse sequence out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Thue–Morse sequence in simple terms?

In mathematics, the Thue–Morse or Prouhet–Thue–Morse sequence is the binary sequence (an infinite sequence of 0s and 1s) that can be obtained by starting with 0 and successively appending the Boolean complement of the sequence obtained thus far. It is sometimes called the fair share sequence becaus…

Why does Thue–Morse sequence matter?

Because it connects several mathematics ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Thue–Morse sequence?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Thue–Morse sequence.

Tags

  • Binary sequences
  • Fixed points (mathematics)
  • Parity (mathematics)

Keep exploring