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

Theorem nbupgr 27137
 Description: The set of neighbors of a vertex in a pseudograph. (Contributed by AV, 5-Nov-2020.) (Proof shortened by AV, 30-Dec-2020.)
Hypotheses
Ref Expression
nbuhgr.v 𝑉 = (Vtx‘𝐺)
nbuhgr.e 𝐸 = (Edg‘𝐺)
Assertion
Ref Expression
nbupgr ((𝐺 ∈ UPGraph ∧ 𝑁𝑉) → (𝐺 NeighbVtx 𝑁) = {𝑛 ∈ (𝑉 ∖ {𝑁}) ∣ {𝑁, 𝑛} ∈ 𝐸})
Distinct variable groups:   𝑛,𝐺   𝑛,𝑁   𝑛,𝑉   𝑛,𝐸

Proof of Theorem nbupgr
Dummy variable 𝑒 is distinct from all other variables.
StepHypRef Expression
1 nbuhgr.v . . . 4 𝑉 = (Vtx‘𝐺)
2 nbuhgr.e . . . 4 𝐸 = (Edg‘𝐺)
31, 2nbgrval 27129 . . 3 (𝑁𝑉 → (𝐺 NeighbVtx 𝑁) = {𝑛 ∈ (𝑉 ∖ {𝑁}) ∣ ∃𝑒𝐸 {𝑁, 𝑛} ⊆ 𝑒})
43adantl 485 . 2 ((𝐺 ∈ UPGraph ∧ 𝑁𝑉) → (𝐺 NeighbVtx 𝑁) = {𝑛 ∈ (𝑉 ∖ {𝑁}) ∣ ∃𝑒𝐸 {𝑁, 𝑛} ⊆ 𝑒})
5 simp-4l 782 . . . . . . . 8 (((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ 𝑒𝐸) ∧ {𝑁, 𝑛} ⊆ 𝑒) → 𝐺 ∈ UPGraph)
6 simpr 488 . . . . . . . . 9 ((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ 𝑒𝐸) → 𝑒𝐸)
76adantr 484 . . . . . . . 8 (((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ 𝑒𝐸) ∧ {𝑁, 𝑛} ⊆ 𝑒) → 𝑒𝐸)
8 simpr 488 . . . . . . . 8 (((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ 𝑒𝐸) ∧ {𝑁, 𝑛} ⊆ 𝑒) → {𝑁, 𝑛} ⊆ 𝑒)
9 simpr 488 . . . . . . . . . . . 12 ((𝐺 ∈ UPGraph ∧ 𝑁𝑉) → 𝑁𝑉)
109adantr 484 . . . . . . . . . . 11 (((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) → 𝑁𝑉)
11 vex 3447 . . . . . . . . . . . 12 𝑛 ∈ V
1211a1i 11 . . . . . . . . . . 11 (((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) → 𝑛 ∈ V)
13 eldifsn 4683 . . . . . . . . . . . . 13 (𝑛 ∈ (𝑉 ∖ {𝑁}) ↔ (𝑛𝑉𝑛𝑁))
14 simpr 488 . . . . . . . . . . . . . 14 ((𝑛𝑉𝑛𝑁) → 𝑛𝑁)
1514necomd 3045 . . . . . . . . . . . . 13 ((𝑛𝑉𝑛𝑁) → 𝑁𝑛)
1613, 15sylbi 220 . . . . . . . . . . . 12 (𝑛 ∈ (𝑉 ∖ {𝑁}) → 𝑁𝑛)
1716adantl 485 . . . . . . . . . . 11 (((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) → 𝑁𝑛)
1810, 12, 173jca 1125 . . . . . . . . . 10 (((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) → (𝑁𝑉𝑛 ∈ V ∧ 𝑁𝑛))
1918adantr 484 . . . . . . . . 9 ((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ 𝑒𝐸) → (𝑁𝑉𝑛 ∈ V ∧ 𝑁𝑛))
2019adantr 484 . . . . . . . 8 (((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ 𝑒𝐸) ∧ {𝑁, 𝑛} ⊆ 𝑒) → (𝑁𝑉𝑛 ∈ V ∧ 𝑁𝑛))
211, 2upgredgpr 26938 . . . . . . . 8 (((𝐺 ∈ UPGraph ∧ 𝑒𝐸 ∧ {𝑁, 𝑛} ⊆ 𝑒) ∧ (𝑁𝑉𝑛 ∈ V ∧ 𝑁𝑛)) → {𝑁, 𝑛} = 𝑒)
225, 7, 8, 20, 21syl31anc 1370 . . . . . . 7 (((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ 𝑒𝐸) ∧ {𝑁, 𝑛} ⊆ 𝑒) → {𝑁, 𝑛} = 𝑒)
2322ex 416 . . . . . 6 ((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ 𝑒𝐸) → ({𝑁, 𝑛} ⊆ 𝑒 → {𝑁, 𝑛} = 𝑒))
24 eleq1 2880 . . . . . . 7 ({𝑁, 𝑛} = 𝑒 → ({𝑁, 𝑛} ∈ 𝐸𝑒𝐸))
2524biimprd 251 . . . . . 6 ({𝑁, 𝑛} = 𝑒 → (𝑒𝐸 → {𝑁, 𝑛} ∈ 𝐸))
2623, 6, 25syl6ci 71 . . . . 5 ((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ 𝑒𝐸) → ({𝑁, 𝑛} ⊆ 𝑒 → {𝑁, 𝑛} ∈ 𝐸))
2726rexlimdva 3246 . . . 4 (((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) → (∃𝑒𝐸 {𝑁, 𝑛} ⊆ 𝑒 → {𝑁, 𝑛} ∈ 𝐸))
28 simpr 488 . . . . . 6 ((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ {𝑁, 𝑛} ∈ 𝐸) → {𝑁, 𝑛} ∈ 𝐸)
29 sseq2 3944 . . . . . . 7 (𝑒 = {𝑁, 𝑛} → ({𝑁, 𝑛} ⊆ 𝑒 ↔ {𝑁, 𝑛} ⊆ {𝑁, 𝑛}))
3029adantl 485 . . . . . 6 (((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ {𝑁, 𝑛} ∈ 𝐸) ∧ 𝑒 = {𝑁, 𝑛}) → ({𝑁, 𝑛} ⊆ 𝑒 ↔ {𝑁, 𝑛} ⊆ {𝑁, 𝑛}))
31 ssidd 3941 . . . . . 6 ((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ {𝑁, 𝑛} ∈ 𝐸) → {𝑁, 𝑛} ⊆ {𝑁, 𝑛})
3228, 30, 31rspcedvd 3577 . . . . 5 ((((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) ∧ {𝑁, 𝑛} ∈ 𝐸) → ∃𝑒𝐸 {𝑁, 𝑛} ⊆ 𝑒)
3332ex 416 . . . 4 (((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) → ({𝑁, 𝑛} ∈ 𝐸 → ∃𝑒𝐸 {𝑁, 𝑛} ⊆ 𝑒))
3427, 33impbid 215 . . 3 (((𝐺 ∈ UPGraph ∧ 𝑁𝑉) ∧ 𝑛 ∈ (𝑉 ∖ {𝑁})) → (∃𝑒𝐸 {𝑁, 𝑛} ⊆ 𝑒 ↔ {𝑁, 𝑛} ∈ 𝐸))
3534rabbidva 3428 . 2 ((𝐺 ∈ UPGraph ∧ 𝑁𝑉) → {𝑛 ∈ (𝑉 ∖ {𝑁}) ∣ ∃𝑒𝐸 {𝑁, 𝑛} ⊆ 𝑒} = {𝑛 ∈ (𝑉 ∖ {𝑁}) ∣ {𝑁, 𝑛} ∈ 𝐸})
364, 35eqtrd 2836 1 ((𝐺 ∈ UPGraph ∧ 𝑁𝑉) → (𝐺 NeighbVtx 𝑁) = {𝑛 ∈ (𝑉 ∖ {𝑁}) ∣ {𝑁, 𝑛} ∈ 𝐸})
 Colors of variables: wff setvar class Syntax hints:   → wi 4   ↔ wb 209   ∧ wa 399   ∧ w3a 1084   = wceq 1538   ∈ wcel 2112   ≠ wne 2990  ∃wrex 3110  {crab 3113  Vcvv 3444   ∖ cdif 3881   ⊆ wss 3884  {csn 4528  {cpr 4530  ‘cfv 6328  (class class class)co 7139  Vtxcvtx 26792  Edgcedg 26843  UPGraphcupgr 26876   NeighbVtx cnbgr 27125 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-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 This theorem depends on definitions:  df-bi 210  df-an 400  df-or 845  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-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-en 8497  df-dom 8498  df-sdom 8499  df-fin 8500  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-nn 11630  df-2 11692  df-n0 11890  df-xnn0 11960  df-z 11974  df-uz 12236  df-fz 12890  df-hash 13691  df-edg 26844  df-upgr 26878  df-nbgr 27126 This theorem is referenced by:  nbupgrel  27138  1loopgrnb0  27295
 Copyright terms: Public domain W3C validator