ArticleslgStudy

mathematics

Mex (mathematics)

Mex (mathematics) 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 Mex (mathematics) rather than just read about it. In short: In mathematics, the mex (minimum excluded value) of a subset of a well-ordered set is the smallest value from the whole set that does not belong to the subset. That is, it is the minimum value of the complement set.

Key takeaways

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

Reference excerpt

In mathematics, the mex (minimum excluded value) of a subset of a well-ordered set is the smallest value from the whole set that does not belong to the subset. That is, it is the minimum value of the complement set. Beyond sets, subclasses of well-ordered classes have minimum excluded values. Minimum excluded values of subclasses of the ordinal numbers are used in combinatorial game theory to assign nim-values to impartial games. According to the Sprague–Grundy theorem, the nim-value of a game position is the minimum excluded value of the class of values of the positions that can be reached in a single move from the given position. Minimum excluded values are also used in graph theory, in greedy coloring algorithms. These algorithms typically choose an ordering of the vertices of a graph and choose a numbering of the available vertex colors. They then consider the vertices in order, for each vertex choosing its color to be the minimum excluded value of the set of colors already assigned to its neighbors.

Examples The following examples all assume that the given set is a subset of the class of ordinal numbers:

mex ⁡ ( ∅ ) = 0 mex ⁡ ( { 1 , 2 , 3 } ) = 0 mex ⁡ ( { 0 , 2 , 4 , 6 , … } ) = 1 mex ⁡ ( { 0 , 1 , 4 , 7 , 12 } ) = 2 mex ⁡ ( { 0 , 1 , 2 , 3 , … } ) = ω mex ⁡ ( { 0 , 1 , 2 , 3 , … , ω } ) = ω + 1 {\displaystyle {\begin{array}{lcl}\operatorname {mex} (\emptyset )&=&0\\[2pt]\operatorname {mex} (\{1,2,3\})&=&0\\[2pt]\operatorname {mex} (\{0,2,4,6,\ldots \})&=&1\\[2pt]\operatorname {mex} (\{0,1,4,7,12\})&=&2\\[2pt]\operatorname {mex} (\{0,1,2,3,\ldots \})&=&\omega \\[2pt]\operatorname {mex} (\{0,1,2,3,\ldots ,\omega \})&=&\omega +1\end{array}}} where ω is the limit ordinal for the natural numbers.

Game theory In the Sprague–Grundy theory the minimum excluded ordinal is used to determine the nimber of a normal-play impartial game. In such a game, either player has the same moves in each position and the last player to move wins. The nimber is equal to 0 for a game that is lost immediately by the first player, and is equal to the mex of the nimbers of all possible next positions for any other game. For example, in a one-pile version of Nim, the game starts with a pile of n stones, and the player to move may take any positive number of stones. If n is zero stones, the nimber is 0 because the mex of the empty set of legal moves is the nimber 0. If n is 1 stone, the player to move will leave 0 stones, and mex({0}) = 1, gives the nimber for this case. If n is 2 stones, the player to move can leave 0 or 1 stones, giving the nimber 2 as the mex of the nimbers {0, 1}. In general, the player to move with a pile of n stones can leave anywhere from 0 to n − 1 stones; the mex of the nimbers {0, 1, …, n − 1} is always the nimber n. The first player wins in Nim if and only if the nimber is not zero, so from this analysis we can conclude that the first player wins if and only if the starting number of stones in a one-pile game of Nim is not zero; the winning move is to take all the stones. If we change the game so that the player to move can take up to 3 stones only, then with n = 4 stones, the successor states have nimbers {1, 2, 3}, giving a mex of 0. Since the nimber for 4 stones is 0, the first player loses. The second player's strategy is to respond to whatever move the first player makes by taking the rest of the stones. For n = 5 stones, the nimbers of the successor states of 2, 3, and 4 stones are the nimbers 2, 3, and 0 (as we just calculated); the mex of the set of nimbers {0, 2, 3} is the nimber 1, so starting with 5 stones in this game is a win for the first player. See nimbers for more details on the meaning of nimber values.

References

Worked examples

Example 1 — a first encounter with Mex (mathematics)

Start with the simplest possible case. Write down what Mex (mathematics) 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 Mex (mathematics) 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 Mex (mathematics) 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 Mex (mathematics)

In research
Mex (mathematics) 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 Mex (mathematics) 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
Mex (mathematics) is common in secondary-school and first-year university syllabi. It links to neighbouring topics Combinatorial game theory, so understanding it makes those chapters shorter.
In everyday life
Look for Mex (mathematics) 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.

Affiliate

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

How to study Mex (mathematics) in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Mex (mathematics) 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 Mex (mathematics) out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Mex (mathematics) in simple terms?

In mathematics, the mex (minimum excluded value) of a subset of a well-ordered set is the smallest value from the whole set that does not belong to the subset. That is, it is the minimum value of the complement set.

Why does Mex (mathematics) 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 Mex (mathematics)?

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 Mex (mathematics).

Tags

  • Combinatorial game theory

Keep exploring