/- Copyright 2025 The Formal Conjectures Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. -/ import FormalConjecturesUtil

Testing Graph Invariants

This file contains tests for graph invariants on 5 specific concrete graphs:

    HouseGraph: A graph on 5 vertices.

    K4: The complete graph on 4 vertices.

    PetersenGraph: The Petersen graph on 10 vertices.

    C6: The cycle graph on 6 vertices.

    Star5: The star graph with 5 leaves (6 vertices total).

Tests cover: independence_number, dominationNumber, average_distance, diameter, radius, girth, order, size, szeged_index, wiener_index, min_degree, max_degree, average_degree, matching_number, residue, annihilation_number, cvetkovic.

open SimpleGraph namespace WrittenOnTheWallII.Test open Classical

House Graph: Square 0-1-2-3-0 with roof 4 connected to 2,3.

abbrev HouseGraph : SimpleGraph (Fin 5) := SimpleGraph.fromEdgeSet { s(0, 1), s(1, 2), s(2, 3), s(3, 0), s(2, 4), s(3, 4) }

K4: Complete graph on 4 vertices.

abbrev K4 : SimpleGraph (Fin 4) := completeGraph (Fin 4)

Petersen Graph on 10 vertices.

abbrev PetersenGraph : SimpleGraph (Fin 10) := SimpleGraph.fromEdgeSet { -- Outer Cycle s(0, 1), s(1, 2), s(2, 3), s(3, 4), s(4, 0), -- Spokes s(0, 5), s(1, 6), s(2, 7), s(3, 8), s(4, 9), -- Inner Star s(5, 7), s(7, 9), s(9, 6), s(6, 8), s(8, 5) }

C6: Cycle graph on 6 vertices.

abbrev C6 : SimpleGraph (Fin 6) := cycleGraph 6

Star5: Star graph with center 0 and 5 leaves.

abbrev Star5 : SimpleGraph (Fin 1 Fin 5) := completeBipartiteGraph (Fin 1) (Fin 5) instance : DecidableRel Star5.Adj := DecidableRel Star5.Adj DecidableRel { Adj := fun v w => v.isLeft = true w.isRight = true v.isRight = true w.isLeft = true, symm := , loopless := }.Adj; All goals completed! 🐙 /- ### House Graph Tests -/ @[category test, AMS 5] theorem house_indep : α(HouseGraph) = 2 := α(HouseGraph) = 2 HouseGraph.computable_indep_num = 2; All goals completed! 🐙 @[category test, AMS 5] theorem house_dom : dominationNumber HouseGraph = 2 := HouseGraph.dominationNumber = 2 HouseGraph.computable_dom_num = 2; All goals completed! 🐙 @[category test, AMS 5] theorem house_avg_dist : averageDistance HouseGraph = 7/5 := HouseGraph.averageDistance = 7 / 5 (7 / 5) = 7 / 5 All goals completed! 🐙 @[category test, AMS 5] theorem house_diameter : ediam HouseGraph = 2 := HouseGraph.ediam = 2 HouseGraph.computable_ediam = 2 exact_mod_cast (HouseGraph.computable_ediam = 2 All goals completed! 🐙 : computable_ediam HouseGraph = 2) @[category test, AMS 5] theorem house_radius : radius HouseGraph = 2 := HouseGraph.radius = 2 HouseGraph.computable_radius = 2 exact_mod_cast (HouseGraph.computable_radius = 2 All goals completed! 🐙 : computable_radius HouseGraph = 2) @[category test, AMS 5] theorem house_girth : HouseGraph.girth = 3 := HouseGraph.girth = 3 have hcyc : (Walk.cons (show HouseGraph.Adj 2 3 HouseGraph.girth = 3 All goals completed! 🐙) (Walk.cons (show HouseGraph.Adj 3 4 HouseGraph.girth = 3 All goals completed! 🐙) (Walk.cons (show HouseGraph.Adj 4 2 HouseGraph.girth = 3 All goals completed! 🐙) Walk.nil))).IsCycle := HouseGraph.girth = 3 (Walk.cons (Walk.cons (Walk.cons Walk.nil))).IsTrail Walk.cons (Walk.cons (Walk.cons Walk.nil)) Walk.nil (Walk.cons (Walk.cons (Walk.cons Walk.nil))).support.tail.Nodup (Walk.cons (Walk.cons (Walk.cons Walk.nil))).IsTrailWalk.cons (Walk.cons (Walk.cons Walk.nil)) Walk.nil(Walk.cons (Walk.cons (Walk.cons Walk.nil))).support.tail.Nodup (Walk.cons (Walk.cons (Walk.cons Walk.nil))).IsTrail (Walk.cons (Walk.cons (Walk.cons Walk.nil))).edges.Nodup; All goals completed! 🐙 Walk.cons (Walk.cons (Walk.cons Walk.nil)) Walk.nil All goals completed! 🐙 (Walk.cons (Walk.cons (Walk.cons Walk.nil))).support.tail.Nodup All goals completed! 🐙 hcyc:(Walk.cons (Walk.cons (Walk.cons Walk.nil))).IsCycle := Eq.mpr (id (congrArg (fun _a => _a) (propext (Walk.isCycle_def (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) Walk.nil))))))) Eq.mpr (id (congrArg (fun _a => _a) (propext (Walk.isTrail_def (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) Walk.nil))))))) (of_decide_eq_true (id (Eq.refl true))), of_eq_true (Eq.trans (congrArg Not (eq_false' fun h => False.elim (noConfusion_of_Nat Walk.ctorIdx h))) not_false_eq_true), of_decide_eq_true (id (Eq.refl true))HouseGraph.girth 3 All goals completed! 🐙 @[category test, AMS 5] theorem house_order : Fintype.card ( : Subgraph HouseGraph).verts = 5 := Fintype.card .verts = 5 Fintype.card (Fin 5) = 5 All goals completed! 🐙 @[category test, AMS 5] theorem house_size : HouseGraph.edgeFinset.card = 6 := HouseGraph.edgeFinset.card = 6 All goals completed! 🐙 @[category test, AMS 5] theorem house_szeged : szegedIndex HouseGraph = 24 := HouseGraph.szegedIndex = 24 HouseGraph.computable_szeged_index = 24; All goals completed! 🐙 @[category test, AMS 5] theorem house_wiener : wienerIndex HouseGraph = 14 := HouseGraph.wienerIndex = 14 HouseGraph.computable_wiener = 14; All goals completed! 🐙 @[category test, AMS 5] theorem house_min_deg : HouseGraph.minDegree = 2 := HouseGraph.minDegree = 2 All goals completed! 🐙 @[category test, AMS 5] theorem house_max_deg : HouseGraph.maxDegree = 3 := HouseGraph.maxDegree = 3 All goals completed! 🐙 @[category test, AMS 5] theorem house_avg_deg : averageDegree HouseGraph = 12/5 := HouseGraph.averageDegree = 12 / 5 (∑ v, (HouseGraph.degree v)) / (Fintype.card (Fin 5)) = 12 / 5; v, (HouseGraph.degree v) = 12; All goals completed! 🐙 @[category test, AMS 5] theorem house_matching : matchingNumber HouseGraph = 2 := HouseGraph.matchingNumber = 2 have hbdd : BddAbove (Set.image (fun M : Subgraph HouseGraph => (M.edgeSet.toFinset.card : )) {M | M.IsMatching}) := HouseGraph.matchingNumber = 2 (Fintype.card (Fin 5)) upperBounds ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) M:HouseGraph.SubgraphhM:M {M | M.IsMatching}(fun M => M.edgeSet.toFinset.card) M (Fintype.card (Fin 5)) M:HouseGraph.SubgraphhM:M {M | M.IsMatching}M.edgeSet.toFinset.card (Fintype.card (Fin 5)) M:HouseGraph.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 5) := matching_card_bound HouseGraph M hMM.edgeSet.toFinset.card (Fintype.card (Fin 5)) exact_mod_cast (M:HouseGraph.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 5) := matching_card_bound HouseGraph M hMM.edgeSet.toFinset.card Fintype.card (Fin 5) All goals completed! 🐙 : M.edgeSet.toFinset.card Fintype.card (Fin 5)) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) = 2 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) 2hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))2 have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) 2 apply csSup_le (Set.Nonempty.image _ , hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a)) {M | M.IsMatching} All goals completed! 🐙) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))M:HouseGraph.SubgraphhM:M {M | M.IsMatching}(fun M => M.edgeSet.toFinset.card) M 2 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))M:HouseGraph.SubgraphhM:M {M | M.IsMatching}M.edgeSet.toFinset.card 2 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))M:HouseGraph.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 5) := matching_card_bound HouseGraph M hMM.edgeSet.toFinset.card 2 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))M:HouseGraph.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card 5M.edgeSet.toFinset.card 2 exact_mod_cast (hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))M:HouseGraph.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card 5M.edgeSet.toFinset.card 2 All goals completed! 🐙 : M.edgeSet.toFinset.card 2) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))2 have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))2 (fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching} refine HouseGraph.subgraphOfAdj (show HouseGraph.Adj 0 1 HouseGraph.matchingNumber = 2 All goals completed! 🐙) HouseGraph.subgraphOfAdj (show HouseGraph.Adj 2 3 HouseGraph.matchingNumber = 2 All goals completed! 🐙), ?_, ?_ hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))HouseGraph.subgraphOfAdj HouseGraph.subgraphOfAdj {M | M.IsMatching} exact (Subgraph.IsMatching.subgraphOfAdj _).sup (Subgraph.IsMatching.subgraphOfAdj _) (hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))Disjoint (HouseGraph.subgraphOfAdj ).support (HouseGraph.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))Disjoint {0, 1} {2, 3}; All goals completed! 🐙) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 5)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound HouseGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => house_matching._proof_1 M hb a))(fun M => M.edgeSet.toFinset.card) (HouseGraph.subgraphOfAdj HouseGraph.subgraphOfAdj ) = 2 All goals completed! 🐙 @[category test, AMS 5] theorem house_residue : residue HouseGraph = 2 := HouseGraph.residue = 2 residueAux ((Multiset.map (fun v => HouseGraph.degree v) Finset.univ.val).sort fun x1 x2 => x1 x2) = 2; All goals completed! 🐙 @[category test, AMS 5] theorem house_annihilation : annihilationNumber HouseGraph = 3 := HouseGraph.annihilationNumber = 3 All goals completed! 🐙 @[category test, AMS 5] theorem declaration uses 'sorry'house_cvetkovic : cvetkovic HouseGraph = 3 := HouseGraph.cvetkovic = 3 All goals completed! 🐙 /- ### K4 Tests -/ @[category test, AMS 5] theorem K4_indep : α(K4) = 1 := α(K4) = 1 K4.computable_indep_num = 1; All goals completed! 🐙 @[category test, AMS 5] theorem K4_dom : dominationNumber K4 = 1 := K4.dominationNumber = 1 K4.computable_dom_num = 1; All goals completed! 🐙 @[category test, AMS 5] theorem K4_avg_dist : averageDistance K4 = 1 := K4.averageDistance = 1 1 = 1 All goals completed! 🐙 @[category test, AMS 5] theorem K4_diameter : ediam K4 = 1 := K4.ediam = 1 K4.computable_ediam = 1 exact_mod_cast (K4.computable_ediam = 1 All goals completed! 🐙 : computable_ediam K4 = 1) @[category test, AMS 5] theorem K4_radius : radius K4 = 1 := K4.radius = 1 K4.computable_radius = 1 exact_mod_cast (K4.computable_radius = 1 All goals completed! 🐙 : computable_radius K4 = 1) @[category test, AMS 5] theorem K4_girth : K4.girth = 3 := K4.girth = 3 have hcyc : (Walk.cons (show K4.Adj 0 1 K4.girth = 3 All goals completed! 🐙) (Walk.cons (show K4.Adj 1 2 K4.girth = 3 All goals completed! 🐙) (Walk.cons (show K4.Adj 2 0 K4.girth = 3 All goals completed! 🐙) Walk.nil))).IsCycle := K4.girth = 3 (Walk.cons (Walk.cons (Walk.cons Walk.nil))).IsTrail Walk.cons (Walk.cons (Walk.cons Walk.nil)) Walk.nil (Walk.cons (Walk.cons (Walk.cons Walk.nil))).support.tail.Nodup (Walk.cons (Walk.cons (Walk.cons Walk.nil))).IsTrailWalk.cons (Walk.cons (Walk.cons Walk.nil)) Walk.nil(Walk.cons (Walk.cons (Walk.cons Walk.nil))).support.tail.Nodup (Walk.cons (Walk.cons (Walk.cons Walk.nil))).IsTrail (Walk.cons (Walk.cons (Walk.cons Walk.nil))).edges.Nodup; All goals completed! 🐙 Walk.cons (Walk.cons (Walk.cons Walk.nil)) Walk.nil All goals completed! 🐙 (Walk.cons (Walk.cons (Walk.cons Walk.nil))).support.tail.Nodup All goals completed! 🐙 hcyc:(Walk.cons (Walk.cons (Walk.cons Walk.nil))).IsCycle := Eq.mpr (id (congrArg (fun _a => _a) (propext (Walk.isCycle_def (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) Walk.nil))))))) Eq.mpr (id (congrArg (fun _a => _a) (propext (Walk.isTrail_def (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) (Walk.cons (have this := of_decide_eq_true (id (Eq.refl true)); this) Walk.nil))))))) (of_decide_eq_true (id (Eq.refl true))), of_eq_true (Eq.trans (congrArg Not (eq_false' fun h => False.elim (noConfusion_of_Nat Walk.ctorIdx h))) not_false_eq_true), of_decide_eq_true (id (Eq.refl true))K4.girth 3 All goals completed! 🐙 @[category test, AMS 5] theorem K4_order : Fintype.card ( : Subgraph K4).verts = 4 := Fintype.card .verts = 4 Fintype.card (Fin 4) = 4 All goals completed! 🐙 @[category test, AMS 5] theorem K4_size : K4.edgeFinset.card = 6 := K4.edgeFinset.card = 6 All goals completed! 🐙 @[category test, AMS 5] theorem K4_szeged : szegedIndex K4 = 6 := K4.szegedIndex = 6 K4.computable_szeged_index = 6; All goals completed! 🐙 @[category test, AMS 5] theorem K4_wiener : wienerIndex K4 = 6 := K4.wienerIndex = 6 K4.computable_wiener = 6; All goals completed! 🐙 @[category test, AMS 5] theorem K4_min_deg : K4.minDegree = 3 := K4.minDegree = 3 All goals completed! 🐙 @[category test, AMS 5] theorem K4_max_deg : K4.maxDegree = 3 := K4.maxDegree = 3 All goals completed! 🐙 @[category test, AMS 5] theorem K4_avg_deg : averageDegree K4 = 3 := K4.averageDegree = 3 (∑ v, (K4.degree v)) / (Fintype.card (Fin 4)) = 3; All goals completed! 🐙 @[category test, AMS 5] theorem K4_matching : matchingNumber K4 = 2 := K4.matchingNumber = 2 have hbdd : BddAbove (Set.image (fun M : Subgraph K4 => (M.edgeSet.toFinset.card : )) {M | M.IsMatching}) := K4.matchingNumber = 2 (Fintype.card (Fin 4)) upperBounds ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) M:K4.SubgraphhM:M {M | M.IsMatching}(fun M => M.edgeSet.toFinset.card) M (Fintype.card (Fin 4)) M:K4.SubgraphhM:M {M | M.IsMatching}M.edgeSet.toFinset.card (Fintype.card (Fin 4)) M:K4.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 4) := matching_card_bound K4 M hMM.edgeSet.toFinset.card (Fintype.card (Fin 4)) exact_mod_cast (M:K4.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 4) := matching_card_bound K4 M hMM.edgeSet.toFinset.card Fintype.card (Fin 4) All goals completed! 🐙 : M.edgeSet.toFinset.card Fintype.card (Fin 4)) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) = 2 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) 2hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))2 have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) 2 apply csSup_le (Set.Nonempty.image _ , hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a)) {M | M.IsMatching} All goals completed! 🐙) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))M:K4.SubgraphhM:M {M | M.IsMatching}(fun M => M.edgeSet.toFinset.card) M 2 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))M:K4.SubgraphhM:M {M | M.IsMatching}M.edgeSet.toFinset.card 2 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))M:K4.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 4) := matching_card_bound K4 M hMM.edgeSet.toFinset.card 2 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))M:K4.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card 4M.edgeSet.toFinset.card 2 exact_mod_cast (hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))M:K4.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card 4M.edgeSet.toFinset.card 2 All goals completed! 🐙 : M.edgeSet.toFinset.card 2) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))2 have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))2 (fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching} refine K4.subgraphOfAdj (show K4.Adj 0 1 K4.matchingNumber = 2 All goals completed! 🐙) K4.subgraphOfAdj (show K4.Adj 2 3 K4.matchingNumber = 2 All goals completed! 🐙), ?_, ?_ hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))K4.subgraphOfAdj K4.subgraphOfAdj {M | M.IsMatching} exact (Subgraph.IsMatching.subgraphOfAdj _).sup (Subgraph.IsMatching.subgraphOfAdj _) (hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))Disjoint (K4.subgraphOfAdj ).support (K4.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))Disjoint {0, 1} {2, 3}; All goals completed! 🐙) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 4)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound K4 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => K4_matching._proof_1 M hb a))(fun M => M.edgeSet.toFinset.card) (K4.subgraphOfAdj K4.subgraphOfAdj ) = 2 All goals completed! 🐙 @[category test, AMS 5] theorem K4_residue : residue K4 = 1 := K4.residue = 1 residueAux ((Multiset.map (fun v => K4.degree v) Finset.univ.val).sort fun x1 x2 => x1 x2) = 1; All goals completed! 🐙 @[category test, AMS 5] theorem K4_annihilation : annihilationNumber K4 = 2 := K4.annihilationNumber = 2 All goals completed! 🐙 @[category test, AMS 5] theorem declaration uses 'sorry'K4_cvetkovic : cvetkovic K4 = 1 := K4.cvetkovic = 1 All goals completed! 🐙 /- ### Petersen Graph Tests -/ @[category test, AMS 5] theorem petersen_indep : α(PetersenGraph) = 4 := α(PetersenGraph) = 4 PetersenGraph.computable_indep_num = 4; All goals completed! 🐙 @[category test, AMS 5] theorem petersen_dom : dominationNumber PetersenGraph = 3 := PetersenGraph.dominationNumber = 3 PetersenGraph.computable_dom_num = 3; All goals completed! 🐙 @[category test, AMS 5] theorem petersen_avg_dist : averageDistance PetersenGraph = 5/3 := PetersenGraph.averageDistance = 5 / 3 (5 / 3) = 5 / 3 All goals completed! 🐙 @[category test, AMS 5] theorem petersen_diameter : ediam PetersenGraph = 2 := PetersenGraph.ediam = 2 PetersenGraph.computable_ediam = 2 exact_mod_cast (PetersenGraph.computable_ediam = 2 All goals completed! 🐙 : computable_ediam PetersenGraph = 2) @[category test, AMS 5] theorem petersen_radius : radius PetersenGraph = 2 := PetersenGraph.radius = 2 PetersenGraph.computable_radius = 2 exact_mod_cast (PetersenGraph.computable_radius = 2 All goals completed! 🐙 : computable_radius PetersenGraph = 2) @[category test, AMS 5] theorem declaration uses 'sorry'petersen_girth : PetersenGraph.girth = 5 := PetersenGraph.girth = 5 All goals completed! 🐙 @[category test, AMS 5] theorem petersen_order : Fintype.card ( : Subgraph PetersenGraph).verts = 10 := Fintype.card .verts = 10 Fintype.card (Fin 10) = 10 All goals completed! 🐙 @[category test, AMS 5] theorem petersen_size : PetersenGraph.edgeFinset.card = 15 := PetersenGraph.edgeFinset.card = 15 All goals completed! 🐙 @[category test, AMS 5] theorem petersen_szeged : szegedIndex PetersenGraph = 135 := PetersenGraph.szegedIndex = 135 PetersenGraph.computable_szeged_index = 135; All goals completed! 🐙 @[category test, AMS 5] theorem petersen_wiener : wienerIndex PetersenGraph = 75 := PetersenGraph.wienerIndex = 75 PetersenGraph.computable_wiener = 75; All goals completed! 🐙 @[category test, AMS 5] theorem petersen_min_deg : PetersenGraph.minDegree = 3 := PetersenGraph.minDegree = 3 All goals completed! 🐙 @[category test, AMS 5] theorem petersen_max_deg : PetersenGraph.maxDegree = 3 := PetersenGraph.maxDegree = 3 All goals completed! 🐙 @[category test, AMS 5] theorem petersen_avg_deg : averageDegree PetersenGraph = 3 := PetersenGraph.averageDegree = 3 (∑ v, (PetersenGraph.degree v)) / (Fintype.card (Fin 10)) = 3; (∑ v, (PetersenGraph.degree v)) / 10 = 3; All goals completed! 🐙 @[category test, AMS 5] theorem petersen_matching : matchingNumber PetersenGraph = 5 := PetersenGraph.matchingNumber = 5 have hbdd : BddAbove (Set.image (fun M : Subgraph PetersenGraph => (M.edgeSet.toFinset.card : )) {M | M.IsMatching}) := PetersenGraph.matchingNumber = 5 (Fintype.card (Fin 10)) upperBounds ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) M:PetersenGraph.SubgraphhM:M {M | M.IsMatching}(fun M => M.edgeSet.toFinset.card) M (Fintype.card (Fin 10)) M:PetersenGraph.SubgraphhM:M {M | M.IsMatching}M.edgeSet.toFinset.card (Fintype.card (Fin 10)) M:PetersenGraph.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 10) := matching_card_bound PetersenGraph M hMM.edgeSet.toFinset.card (Fintype.card (Fin 10)) exact_mod_cast (M:PetersenGraph.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 10) := matching_card_bound PetersenGraph M hMM.edgeSet.toFinset.card Fintype.card (Fin 10) All goals completed! 🐙 : M.edgeSet.toFinset.card Fintype.card (Fin 10)) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) = 5 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) 5hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))5 have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) 5 apply csSup_le (Set.Nonempty.image _ , hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a)) {M | M.IsMatching} All goals completed! 🐙) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))M:PetersenGraph.SubgraphhM:M {M | M.IsMatching}(fun M => M.edgeSet.toFinset.card) M 5 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))M:PetersenGraph.SubgraphhM:M {M | M.IsMatching}M.edgeSet.toFinset.card 5 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))M:PetersenGraph.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 10) := matching_card_bound PetersenGraph M hMM.edgeSet.toFinset.card 5 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))M:PetersenGraph.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card 10M.edgeSet.toFinset.card 5 exact_mod_cast (hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))M:PetersenGraph.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card 10M.edgeSet.toFinset.card 5 All goals completed! 🐙 : M.edgeSet.toFinset.card 5) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))5 have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))5 (fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching} refine PetersenGraph.subgraphOfAdj (show PetersenGraph.Adj 0 5 PetersenGraph.matchingNumber = 5 All goals completed! 🐙) PetersenGraph.subgraphOfAdj (show PetersenGraph.Adj 1 6 PetersenGraph.matchingNumber = 5 All goals completed! 🐙) PetersenGraph.subgraphOfAdj (show PetersenGraph.Adj 2 7 PetersenGraph.matchingNumber = 5 All goals completed! 🐙) PetersenGraph.subgraphOfAdj (show PetersenGraph.Adj 3 8 PetersenGraph.matchingNumber = 5 All goals completed! 🐙) PetersenGraph.subgraphOfAdj (show PetersenGraph.Adj 4 9 PetersenGraph.matchingNumber = 5 All goals completed! 🐙), ?_, ?_ hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj {M | M.IsMatching} hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).IsMatchinghbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj ).IsMatchinghbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint (PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).support (PetersenGraph.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).IsMatching hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).IsMatchinghbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj ).IsMatchinghbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint (PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).support (PetersenGraph.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).IsMatching hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).IsMatchinghbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj ).IsMatchinghbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint (PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).support (PetersenGraph.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).IsMatching exact (Subgraph.IsMatching.subgraphOfAdj _).sup (Subgraph.IsMatching.subgraphOfAdj _) (hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint (PetersenGraph.subgraphOfAdj ).support (PetersenGraph.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint {0, 5} {1, 6}; All goals completed! 🐙) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj ).IsMatching All goals completed! 🐙 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint (PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).support (PetersenGraph.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint (PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).verts (PetersenGraph.subgraphOfAdj ).verts All goals completed! 🐙 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj ).IsMatching All goals completed! 🐙 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint (PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).support (PetersenGraph.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint (PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).verts (PetersenGraph.subgraphOfAdj ).verts All goals completed! 🐙 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(PetersenGraph.subgraphOfAdj ).IsMatching All goals completed! 🐙 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint (PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).support (PetersenGraph.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))Disjoint (PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ).verts (PetersenGraph.subgraphOfAdj ).verts All goals completed! 🐙 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 10)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound PetersenGraph M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => petersen_matching._proof_1 M hb a))(fun M => M.edgeSet.toFinset.card) (PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj PetersenGraph.subgraphOfAdj ) = 5 All goals completed! 🐙 @[category test, AMS 5] theorem petersen_residue : residue PetersenGraph = 3 := PetersenGraph.residue = 3 residueAux ((Multiset.map (fun v => PetersenGraph.degree v) Finset.univ.val).sort fun x1 x2 => x1 x2) = 3; All goals completed! 🐙 @[category test, AMS 5] theorem petersen_annihilation : annihilationNumber PetersenGraph = 5 := PetersenGraph.annihilationNumber = 5 All goals completed! 🐙 @[category test, AMS 5] theorem declaration uses 'sorry'petersen_cvetkovic : cvetkovic PetersenGraph = 4 := PetersenGraph.cvetkovic = 4 All goals completed! 🐙 /- ### C6 Tests -/ @[category test, AMS 5] theorem C6_indep : α(C6) = 3 := α(C6) = 3 C6.computable_indep_num = 3; All goals completed! 🐙 @[category test, AMS 5] theorem C6_dom : dominationNumber C6 = 2 := C6.dominationNumber = 2 C6.computable_dom_num = 2; All goals completed! 🐙 @[category test, AMS 5] theorem C6_avg_dist : averageDistance C6 = 9/5 := C6.averageDistance = 9 / 5 (9 / 5) = 9 / 5 All goals completed! 🐙 @[category test, AMS 5] theorem C6_diameter : ediam C6 = 3 := C6.ediam = 3 C6.computable_ediam = 3 exact_mod_cast (C6.computable_ediam = 3 All goals completed! 🐙 : computable_ediam C6 = 3) @[category test, AMS 5] theorem C6_radius : radius C6 = 3 := C6.radius = 3 C6.computable_radius = 3 exact_mod_cast (C6.computable_radius = 3 All goals completed! 🐙 : computable_radius C6 = 3) @[category test, AMS 5] theorem declaration uses 'sorry'C6_girth : C6.girth = 6 := C6.girth = 6 All goals completed! 🐙 @[category test, AMS 5] theorem C6_order : Fintype.card ( : Subgraph C6).verts = 6 := Fintype.card .verts = 6 Fintype.card (Fin 6) = 6 All goals completed! 🐙 @[category test, AMS 5] theorem C6_size : C6.edgeFinset.card = 6 := C6.edgeFinset.card = 6 All goals completed! 🐙 @[category test, AMS 5] theorem C6_szeged : szegedIndex C6 = 54 := C6.szegedIndex = 54 C6.computable_szeged_index = 54; All goals completed! 🐙 @[category test, AMS 5] theorem C6_wiener : wienerIndex C6 = 27 := C6.wienerIndex = 27 C6.computable_wiener = 27; All goals completed! 🐙 @[category test, AMS 5] theorem C6_min_deg : C6.minDegree = 2 := C6.minDegree = 2 All goals completed! 🐙 @[category test, AMS 5] theorem C6_max_deg : C6.maxDegree = 2 := C6.maxDegree = 2 All goals completed! 🐙 @[category test, AMS 5] theorem C6_avg_deg : averageDegree C6 = 2 := C6.averageDegree = 2 (∑ v, (C6.degree v)) / (Fintype.card (Fin 6)) = 2; (∑ v, (C6.degree v)) / 6 = 2; All goals completed! 🐙 @[category test, AMS 5] theorem C6_matching : matchingNumber C6 = 3 := C6.matchingNumber = 3 have hbdd : BddAbove (Set.image (fun M : Subgraph C6 => (M.edgeSet.toFinset.card : )) {M | M.IsMatching}) := C6.matchingNumber = 3 (Fintype.card (Fin 6)) upperBounds ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) M:C6.SubgraphhM:M {M | M.IsMatching}(fun M => M.edgeSet.toFinset.card) M (Fintype.card (Fin 6)) M:C6.SubgraphhM:M {M | M.IsMatching}M.edgeSet.toFinset.card (Fintype.card (Fin 6)) M:C6.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 6) := matching_card_bound C6 M hMM.edgeSet.toFinset.card (Fintype.card (Fin 6)) exact_mod_cast (M:C6.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 6) := matching_card_bound C6 M hMM.edgeSet.toFinset.card Fintype.card (Fin 6) All goals completed! 🐙 : M.edgeSet.toFinset.card Fintype.card (Fin 6)) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) = 3 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) 3hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))3 have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) 3 apply csSup_le (Set.Nonempty.image _ , hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a)) {M | M.IsMatching} All goals completed! 🐙) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))M:C6.SubgraphhM:M {M | M.IsMatching}(fun M => M.edgeSet.toFinset.card) M 3 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))M:C6.SubgraphhM:M {M | M.IsMatching}M.edgeSet.toFinset.card 3 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))M:C6.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card Fintype.card (Fin 6) := matching_card_bound C6 M hMM.edgeSet.toFinset.card 3 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))M:C6.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card 6M.edgeSet.toFinset.card 3 exact_mod_cast (hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))M:C6.SubgraphhM:M {M | M.IsMatching}hb:2 * M.edgeSet.toFinset.card 6M.edgeSet.toFinset.card 3 All goals completed! 🐙 : M.edgeSet.toFinset.card 3) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))3 have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))3 (fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching} refine C6.subgraphOfAdj (show C6.Adj 0 1 C6.matchingNumber = 3 All goals completed! 🐙) C6.subgraphOfAdj (show C6.Adj 2 3 C6.matchingNumber = 3 All goals completed! 🐙) C6.subgraphOfAdj (show C6.Adj 4 5 C6.matchingNumber = 3 All goals completed! 🐙), ?_, ?_ hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))C6.subgraphOfAdj C6.subgraphOfAdj C6.subgraphOfAdj {M | M.IsMatching} hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))(C6.subgraphOfAdj C6.subgraphOfAdj ).IsMatchinghbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))(C6.subgraphOfAdj ).IsMatchinghbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))Disjoint (C6.subgraphOfAdj C6.subgraphOfAdj ).support (C6.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))(C6.subgraphOfAdj C6.subgraphOfAdj ).IsMatching exact (Subgraph.IsMatching.subgraphOfAdj _).sup (Subgraph.IsMatching.subgraphOfAdj _) (hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))Disjoint (C6.subgraphOfAdj ).support (C6.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))Disjoint {0, 1} {2, 3}; All goals completed! 🐙) hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))(C6.subgraphOfAdj ).IsMatching All goals completed! 🐙 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))Disjoint (C6.subgraphOfAdj C6.subgraphOfAdj ).support (C6.subgraphOfAdj ).support hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))Disjoint (C6.subgraphOfAdj C6.subgraphOfAdj ).verts (C6.subgraphOfAdj ).verts All goals completed! 🐙 hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro (Fintype.card (Fin 6)) fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (have hb := matching_card_bound C6 M hM; cast (Eq.symm Nat.cast_le._simp_1) (Decidable.byContradiction fun a => C6_matching._proof_1 M hb a))(fun M => M.edgeSet.toFinset.card) (C6.subgraphOfAdj C6.subgraphOfAdj C6.subgraphOfAdj ) = 3 All goals completed! 🐙 @[category test, AMS 5] theorem C6_residue : residue C6 = 2 := C6.residue = 2 residueAux ((Multiset.map (fun v => C6.degree v) Finset.univ.val).sort fun x1 x2 => x1 x2) = 2; All goals completed! 🐙 @[category test, AMS 5] theorem C6_annihilation : annihilationNumber C6 = 3 := C6.annihilationNumber = 3 All goals completed! 🐙 @[category test, AMS 5] theorem declaration uses 'sorry'C6_cvetkovic : cvetkovic C6 = 3 := C6.cvetkovic = 3 All goals completed! 🐙 /- ### Star5 Tests -/ @[category test, AMS 5] theorem Star5_indep : α(Star5) = 5 := α(Star5) = 5 Star5.computable_indep_num = 5; All goals completed! 🐙 @[category test, AMS 5] theorem Star5_dom : dominationNumber Star5 = 1 := Star5.dominationNumber = 1 Star5.computable_dom_num = 1; All goals completed! 🐙 @[category test, AMS 5] theorem Star5_avg_dist : averageDistance Star5 = 5/3 := Star5.averageDistance = 5 / 3 (5 / 3) = 5 / 3 All goals completed! 🐙 @[category test, AMS 5] theorem Star5_diameter : ediam Star5 = 2 := Star5.ediam = 2 Star5.computable_ediam = 2 exact_mod_cast (Star5.computable_ediam = 2 All goals completed! 🐙 : computable_ediam Star5 = 2) @[category test, AMS 5] theorem Star5_radius : radius Star5 = 1 := Star5.radius = 1 Star5.computable_radius = 1 exact_mod_cast (Star5.computable_radius = 1 All goals completed! 🐙 : computable_radius Star5 = 1) @[category test, AMS 5] theorem Star5_girth : Star5.egirth = := Star5.egirth = Star5.IsAcyclic have key : (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬ c.IsCycle := Star5.egirth = intro b b:Fin 5c:Star5.Walk (Sum.inr b) (Sum.inr b)¬c.IsCycle b:Fin 5c:Star5.Walk (Sum.inr b) (Sum.inr b)hc:c.IsCycleFalse b:Fin 5c:Star5.Walk (Sum.inr b) (Sum.inr b)hc:c.IsCycleh1:Star5.Adj (Sum.inr b) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)False b:Fin 5c:Star5.Walk (Sum.inr b) (Sum.inr b)hc:c.IsCycleh1:Star5.Adj (Sum.inr b) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)h2:Star5.Adj c.penultimate (Sum.inr b) := Walk.adj_penultimate (Walk.IsCycle.not_nil hc)False have hs : c.snd.isLeft := Star5.egirth = b:Fin 5c:Star5.Walk (Sum.inr b) (Sum.inr b)hc:c.IsCycleh2:Star5.Adj c.penultimate (Sum.inr b) := Walk.adj_penultimate (Walk.IsCycle.not_nil hc)h1:false = true c.snd.isRight = true True c.snd.isLeft = truec.snd.isLeft = true All goals completed! 🐙 have hp : c.penultimate.isLeft := Star5.egirth = b:Fin 5c:Star5.Walk (Sum.inr b) (Sum.inr b)hc:c.IsCycleh1:Star5.Adj (Sum.inr b) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)hs:c.snd.isLeft = true := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => righth2:c.penultimate.isLeft = true True c.penultimate.isRight = true false = truec.penultimate.isLeft = true All goals completed! 🐙 b:Fin 5c:Star5.Walk (Sum.inr b) (Sum.inr b)hc:c.IsCycleh1:Star5.Adj (Sum.inr b) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)h2:Star5.Adj c.penultimate (Sum.inr b) := Walk.adj_penultimate (Walk.IsCycle.not_nil hc)hs:c.snd.isLeft = true := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => righthp:c.penultimate.isLeft = true := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right)c.snd = c.penultimate b:Fin 5c:Star5.Walk (Sum.inr b) (Sum.inr b)hc:c.IsCycleh1:Star5.Adj (Sum.inr b) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)h2:Star5.Adj c.penultimate (Sum.inr b) := Walk.adj_penultimate (Walk.IsCycle.not_nil hc)hs:c.snd.isLeft = true := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => righthp:c.penultimate.isLeft = true := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right)x:Fin 1hx:c.snd = Sum.inl xc.snd = c.penultimate b:Fin 5c:Star5.Walk (Sum.inr b) (Sum.inr b)hc:c.IsCycleh1:Star5.Adj (Sum.inr b) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)h2:Star5.Adj c.penultimate (Sum.inr b) := Walk.adj_penultimate (Walk.IsCycle.not_nil hc)hs:c.snd.isLeft = true := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => righthp:c.penultimate.isLeft = true := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right)x:Fin 1hx:c.snd = Sum.inl xy:Fin 1hy:c.penultimate = Sum.inl yc.snd = c.penultimate All goals completed! 🐙 intro v key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))v:Fin 1 Fin 5c:Star5.Walk v v¬c.IsCycle key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))v:Fin 1 Fin 5c:Star5.Walk v vhc:c.IsCycleFalse cases v with key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))b:Fin 5c:Star5.Walk (Sum.inr b) (Sum.inr b)hc:c.IsCycleFalse All goals completed! 🐙 key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))a:Fin 1c:Star5.Walk (Sum.inl a) (Sum.inl a)hc:c.IsCycleFalse key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))a:Fin 1c:Star5.Walk (Sum.inl a) (Sum.inl a)hc:c.IsCycleh1:Star5.Adj (Sum.inl a) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)False obtain b, hb : b, c.snd = Sum.inr b := key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))a:Fin 1c:Star5.Walk (Sum.inl a) (Sum.inl a)hc:c.IsCycleh1:Star5.Adj (Sum.inl a) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc) b, c.snd = Sum.inr b key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))a:Fin 1c:Star5.Walk (Sum.inl a) (Sum.inl a)hc:c.IsCycleh1:Star5.Adj (Sum.inl a) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)x:Fin 1hsnd:c.snd = Sum.inl x b, Sum.inl x = Sum.inr bkey: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))a:Fin 1c:Star5.Walk (Sum.inl a) (Sum.inl a)hc:c.IsCycleh1:Star5.Adj (Sum.inl a) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)y:Fin 5hsnd:c.snd = Sum.inr y b, Sum.inr y = Sum.inr b key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))a:Fin 1c:Star5.Walk (Sum.inl a) (Sum.inl a)hc:c.IsCycleh1:Star5.Adj (Sum.inl a) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)x:Fin 1hsnd:c.snd = Sum.inl x b, Sum.inl x = Sum.inr b key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))a:Fin 1c:Star5.Walk (Sum.inl a) (Sum.inl a)hc:c.IsCyclex:Fin 1h1:Star5.Adj (Sum.inl a) (Sum.inl x)hsnd:c.snd = Sum.inl x b, Sum.inl x = Sum.inr b; All goals completed! 🐙 key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))a:Fin 1c:Star5.Walk (Sum.inl a) (Sum.inl a)hc:c.IsCycleh1:Star5.Adj (Sum.inl a) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)y:Fin 5hsnd:c.snd = Sum.inr y b, Sum.inr y = Sum.inr b All goals completed! 🐙 key: (b : Fin 5) (c : Star5.Walk (Sum.inr b) (Sum.inr b)), ¬c.IsCycle := fun b c hc => have h1 := Walk.adj_snd (Walk.IsCycle.not_nil hc); have h2 := Walk.adj_penultimate (Walk.IsCycle.not_nil hc); have hs := Or.casesOn (Eq.mp (congrArg (fun x => false = true c.snd.isRight = true x c.snd.isLeft = true) (eq_self true)) h1) (fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx left)) fun h => And.casesOn h fun left right => right; have hp := Or.casesOn (Eq.mp (congrArg (fun x => c.penultimate.isLeft = true x c.penultimate.isRight = true false = true) (eq_self true)) h2) (fun h => And.casesOn h fun left right => left) fun h => And.casesOn h fun left right => False.elim (noConfusion_of_Nat Bool.ctorIdx right); Walk.IsCycle.snd_ne_penultimate hc (Exists.casesOn (Sum.isLeft_iff.mp hs) fun x hx => Exists.casesOn (Sum.isLeft_iff.mp hp) fun y hy => Eq.mpr (id (congrArg (fun _a => _a = c.penultimate) hx)) (Eq.mpr (id (congrArg (fun _a => Sum.inl x = _a) hy)) (Eq.mpr (id (congrArg (fun _a => Sum.inl _a = Sum.inl y) (Subsingleton.elim x y))) (Eq.refl (Sum.inl y)))))a:Fin 1c:Star5.Walk (Sum.inl a) (Sum.inl a)hc:c.IsCycleh1:Star5.Adj (Sum.inl a) c.snd := Walk.adj_snd (Walk.IsCycle.not_nil hc)b:Fin 5hb:c.snd = Sum.inr bhmem:Sum.inr b c.support := hb List.mem_of_mem_tail (Walk.snd_mem_tail_support (Walk.IsCycle.not_nil hc))False All goals completed! 🐙 @[category test, AMS 5] theorem Star5_order : Fintype.card ( : Subgraph Star5).verts = 6 := Fintype.card .verts = 6 Fintype.card (Fin 1 Fin 5) = 6 All goals completed! 🐙 @[category test, AMS 5] theorem Star5_size : Star5.edgeFinset.card = 5 := Star5.edgeFinset.card = 5 All goals completed! 🐙 @[category test, AMS 5] theorem Star5_szeged : szegedIndex Star5 = 25 := Star5.szegedIndex = 25 Star5.computable_szeged_index = 25; All goals completed! 🐙 @[category test, AMS 5] theorem Star5_wiener : wienerIndex Star5 = 25 := Star5.wienerIndex = 25 Star5.computable_wiener = 25; All goals completed! 🐙 @[category test, AMS 5] theorem Star5_min_deg : Star5.minDegree = 1 := Star5.minDegree = 1 All goals completed! 🐙 @[category test, AMS 5] theorem Star5_max_deg : Star5.maxDegree = 5 := Star5.maxDegree = 5 All goals completed! 🐙 @[category test, AMS 5] theorem Star5_avg_deg : averageDegree Star5 = 5/3 := Star5.averageDegree = 5 / 3 (∑ v, (Star5.degree v)) / (Fintype.card (Fin 1 Fin 5)) = 5 / 3; ((Star5.degree (Sum.inl 0)) + a₂, (Star5.degree (Sum.inr a₂))) / 6 = 5 / 3; All goals completed! 🐙 @[category test, AMS 5] theorem Star5_matching : matchingNumber Star5 = 1 := Star5.matchingNumber = 1 have hle : M : Subgraph Star5, M.IsMatching M.edgeSet.toFinset.card 1 := Star5.matchingNumber = 1 intro M M:Star5.SubgraphhM:M.IsMatchingM.edgeSet.toFinset.card 1 have hcenter : e M.edgeSet, (Sum.inl 0 : Fin 1 Fin 5) e := Star5.matchingNumber = 1 intro e M:Star5.SubgraphhM:M.IsMatchinge:Sym2 (Fin 1 Fin 5)he:e M.edgeSetSum.inl 0 e induction e using Sym2.inductionOn with M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:s(a, b) M.edgeSetSum.inl 0 s(a, b) M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:M.Adj a bSum.inl 0 s(a, b) M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:M.Adj a bhadj:Star5.Adj a b := Subgraph.Adj.adj_sub heSum.inl 0 s(a, b) M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:M.Adj a bhadj:a.isLeft = true b.isRight = true a.isRight = true b.isLeft = true := Subgraph.Adj.adj_sub heSum.inl 0 s(a, b) M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:M.Adj a bhadj:a.isLeft = true b.isRight = true a.isRight = true b.isLeft = true := Subgraph.Adj.adj_sub heSum.inl 0 = a Sum.inl 0 = b M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:M.Adj a bha:a.isLeft = trueright✝:b.isRight = trueSum.inl 0 = a Sum.inl 0 = bM:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:M.Adj a bleft✝:a.isRight = truehb:b.isLeft = trueSum.inl 0 = a Sum.inl 0 = b M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:M.Adj a bha:a.isLeft = trueright✝:b.isRight = trueSum.inl 0 = a Sum.inl 0 = b M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:M.Adj a bha:a.isLeft = trueright✝:b.isRight = trueSum.inl 0 = a; M:Star5.SubgraphhM:M.IsMatchingb:Fin 1 Fin 5right✝:b.isRight = truea':Fin 1he:M.Adj (Sum.inl a') bha:(Sum.inl a').isLeft = trueSum.inl 0 = Sum.inl a'; All goals completed! 🐙 M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:M.Adj a bleft✝:a.isRight = truehb:b.isLeft = trueSum.inl 0 = a Sum.inl 0 = b M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5b:Fin 1 Fin 5he:M.Adj a bleft✝:a.isRight = truehb:b.isLeft = trueSum.inl 0 = b; M:Star5.SubgraphhM:M.IsMatchinga:Fin 1 Fin 5left✝:a.isRight = trueb':Fin 1he:M.Adj a (Sum.inl b')hb:(Sum.inl b').isLeft = trueSum.inl 0 = Sum.inl b'; All goals completed! 🐙 M:Star5.SubgraphhM:M.IsMatchinghcenter: e M.edgeSet, Sum.inl 0 e := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he a M.edgeSet.toFinset, b M.edgeSet.toFinset, a = b intro e M:Star5.SubgraphhM:M.IsMatchinghcenter: e M.edgeSet, Sum.inl 0 e := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) hee:Sym2 (Fin 1 Fin 5)he:e M.edgeSet.toFinset b M.edgeSet.toFinset, e = b M:Star5.SubgraphhM:M.IsMatchinghcenter: e M.edgeSet, Sum.inl 0 e := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) hee:Sym2 (Fin 1 Fin 5)he:e M.edgeSet.toFinsetf:Sym2 (Fin 1 Fin 5)f M.edgeSet.toFinset e = f M:Star5.SubgraphhM:M.IsMatchinghcenter: e M.edgeSet, Sum.inl 0 e := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) hee:Sym2 (Fin 1 Fin 5)he:e M.edgeSet.toFinsetf:Sym2 (Fin 1 Fin 5)hf:f M.edgeSet.toFinsete = f M:Star5.SubgraphhM:M.IsMatchinghcenter: e M.edgeSet, Sum.inl 0 e := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) hee:Sym2 (Fin 1 Fin 5)he:e M.edgeSetf:Sym2 (Fin 1 Fin 5)hf:f M.edgeSete = f M:Star5.SubgraphhM:M.IsMatchinghcenter: e M.edgeSet, Sum.inl 0 e := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) hef:Sym2 (Fin 1 Fin 5)hf:f M.edgeSety:Fin 1 Fin 5he:s(Sum.inl 0, y) M.edgeSets(Sum.inl 0, y) = f M:Star5.SubgraphhM:M.IsMatchinghcenter: e M.edgeSet, Sum.inl 0 e := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) hey:Fin 1 Fin 5he:s(Sum.inl 0, y) M.edgeSetz:Fin 1 Fin 5hf:s(Sum.inl 0, z) M.edgeSets(Sum.inl 0, y) = s(Sum.inl 0, z) M:Star5.SubgraphhM:M.IsMatchinghcenter: e M.edgeSet, Sum.inl 0 e := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) hey:Fin 1 Fin 5he:M.Adj (Sum.inl 0) yz:Fin 1 Fin 5hf:M.Adj (Sum.inl 0) zs(Sum.inl 0, y) = s(Sum.inl 0, z) All goals completed! 🐙 have hbdd : BddAbove (Set.image (fun M : Subgraph Star5 => (M.edgeSet.toFinset.card : )) {M | M.IsMatching}) := Star5.matchingNumber = 1 hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)1 upperBounds ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)M:Star5.SubgraphhM:M {M | M.IsMatching}(fun M => M.edgeSet.toFinset.card) M 1 hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)M:Star5.SubgraphhM:M {M | M.IsMatching}M.edgeSet.toFinset.card 1 All goals completed! 🐙 hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) = 1 hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) 1hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM))1 have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings) hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM))(have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings)) 1 apply csSup_le (Set.Nonempty.image _ , hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM)) {M | M.IsMatching} All goals completed! 🐙) hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM))M:Star5.SubgraphhM:M {M | M.IsMatching}(fun M => M.edgeSet.toFinset.card) M 1 hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM))M:Star5.SubgraphhM:M {M | M.IsMatching}M.edgeSet.toFinset.card 1 All goals completed! 🐙 hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM))1 have matchings := {M | M.IsMatching}; sSup ((fun M => M.edgeSet.toFinset.card) '' matchings) hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM))1 (fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching} refine Star5.subgraphOfAdj (show Star5.Adj (Sum.inl 0) (Sum.inr 0) Star5.matchingNumber = 1 All goals completed! 🐙), ?_, ?_ hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM))Star5.subgraphOfAdj {M | M.IsMatching} All goals completed! 🐙 hle: (M : Star5.Subgraph), M.IsMatching M.edgeSet.toFinset.card 1 := fun M hM => have hcenter := fun e he => Sym2.inductionOn e (fun a b he => have hadj := Subgraph.Adj.adj_sub (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he); Eq.mpr (id (congrArg (fun _a => _a) (propext Sym2.mem_iff))) (Or.casesOn hadj (fun h => And.casesOn h fun ha right => Or.inl (Exists.casesOn (Sum.isLeft_iff.mp ha) fun a' h => Eq.ndrec (motive := fun a => M.Adj a b a.isLeft = true Sum.inl 0 = a) (fun he ha => congrArg Sum.inl (Subsingleton.elim 0 a')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) ha)) fun h => And.casesOn h fun left hb => Or.inr (Exists.casesOn (Sum.isLeft_iff.mp hb) fun b' h => Eq.ndrec (motive := fun b => M.Adj a b b.isLeft = true Sum.inl 0 = b) (fun he hb => congrArg Sum.inl (Subsingleton.elim 0 b')) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) hb))) he; Eq.mpr (id (congrArg (fun _a => _a) (propext Finset.card_le_one))) fun e he f hf => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter e (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he))) fun y h => Eq.ndrec (motive := fun e => e M.edgeSet e = f) (fun he => Exists.casesOn (Sym2.mem_iff_exists.mp (hcenter f (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf))) fun z h => Eq.ndrec (motive := fun f => f M.edgeSet s(Sum.inl 0, y) = f) (fun hf => Eq.mpr (id (congrArg (fun _a => s(Sum.inl 0, _a) = s(Sum.inl 0, z)) (Subgraph.IsMatching.eq_of_adj_left hM (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) he) (Eq.mp (congrArg (fun _a => _a) (propext Subgraph.mem_edgeSet)) hf)))) (Eq.refl s(Sum.inl 0, z))) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) hf)) (Eq.symm h) (Eq.mp (congrArg (fun _a => _a) (propext Set.mem_toFinset)) he)hbdd:BddAbove ((fun M => M.edgeSet.toFinset.card) '' {M | M.IsMatching}) := Exists.intro 1 fun x a => Exists.casesOn a fun M h => And.casesOn h fun hM right => right id (cast (Eq.symm (Eq.trans (congrArg (LE.le M.edgeSet.toFinset.card) (Eq.symm Nat.cast_one)) Nat.cast_le._simp_1)) (hle M hM))(fun M => M.edgeSet.toFinset.card) (Star5.subgraphOfAdj ) = 1 All goals completed! 🐙 @[category test, AMS 5] theorem Star5_residue : residue Star5 = 5 := Star5.residue = 5 residueAux ((Multiset.map (fun v => Star5.degree v) Finset.univ.val).sort fun x1 x2 => x1 x2) = 5; All goals completed! 🐙 @[category test, AMS 5] theorem Star5_annihilation : annihilationNumber Star5 = 5 := Star5.annihilationNumber = 5 All goals completed! 🐙 @[category test, AMS 5] theorem declaration uses 'sorry'Star5_cvetkovic : cvetkovic Star5 = 5 := Star5.cvetkovic = 5 All goals completed! 🐙 end WrittenOnTheWallII.Test