Two different matroids with the same deck
A matroid says which sets of elements count as independent, as four points in space do when not on one flat plane. Two matroids on 8 elements differ even after renaming, yet match up to renaming when the same element is deleted from both, or contracted in both.
There are two matroids M and N, each on all eight elements 0, 1, …, 7, such that for every element e, deleting e from M and deleting e from N give isomorphic matroids, and contracting e in M and contracting e in N give isomorphic matroids, yet M and N themselves are not isomorphic.
Brylawski (1986) asked whether a matroid is always determined by the smaller matroids, called cards, that you get by deleting or contracting one element, and Oxley's book Matroid Theory (2011) records this as Problem 15.4.3. Miller (1997) stated the expected answer, yes, as a conjecture. Lean checked a pair of matroids on 8 elements that answers no.
Seven non-bases, one path and one ring
Write 0123 for the set of elements 0, 1, 2, 3. Both matroids live on the elements 0 to 7. Their bases are the sets of 4 elements, except for 7 sets called non-bases. There are 70 sets of 4 elements, so each matroid has 70 − 7 = 63 bases.
M₁ has the non-bases 0123 0145 0246 1247 1356 3467 2357. M₂ has the same ones, except 0357 in place of 2357.
Join two non-bases when they share exactly one element. In M₁ this makes one path of seven, in this order: 0123, 3467, 0145, 2357, 0246, 1356, 1247. In M₂ it makes a path of three, 0123, 3467, 0145, and a ring of four, 0246, 1356, 1247, 0357 and back to 0246. Renaming the elements cannot turn a path into a ring, so M₁ and M₂ are not isomorphic.
Deleting an element e that some basis leaves out keeps only the bases that leave e out. Contracting an element e that lies in some basis keeps only the bases that contain e, each with e taken out. A card is one of the smaller matroids left after deleting or contracting a single element, so a matroid on 8 elements has 16 cards.
The cards are matched through the renaming s, which sends 0, 1, …, 7 to 5, 1, 0, 4, 3, 7, 6, 2; it sends 7 to 2. Now contract element 7 in M₁ and element 2 in M₂: keep the non-bases that contain it, and take it out. M₁ gives 124, 235, 346 and M₂ gives 013, 046, 147. The renaming 0 → 5, 1 → 3, 2 → 0, 3 → 4, 4 → 1, 5 → 6, 6 → 7 turns 124, 235, 346 into 013, 046, 147, the list of M₂.
Lean checks a renaming like this for all 16 cards: the 8 deletions and the 8 contractions.
Matroids and renaming
An isomorphism between two matroids is a renaming of the elements of the one as the elements of the other that keeps exactly the independent sets independent. Isomorphisms can be undone and chained, and an isomorphism keeps bases as bases. Renaming commutes with deleting and with contracting an element.
- An isomorphism of matroids
- Every matroid is isomorphic to itself
- An isomorphism can be undone
- Isomorphisms can be chained
- An isomorphism carries M onto N exactly
- An isomorphism from a renaming that carries M onto N
- An isomorphism sends bases to bases
- An isomorphism keeps bases, both ways
- An isomorphism from a renaming that keeps bases
- An isomorphism from a renaming of all elements
- A matroid is isomorphic to its renamed copy
- An isomorphism from a renamed copy
- The renaming of all elements behind an isomorphism
That renaming keeps bases
When both matroids use every element, a set is a basis of M exactly when its renamed copy is a basis of N.
theorem MatroidReconst.MatroidIso.toEquivUniv_isBase_iff {α : Type u_1} {β : Type u_2} {M : Matroid α} {N : Matroid β} (e : MatroidIso M N) (hM : M.E = univ) (hN : N.E = univ) (B : Set α) : M.IsBase B ↔ N.IsBase (⇑(e.toEquivUniv hM hN) '' B)- Renaming commutes with deleting
- Renaming commutes with taking the dual
- Renaming commutes with contracting
- Renaming commutes with deleting one element
- Renaming commutes with contracting one element
Sparse paving matroids
Take a finite set of elements and a family of its sets of r elements, in which any two different members share at most r − 2 elements, and leave at least one set of r elements outside it. Then the sets of r elements outside the family obey the exchange rule, so they are the bases of a matroid of rank r. Lean also describes the bases of its deletion and contraction cards in terms of the family.
The sets of r elements outside a sparse paving family obey the exchange rule
For a sparse paving family H of sets of r elements, on any finite set of elements and for any r, the sets of r elements not in H obey the exchange rule: if B₁ and B₂ are two of them and x is in B₁ but not in B₂, then some y in B₂ but not in B₁ makes B₁ with x swapped for y another of them.
theorem MatroidReconst.IsSparsePaving.exchangeProperty {α : Type u_1} [Fintype α] [DecidableEq α] {r : ℕ} {H : Finset (Finset α)} (hSP : IsSparsePaving r H) : ExchangeProperty fun B => ∃ F, ↑F = B ∧ F.card = r ∧ F ∉ H- A sparse paving family
- The sparse paving matroid of a family
- Its ground set is every element
Its bases are the sets of r elements outside the family
A finite set F is a basis exactly when F has r elements and is not in H.
theorem MatroidReconst.sparsePavingMatroid_isBase_coe {α : Type u_1} [Fintype α] [DecidableEq α] {r : ℕ} {H : Finset (Finset α)} (hSP : IsSparsePaving r H) (F : Finset α) : (sparsePavingMatroid hSP).IsBase ↑F ↔ F.card = r ∧ F ∉ H- The same test for any set
- Its rank is r
- An element missing from some basis is not a coloop
- An element missing from some basis is coindependent
- The bases of a deletion card
- An element in some basis is not a loop
- An element in some basis is independent on its own
- The bases of a contraction card
The two matroids M₁ and M₂
The two families of 7 non-bases differ in one set: 2357 in M₁ and 0357 in M₂. Any two non-bases in either family share at most 2 elements, so both give sparse paving matroids of rank 4 on the elements 0 to 7, each with 63 bases. Every element lies in some basis and is missing from some basis.
The non-bases of M₁ form a sparse paving family
Each of the 7 sets has 4 elements, any two different ones share at most 2 elements, and 0124 is a set of 4 elements outside the family.
theorem MatroidReconst.H₁_isSparsePaving : IsSparsePaving 4 H₁
The non-bases of M₂ form a sparse paving family
Each of the 7 sets has 4 elements, any two different ones share at most 2 elements, and 0124 is a set of 4 elements outside the family.
theorem MatroidReconst.H₂_isSparsePaving : IsSparsePaving 4 H₂
- A set of four elements
- The non-bases of M₁
- The non-bases of M₂
- M₁ has 7 non-bases
- M₂ has 7 non-bases
- The matroid M₁
- The matroid M₂
- M₁ uses all eight elements
- M₂ uses all eight elements
- M₁ has rank 4
- M₂ has rank 4
- Seven non-bases leave 63 bases
- M₁ has 63 bases
- M₂ has 63 bases
- Each element is missing from some basis of M₁
- Each element is missing from some basis of M₂
- Each element lies in some basis of M₁
- Each element lies in some basis of M₂
- M₁ has no loops
- M₂ has no loops
- M₁ has no coloops
- M₂ has no coloops
A path cannot be renamed into a ring
For two sparse paving matroids of the same rank on the same elements, an isomorphism renames the non-bases of the one onto the non-bases of the other and keeps the size of every overlap. So one family has a ring of four exactly when the other does. M₂ has the ring 0246, 1356, 1247, 0357, while M₁'s non-bases form a path, which has none, so M₁ and M₂ are not isomorphic.
Isomorphic sparse paving matroids agree on rings of four
If two sparse paving matroids of the same rank r on the same finite set of elements are isomorphic, then the family of the one has a ring of four exactly when the family of the other does. Here H₁ and H₂ are the two families, h₁ is the fact that H₁ is a sparse paving family, and h₂ the same for H₂.
theorem MatroidReconst.IsSparsePaving.iso_preserves_hasOnePtFourCycle {α : Type u_1} [Fintype α] [DecidableEq α] {r : ℕ} {H₁ : Finset (Finset α)} {H₂ : Finset (Finset α)} (h₁ : IsSparsePaving r H₁) (h₂ : IsSparsePaving r H₂) (e : MatroidIso (sparsePavingMatroid h₁) (sparsePavingMatroid h₂)) : HasOnePtFourCycle H₁ ↔ HasOnePtFourCycle H₂- A ring of four in a family
- Rings of four can be searched for
The non-bases of M₂ contain a ring of four
In H₂, the sets 0246 and 1356 share 6, 1356 and 1247 share 1, 1247 and 0357 share 7, and 0357 and 0246 share 0.
theorem MatroidReconst.hasOnePtFourCycle_H₂ : HasOnePtFourCycle H₂
- The non-bases of M₁, numbered 0 to 6
- Neighbours on the path of M₁
- Every non-basis of M₁ is one of the numbered rows
- Rows sharing one element are neighbours on the path
The non-bases of M₁ contain no ring of four
H₁ has no four members a, b, c, d forming a ring of four.
theorem MatroidReconst.not_hasOnePtFourCycle_H₁ : ¬HasOnePtFourCycle H₁
M₁ and M₂ are not isomorphic
There is no isomorphism from M₁ to M₂.
theorem MatroidReconst.M₁_not_iso_M₂ : ¬Nonempty (MatroidIso M₁ M₂)
Matching all 16 cards
Take sparse paving matroids of the same rank, an element e₁ of the one, an element e₂ of the other, and a renaming of all the elements that sends e₁ to e₂. If some basis of each leaves out its element, and the renaming carries the non-bases that leave out e₁ onto those that leave out e₂, then the deletion cards of e₁ and e₂ are isomorphic; contraction cards work the same way, with "contain" in place of "leave out". The renaming s sends 0, 1, 2, 3, 4, 5, 6, 7 to 5, 1, 0, 4, 3, 7, 6, 2. For each element e, two written-out renamings, one for the deletion card and one for the contraction card, rename the deletion card of e in M₁ onto the deletion card of s(e) in M₂, and the contraction card likewise.
- The match of deletion card e of M₁ with deletion card s(e) of M₂
- The match of contraction card e of M₁ with contraction card s(e) of M₂
- A test for matching deletion cards
- The renaming matches the ground sets of the deletion cards
The renaming matches the bases of the deletion cards
For two sparse paving matroids of the same rank r, where e₁ is missing from some basis of the one and e₂ from some basis of the other: if a renaming p with p(e₁) = e₂ carries the non-bases that leave out e₁ onto the non-bases that leave out e₂, then p carries the bases of the deletion card of e₁ onto those of the deletion card of e₂.
theorem MatroidReconst.sparsePaving_deleteElem_isBase_image {α : Type u_1} [Fintype α] [DecidableEq α] {r : ℕ} {H₁ : Finset (Finset α)} {H₂ : Finset (Finset α)} (h₁ : IsSparsePaving r H₁) (h₂ : IsSparsePaving r H₂) {e₁ : α} {e₂ : α} (he₁ : ∃ B, B.card = r ∧ B ∉ H₁ ∧ e₁ ∉ B) (he₂ : ∃ B, B.card = r ∧ B ∉ H₂ ∧ e₂ ∉ B) (p : Equiv.Perm α) (hpe : p e₁ = e₂) (himg : Finset.image (Finset.image ⇑p) ({h ∈ H₁ | e₁ ∉ h}) = {h ∈ H₂ | e₂ ∉ h}) (B : Set α) : ((sparsePavingMatroid h₁).delete {e₁}).IsBase B ↔ ((sparsePavingMatroid h₂).delete {e₂}).IsBase (⇑p '' B)- A test for matching contraction cards
- The renaming matches the ground sets of the contraction cards
The renaming matches the bases of the contraction cards
For two sparse paving matroids of the same rank r, where e₁ lies in some basis of the one and e₂ in some basis of the other: if a renaming p with p(e₁) = e₂ carries the non-bases that contain e₁ onto the non-bases that contain e₂, then p carries the bases of the contraction card of e₁ onto those of the contraction card of e₂.
theorem MatroidReconst.sparsePaving_contractElem_isBase_image {α : Type u_1} [Fintype α] [DecidableEq α] {r : ℕ} {H₁ : Finset (Finset α)} {H₂ : Finset (Finset α)} (h₁ : IsSparsePaving r H₁) (h₂ : IsSparsePaving r H₂) {e₁ : α} {e₂ : α} (he₁ : ∃ B, B.card = r ∧ B ∉ H₁ ∧ e₁ ∈ B) (he₂ : ∃ B, B.card = r ∧ B ∉ H₂ ∧ e₂ ∈ B) (p : Equiv.Perm α) (hpe : p e₁ = e₂) (himg : Finset.image (Finset.image ⇑p) ({h ∈ H₁ | e₁ ∈ h}) = {h ∈ H₂ | e₂ ∈ h}) (B : Set α) : ((sparsePavingMatroid h₁).contract {e₁}).IsBase B ↔ ((sparsePavingMatroid h₂).contract {e₂}).IsBase (⇑p '' B)- A renaming from a table and its reverse
- A table of eight entries
- The renaming s
- The deletion renamings
- The contraction renamings
- Each deletion renaming sends e to s(e)
- Each contraction renaming sends e to s(e)
The deletion renamings match the non-bases
For every element e, the deletion renaming for e carries the non-bases of M₁ that leave out e onto the non-bases of M₂ that leave out s(e).
theorem MatroidReconst.delPerm_maps_nonbases (e : Fin 8) : Finset.image (Finset.image ⇑(delPerm e)) ({h ∈ H₁ | e ∉ h}) = {h ∈ H₂ | sPerm e ∉ h}The contraction renamings match the non-bases
For every element e, the contraction renaming for e carries the non-bases of M₁ that contain e onto the non-bases of M₂ that contain s(e).
theorem MatroidReconst.conPerm_maps_nonbases (e : Fin 8) : Finset.image (Finset.image ⇑(conPerm e)) ({h ∈ H₁ | e ∈ h}) = {h ∈ H₂ | sPerm e ∈ h}
The answer to Problem 15.4.3
Rename the elements of M₂ by undoing s, and call the result N. Then the deletion card of e in M₁ matches the deletion card of the same e in N, and likewise for contraction, for every e. N is isomorphic to M₂, so it is not isomorphic to M₁, and the pair M₁, N answers the problem with no.
Two matroids that are not isomorphic but have matching cards
There are matroids M and N, each on all of the elements 0 to 7, such that for every element e the deletion cards of e match up to renaming and the contraction cards of e match up to renaming, yet M and N are not isomorphic.
theorem MatroidReconst.oxley_15_4_3_refuted : ∃ M N, M.E = univ ∧ N.E = univ ∧ (∀ (e : Fin 8), Nonempty (MatroidIso (M.delete {e}) (N.delete {e})) ∧ Nonempty (MatroidIso (M.contract {e}) (N.contract {e}))) ∧ ¬Nonempty (MatroidIso M N)- The matroid N
- N uses all eight elements
- N is isomorphic to M₂
- N has rank 4
M₁ and N are not isomorphic
There is no isomorphism from M₁ to N.
theorem MatroidReconst.M₁_not_iso_N : ¬Nonempty (MatroidIso M₁ N)
- Deleting e from N is renaming a deletion card of M₂
- Contracting e in N is renaming a contraction card of M₂
- The match of deletion card s(e) of M₂ with deletion card e of N
- The match of contraction card s(e) of M₂ with contraction card e of N
- The match of deletion card e of M₁ with deletion card e of N
- The match of contraction card e of M₁ with contraction card e of N