MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  konigsberg Structured version   Visualization version   GIF version

Theorem konigsberg 28046
Description: The Königsberg Bridge problem. If 𝐺 is the Königsberg graph, i.e. a graph on four vertices 0, 1, 2, 3, with edges {0, 1}, {0, 2}, {0, 3}, {1, 2}, {1, 2}, {2, 3}, {2, 3}, then vertices 0, 1, 3 each have degree three, and 2 has degree five, so there are four vertices of odd degree and thus by eulerpath 28030 the graph cannot have an Eulerian path. It is sufficient to show that there are 3 vertices of odd degree, since a graph having an Eulerian path can only have 0 or 2 vertices of odd degree. This is Metamath 100 proof #54. (Contributed by Mario Carneiro, 11-Mar-2015.) (Revised by Mario Carneiro, 28-Feb-2016.) (Revised by AV, 9-Mar-2021.)
Hypotheses
Ref Expression
konigsberg.v 𝑉 = (0...3)
konigsberg.e 𝐸 = ⟨“{0, 1} {0, 2} {0, 3} {1, 2} {1, 2} {2, 3} {2, 3}”⟩
konigsberg.g 𝐺 = ⟨𝑉, 𝐸
Assertion
Ref Expression
konigsberg (EulerPaths‘𝐺) = ∅

Proof of Theorem konigsberg
Dummy variable 𝑥 is distinct from all other variables.
StepHypRef Expression
1 konigsberg.v . . . 4 𝑉 = (0...3)
2 konigsberg.e . . . 4 𝐸 = ⟨“{0, 1} {0, 2} {0, 3} {1, 2} {1, 2} {2, 3} {2, 3}”⟩
3 konigsberg.g . . . 4 𝐺 = ⟨𝑉, 𝐸
41, 2, 3konigsberglem5 28045 . . 3 2 < (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)})
5 elpri 4550 . . . 4 ((♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) ∈ {0, 2} → ((♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) = 0 ∨ (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) = 2))
6 2pos 11732 . . . . . . 7 0 < 2
7 0re 10636 . . . . . . . 8 0 ∈ ℝ
8 2re 11703 . . . . . . . 8 2 ∈ ℝ
97, 8ltnsymi 10752 . . . . . . 7 (0 < 2 → ¬ 2 < 0)
106, 9ax-mp 5 . . . . . 6 ¬ 2 < 0
11 breq2 5037 . . . . . 6 ((♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) = 0 → (2 < (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) ↔ 2 < 0))
1210, 11mtbiri 330 . . . . 5 ((♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) = 0 → ¬ 2 < (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}))
138ltnri 10742 . . . . . 6 ¬ 2 < 2
14 breq2 5037 . . . . . 6 ((♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) = 2 → (2 < (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) ↔ 2 < 2))
1513, 14mtbiri 330 . . . . 5 ((♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) = 2 → ¬ 2 < (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}))
1612, 15jaoi 854 . . . 4 (((♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) = 0 ∨ (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) = 2) → ¬ 2 < (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}))
175, 16syl 17 . . 3 ((♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) ∈ {0, 2} → ¬ 2 < (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}))
184, 17mt2 203 . 2 ¬ (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) ∈ {0, 2}
191, 2, 3konigsbergumgr 28040 . . . . 5 𝐺 ∈ UMGraph
20 umgrupgr 26900 . . . . 5 (𝐺 ∈ UMGraph → 𝐺 ∈ UPGraph)
2119, 20ax-mp 5 . . . 4 𝐺 ∈ UPGraph
223fveq2i 6652 . . . . . 6 (Vtx‘𝐺) = (Vtx‘⟨𝑉, 𝐸⟩)
231ovexi 7173 . . . . . . 7 𝑉 ∈ V
24 s7cli 14242 . . . . . . . 8 ⟨“{0, 1} {0, 2} {0, 3} {1, 2} {1, 2} {2, 3} {2, 3}”⟩ ∈ Word V
252, 24eqeltri 2889 . . . . . . 7 𝐸 ∈ Word V
26 opvtxfv 26801 . . . . . . 7 ((𝑉 ∈ V ∧ 𝐸 ∈ Word V) → (Vtx‘⟨𝑉, 𝐸⟩) = 𝑉)
2723, 25, 26mp2an 691 . . . . . 6 (Vtx‘⟨𝑉, 𝐸⟩) = 𝑉
2822, 27eqtr2i 2825 . . . . 5 𝑉 = (Vtx‘𝐺)
2928eulerpath 28030 . . . 4 ((𝐺 ∈ UPGraph ∧ (EulerPaths‘𝐺) ≠ ∅) → (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) ∈ {0, 2})
3021, 29mpan 689 . . 3 ((EulerPaths‘𝐺) ≠ ∅ → (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) ∈ {0, 2})
3130necon1bi 3018 . 2 (¬ (♯‘{𝑥𝑉 ∣ ¬ 2 ∥ ((VtxDeg‘𝐺)‘𝑥)}) ∈ {0, 2} → (EulerPaths‘𝐺) = ∅)
3218, 31ax-mp 5 1 (EulerPaths‘𝐺) = ∅
Colors of variables: wff setvar class
Syntax hints:  ¬ wn 3  wo 844   = wceq 1538  wcel 2112  wne 2990  {crab 3113  Vcvv 3444  c0 4246  {cpr 4530  cop 4534   class class class wbr 5033  cfv 6328  (class class class)co 7139  0cc0 10530  1c1 10531   < clt 10668  2c2 11684  3c3 11685  ...cfz 12889  chash 13690  Word cword 13861  ⟨“cs7 14203  cdvds 15603  Vtxcvtx 26793  UPGraphcupgr 26877  UMGraphcumgr 26878  VtxDegcvtxdg 27259  EulerPathsceupth 27986
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1797  ax-4 1811  ax-5 1911  ax-6 1970  ax-7 2015  ax-8 2114  ax-9 2122  ax-10 2143  ax-11 2159  ax-12 2176  ax-ext 2773  ax-rep 5157  ax-sep 5170  ax-nul 5177  ax-pow 5234  ax-pr 5298  ax-un 7445  ax-cnex 10586  ax-resscn 10587  ax-1cn 10588  ax-icn 10589  ax-addcl 10590  ax-addrcl 10591  ax-mulcl 10592  ax-mulrcl 10593  ax-mulcom 10594  ax-addass 10595  ax-mulass 10596  ax-distr 10597  ax-i2m1 10598  ax-1ne0 10599  ax-1rid 10600  ax-rnegex 10601  ax-rrecex 10602  ax-cnre 10603  ax-pre-lttri 10604  ax-pre-lttrn 10605  ax-pre-ltadd 10606  ax-pre-mulgt0 10607  ax-pre-sup 10608
This theorem depends on definitions:  df-bi 210  df-an 400  df-or 845  df-ifp 1059  df-3or 1085  df-3an 1086  df-tru 1541  df-ex 1782  df-nf 1786  df-sb 2070  df-mo 2601  df-eu 2632  df-clab 2780  df-cleq 2794  df-clel 2873  df-nfc 2941  df-ne 2991  df-nel 3095  df-ral 3114  df-rex 3115  df-reu 3116  df-rmo 3117  df-rab 3118  df-v 3446  df-sbc 3724  df-csb 3832  df-dif 3887  df-un 3889  df-in 3891  df-ss 3901  df-pss 3903  df-nul 4247  df-if 4429  df-pw 4502  df-sn 4529  df-pr 4531  df-tp 4533  df-op 4535  df-uni 4804  df-int 4842  df-iun 4886  df-br 5034  df-opab 5096  df-mpt 5114  df-tr 5140  df-id 5428  df-eprel 5433  df-po 5442  df-so 5443  df-fr 5482  df-we 5484  df-xp 5529  df-rel 5530  df-cnv 5531  df-co 5532  df-dm 5533  df-rn 5534  df-res 5535  df-ima 5536  df-pred 6120  df-ord 6166  df-on 6167  df-lim 6168  df-suc 6169  df-iota 6287  df-fun 6330  df-fn 6331  df-f 6332  df-f1 6333  df-fo 6334  df-f1o 6335  df-fv 6336  df-riota 7097  df-ov 7142  df-oprab 7143  df-mpo 7144  df-om 7565  df-1st 7675  df-2nd 7676  df-wrecs 7934  df-recs 7995  df-rdg 8033  df-1o 8089  df-2o 8090  df-oadd 8093  df-er 8276  df-map 8395  df-pm 8396  df-en 8497  df-dom 8498  df-sdom 8499  df-fin 8500  df-sup 8894  df-inf 8895  df-dju 9318  df-card 9356  df-pnf 10670  df-mnf 10671  df-xr 10672  df-ltxr 10673  df-le 10674  df-sub 10865  df-neg 10866  df-div 11291  df-nn 11630  df-2 11692  df-3 11693  df-4 11694  df-n0 11890  df-xnn0 11960  df-z 11974  df-uz 12236  df-rp 12382  df-xadd 12500  df-fz 12890  df-fzo 13033  df-seq 13369  df-exp 13430  df-hash 13691  df-word 13862  df-concat 13918  df-s1 13945  df-s2 14205  df-s3 14206  df-s4 14207  df-s5 14208  df-s6 14209  df-s7 14210  df-cj 14454  df-re 14455  df-im 14456  df-sqrt 14590  df-abs 14591  df-dvds 15604  df-vtx 26795  df-iedg 26796  df-edg 26845  df-uhgr 26855  df-ushgr 26856  df-upgr 26879  df-umgr 26880  df-uspgr 26947  df-vtxdg 27260  df-wlks 27393  df-trls 27486  df-eupth 27987
This theorem is referenced by: (None)
  Copyright terms: Public domain W3C validator