Practice: Permutations

Recognition · Error diagnosis

A learner writes: " ( 1 2 3 4 ) is a cycle of even length, so it is an even permutation and its sign is + 1 ."

What is wrong?

2 hints available, least help first.

Hint 1: Retrieval cue

How many transpositions does a cycle of length k decompose into?

Hint 2: Concept cue

Write ( 1 2 3 4 ) in one-line notation and count the inversions.

Direct application

Let σ = ( 3 1 4 5 2 ) in one-line notation, so σ ( 1 ) = 3 , σ ( 2 ) = 1 , and so on.

How many inversions does σ have? (An inversion is a pair i < j with σ ( i ) > σ ( j ) .)

Enter the value. It is checked against the answer and the precision this task asks for.

2 hints available, least help first.

Hint 1: Retrieval cue

Go entry by entry, counting how many smaller numbers appear to its right.

Hint 2: Concept cue

The entry 3 contributes two inversions, against the 1 and the 2.

Representation translation · Direct application

Let σ = ( 1 3 5 2 4 ) in S 5 , one-line notation.

Decompose σ into disjoint cycles, counting fixed points as cycles of length 1.

How many cycles are there in total?

Enter the value. It is checked against the answer and the precision this task asks for.

2 hints available, least help first.

Hint 1: Retrieval cue

Start at 1 and follow where it goes until you return to the start. Then begin again from the smallest unused element.

Hint 2: Concept cue

Where does 1 map to? And the question asks you to count fixed points as cycles.

Direct application · Prediction

In S 4 , let p = ( 2 3 4 1 ) and q = ( 3 1 4 2 ) in one-line notation.

Form p ∘ q , applying q first, so that ( p ∘ q ) ( i ) = p ( q ( i ) ) .

What is ( p ∘ q ) ( 1 ) ?

Enter the value. It is checked against the answer and the precision this task asks for.

2 hints available, least help first.

Hint 1: Retrieval cue

Which of the two permutations acts first, and on what?

Hint 2: Concept cue

q ( 1 ) = 3 . Now apply p to 3.

Direct application · Interpretation

In the Leibniz expansion of a 4 × 4 determinant, one term is

a 1 , 4 a 2 , 3 a 3 , 2 a 4 , 1 .

Its permutation is σ = ( 4 3 2 1 ) , the full reversal.

What sign does this term carry, enter 1 for + or − 1 for − ?

Enter the value. It is checked against the answer and the precision this task asks for.

2 hints available, least help first.

Hint 1: Retrieval cue

How many pairs are out of order in ( 4 3 2 1 ) ?

Hint 2: Concept cue

All six of them, and ( − 1 ) 6 = + 1 . Check it against the cycle decomposition ( 1 4 ) ( 2 3 ) .

Construction · Direct application · Explanation

(a) For σ = ( 2 5 1 4 3 ) in S 5 , count the inversions and give the sign. Then decompose σ into disjoint cycles and obtain the sign again from the cycle lengths. Confirm the two agree.

(b) Let τ = ( 1 3 5 ) ( 2 4 ) in S 5 . Write τ in one-line notation and give its sign.

(c) Compute σ ∘ τ (apply τ first) in one-line notation, and verify that its sign equals sgn ⁡ ( σ ) sgn ⁡ ( τ ) .

(d) Let P be the 5 × 5 permutation matrix of σ , with a 1 in position ( i , σ ( i ) ) . State det P and say why.

(e) Explain why the parity of a permutation is well defined, given that the same permutation can be written as a product of transpositions in many different ways. Say what would break in the determinant if it were not.

Write your answer, then compare it with the worked solution.

3 hints available, least help first.

Hint 1: Retrieval cue

For inversions, work entry by entry, counting smaller values to the right.

Hint 2: Concept cue

A cycle of length k is k − 1 transpositions, so multiply the signs across the disjoint cycles.

Hint 3: Strategy cue

In (e), ask what one transposition does to the inversion count, and start from the identity.

Compare with the worked solution

Comparing does not record a result. Judging your own written answer cannot show that you can do this without help.

(a) σ = ( 2 5 1 4 3 ) . Inversions. Count, for each entry, the strictly smaller entries to its right: | entry | smaller, to its right | count |
|---|---|---|
| 2 | 1 | 1 |
| 5 | 1, 4, 3 | 3 |
| 1 | — | 0 |
| 4 | 3 | 1 |
| 3 | — | 0 | inv ⁡ ( σ ) = 1 + 3 + 0 + 1 + 0 = 5 , so sgn ⁡ ( σ ) = ( − 1 ) 5 = − 1 . Odd. Cycles. Trace: 1 ↦ 2 ↦ 5 ↦ 3 ↦ 1 , closing a 4-cycle ( 1 2 5 3 ) . Then 4 ↦ 4 , a fixed point. So σ = ( 1 2 5 3 ) ( 4 ) . One cycle of length 4 contributes 4 − 1 = 3 transpositions; the fixed point contributes none. Total 3, so sgn ⁡ ( σ ) = ( − 1 ) 3 = − 1 ✓. The routes agree. Note that 5 inversions and 3 transpositions are different counts, only their parity must match, and both are odd. (b) τ = ( 1 3 5 ) ( 2 4 ) . One-line. From the cycles: 1 ↦ 3 , 3 ↦ 5 , 5 ↦ 1 , and 2 ↦ 4 , 4 ↦ 2 . Listing the images of 1 , 2 , 3 , 4 , 5 in order:

τ = ( 3 4 5 2 1 ) .

Sign. A 3-cycle is 3 − 1 = 2 transpositions (even); a 2-cycle is 1 (odd). Total 3, so sgn ⁡ ( τ ) = − 1 . Odd. Check by inversions on ( 3 4 5 2 1 ) : 3 beats 2 and 1 → 2; 4 beats 2 and 1 → 2; 5 beats 2 and 1 → 2; 2 beats 1 → 1; total 2 + 2 + 2 + 1 = 7 , and ( − 1 ) 7 = − 1 ✓. (c) The composition σ ∘ τ , applying τ first. ( σ ∘ τ ) ( i ) = σ ( τ ( i ) ) , with σ = ( 2 5 1 4 3 ) and τ = ( 3 4 5 2 1 ) : | i | τ ( i ) | σ ( τ ( i ) ) |
|---|---|---|
| 1 | 3 | 1 |
| 2 | 4 | 4 |
| 3 | 5 | 3 |
| 4 | 2 | 5 |
| 5 | 1 | 2 | So σ ∘ τ = ( 1 4 3 5 2 ) . Its sign by inversions. 1 beats nothing → 0; 4 beats 3 and 2 → 2; 3 beats 2 → 1; 5 beats 2 → 1; total 0 + 2 + 1 + 1 = 4 , so the sign is ( − 1 ) 4 = + 1 . Multiplicativity. sgn ⁡ ( σ ) sgn ⁡ ( τ ) = ( − 1 ) ( − 1 ) = + 1 ✓. Two odd permutations compose to an even one, exactly as adding two odd numbers gives an even one. (d) The permutation matrix.

det P = sgn ⁡ ( σ ) = − 1 .

Why. In the Leibniz sum det P = ∑ π sgn ⁡ ( π ) ∏ i p i , π ( i ) , a term survives only if p i , π ( i ) = 1 for every i , which happens for the single permutation π = σ . That term is sgn ⁡ ( σ ) times a product of five ones. Geometrically: P maps the unit cube onto itself, so | det P | = 1 , and the sign says orientation is reversed, σ being odd, P acts as a reflection rather than a rotation. (e) Why parity is well defined. The decomposition into transpositions is genuinely non-unique: ( 1 2 5 3 ) can be written as ( 1 3 ) ( 1 5 ) ( 1 2 ) , or with extra cancelling pairs such as ( 1 3 ) ( 1 5 ) ( 1 2 ) ( 4 5 ) ( 4 5 ) , giving 3 factors or 5. What never changes is the parity. The argument. Composing with any transposition changes the inversion count by an odd number. For an adjacent swap this is immediate: exactly one pair reverses relative order, so inv changes by ± 1 . A transposition of positions i and j with d = j − i is a product of 2 d − 1 adjacent swaps, move one entry right d steps, move the displaced entry left d − 1 steps, and 2 d − 1 is odd, so the total change is a sum of an odd number of odd changes, hence odd. Now start from the identity, which has inv = 0 , and apply m transpositions to reach σ . Each flips the parity of inv , so the parity after m steps is the parity of m . But it also equals the parity of inv ⁡ ( σ ) , a number fixed by σ alone. Therefore m ≡ inv ⁡ ( σ ) ( mod 2 ) for every decomposition, and sgn is well defined. What would break. The Leibniz formula assigns each of the n ! terms a sign depending only on its permutation. If parity were not invariant, the same term could be assigned + or − according to how its permutation happened to be written, and the sum would not be a function of A at all, det would be undefined rather than merely awkward. Every downstream fact would fail with it: the row-swap rule, det ( A B ) = det A det B , and the characterisation of invertibility by a nonzero determinant.

A complete answer does each of these:

  • counts inversions
  • decomposes into cycles
  • relates cycle length to parity
  • composes permutations
  • applies leibniz sign
  • justifies parity invariance
Practice data

Your practice record is stored in this browser only. Clearing it removes every answer and every scheduled review, and cannot be undone.

Results update as you type. Use the up and down arrow keys to move between results, Enter to open one, and Escape to close.

Type to search.

Settings

Appearance

Interface density

Your record

Your progress is stored in this browser and nowhere else: an identifier, the answers you have given, the mastery states and review schedule derived from them, and the lesson you last opened. Clearing it makes you a new learner on this device. It cannot be undone, and it will not affect your appearance or density settings.

Focus timer

Focus--minutes remaining

Phase

Kept in this browser only, and used to label the session in your own history.

Today

Nothing recorded yet. Finish a focus session and it will appear here.

Settings

Focus sessions between long breaks.

Sessions you are aiming for in a day.

Notifications

Your history

Sessions are stored in this browser and nowhere else. They are not evidence and never reach your mastery record.