MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  nb3grapr2 Structured version   Unicode version

Theorem nb3grapr2 25174
Description: The neighbors of a vertex in a graph with three elements are an unordered pair of the other vertices if and only if all vertices are connected with each other. (Contributed by Alexander van der Vekens, 18-Oct-2017.)
Assertion
Ref Expression
nb3grapr2  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E )  /\  ( A  =/=  B  /\  A  =/=  C  /\  B  =/= 
C ) )  -> 
( ( { A ,  B }  e.  ran  E  /\  { B ,  C }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( ( <. V ,  E >. Neighbors  A
)  =  { B ,  C }  /\  ( <. V ,  E >. Neighbors  B
)  =  { A ,  C }  /\  ( <. V ,  E >. Neighbors  C
)  =  { A ,  B } ) ) )

Proof of Theorem nb3grapr2
StepHypRef Expression
1 3anan32 995 . . . . 5  |-  ( ( { A ,  B }  e.  ran  E  /\  { B ,  C }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  { B ,  C }  e.  ran  E ) )
21a1i 11 . . . 4  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E )  /\  ( A  =/=  B  /\  A  =/=  C  /\  B  =/= 
C ) )  -> 
( ( { A ,  B }  e.  ran  E  /\  { B ,  C }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  { B ,  C }  e.  ran  E ) ) )
3 prcom 4076 . . . . . . . . . . 11  |-  { C ,  A }  =  { A ,  C }
43eleq1i 2500 . . . . . . . . . 10  |-  ( { C ,  A }  e.  ran  E  <->  { A ,  C }  e.  ran  E )
54biimpi 198 . . . . . . . . 9  |-  ( { C ,  A }  e.  ran  E  ->  { A ,  C }  e.  ran  E )
65pm4.71i 637 . . . . . . . 8  |-  ( { C ,  A }  e.  ran  E  <->  ( { C ,  A }  e.  ran  E  /\  { A ,  C }  e.  ran  E ) )
76anbi2i 699 . . . . . . 7  |-  ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( { A ,  B }  e.  ran  E  /\  ( { C ,  A }  e.  ran  E  /\  { A ,  C }  e.  ran  E ) ) )
8 anass 654 . . . . . . 7  |-  ( ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  { A ,  C }  e.  ran  E )  <->  ( { A ,  B }  e.  ran  E  /\  ( { C ,  A }  e.  ran  E  /\  { A ,  C }  e.  ran  E ) ) )
97, 8bitr4i 256 . . . . . 6  |-  ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  { A ,  C }  e.  ran  E ) )
109anbi1i 700 . . . . 5  |-  ( ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  { B ,  C }  e.  ran  E )  <->  ( ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  { A ,  C }  e.  ran  E )  /\  { B ,  C }  e.  ran  E ) )
11 anass 654 . . . . 5  |-  ( ( ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  { A ,  C }  e.  ran  E )  /\  { B ,  C }  e.  ran  E )  <->  ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E ) ) )
1210, 11bitri 253 . . . 4  |-  ( ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  { B ,  C }  e.  ran  E )  <->  ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E ) ) )
132, 12syl6bb 265 . . 3  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E )  /\  ( A  =/=  B  /\  A  =/=  C  /\  B  =/= 
C ) )  -> 
( ( { A ,  B }  e.  ran  E  /\  { B ,  C }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E ) ) ) )
14 prcom 4076 . . . . . . . . . 10  |-  { A ,  B }  =  { B ,  A }
1514eleq1i 2500 . . . . . . . . 9  |-  ( { A ,  B }  e.  ran  E  <->  { B ,  A }  e.  ran  E )
1615biimpi 198 . . . . . . . 8  |-  ( { A ,  B }  e.  ran  E  ->  { B ,  A }  e.  ran  E )
1716pm4.71i 637 . . . . . . 7  |-  ( { A ,  B }  e.  ran  E  <->  ( { A ,  B }  e.  ran  E  /\  { B ,  A }  e.  ran  E ) )
1817anbi1i 700 . . . . . 6  |-  ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( ( { A ,  B }  e.  ran  E  /\  { B ,  A }  e.  ran  E )  /\  { C ,  A }  e.  ran  E ) )
19 df-3an 985 . . . . . 6  |-  ( ( { A ,  B }  e.  ran  E  /\  { B ,  A }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( ( { A ,  B }  e.  ran  E  /\  { B ,  A }  e.  ran  E )  /\  { C ,  A }  e.  ran  E ) )
2018, 19bitr4i 256 . . . . 5  |-  ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( { A ,  B }  e.  ran  E  /\  { B ,  A }  e.  ran  E  /\  { C ,  A }  e.  ran  E ) )
21 prcom 4076 . . . . . . . . . 10  |-  { B ,  C }  =  { C ,  B }
2221eleq1i 2500 . . . . . . . . 9  |-  ( { B ,  C }  e.  ran  E  <->  { C ,  B }  e.  ran  E )
2322biimpi 198 . . . . . . . 8  |-  ( { B ,  C }  e.  ran  E  ->  { C ,  B }  e.  ran  E )
2423pm4.71i 637 . . . . . . 7  |-  ( { B ,  C }  e.  ran  E  <->  ( { B ,  C }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) )
2524anbi2i 699 . . . . . 6  |-  ( ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E )  <->  ( { A ,  C }  e.  ran  E  /\  ( { B ,  C }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) ) )
26 3anass 987 . . . . . 6  |-  ( ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E  /\  { C ,  B }  e.  ran  E )  <->  ( { A ,  C }  e.  ran  E  /\  ( { B ,  C }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) ) )
2725, 26bitr4i 256 . . . . 5  |-  ( ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E )  <->  ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) )
2820, 27anbi12i 702 . . . 4  |-  ( ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E ) )  <-> 
( ( { A ,  B }  e.  ran  E  /\  { B ,  A }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) ) )
29 an6 1345 . . . 4  |-  ( ( ( { A ,  B }  e.  ran  E  /\  { B ,  A }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) )  <-> 
( ( { A ,  B }  e.  ran  E  /\  { A ,  C }  e.  ran  E )  /\  ( { B ,  A }  e.  ran  E  /\  { B ,  C }  e.  ran  E )  /\  ( { C ,  A }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) ) )
3028, 29bitri 253 . . 3  |-  ( ( ( { A ,  B }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  /\  ( { A ,  C }  e.  ran  E  /\  { B ,  C }  e.  ran  E ) )  <-> 
( ( { A ,  B }  e.  ran  E  /\  { A ,  C }  e.  ran  E )  /\  ( { B ,  A }  e.  ran  E  /\  { B ,  C }  e.  ran  E )  /\  ( { C ,  A }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) ) )
3113, 30syl6bb 265 . 2  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E )  /\  ( A  =/=  B  /\  A  =/=  C  /\  B  =/= 
C ) )  -> 
( ( { A ,  B }  e.  ran  E  /\  { B ,  C }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( ( { A ,  B }  e.  ran  E  /\  { A ,  C }  e.  ran  E )  /\  ( { B ,  A }  e.  ran  E  /\  { B ,  C }  e.  ran  E )  /\  ( { C ,  A }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) ) ) )
32 nb3graprlem1 25171 . . . . 5  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E ) )  ->  (
( <. V ,  E >. Neighbors  A )  =  { B ,  C }  <->  ( { A ,  B }  e.  ran  E  /\  { A ,  C }  e.  ran  E ) ) )
3332bicomd 205 . . . 4  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E ) )  ->  (
( { A ,  B }  e.  ran  E  /\  { A ,  C }  e.  ran  E )  <->  ( <. V ,  E >. Neighbors  A )  =  { B ,  C }
) )
34 3ancoma 990 . . . . . . 7  |-  ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z )  <->  ( B  e.  Y  /\  A  e.  X  /\  C  e.  Z )
)
3534biimpi 198 . . . . . 6  |-  ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z )  ->  ( B  e.  Y  /\  A  e.  X  /\  C  e.  Z
) )
36 tpcoma 4094 . . . . . . . . 9  |-  { A ,  B ,  C }  =  { B ,  A ,  C }
3736eqeq2i 2441 . . . . . . . 8  |-  ( V  =  { A ,  B ,  C }  <->  V  =  { B ,  A ,  C }
)
3837biimpi 198 . . . . . . 7  |-  ( V  =  { A ,  B ,  C }  ->  V  =  { B ,  A ,  C }
)
3938anim1i 571 . . . . . 6  |-  ( ( V  =  { A ,  B ,  C }  /\  V USGrph  E )  -> 
( V  =  { B ,  A ,  C }  /\  V USGrph  E
) )
40 nb3graprlem1 25171 . . . . . 6  |-  ( ( ( B  e.  Y  /\  A  e.  X  /\  C  e.  Z
)  /\  ( V  =  { B ,  A ,  C }  /\  V USGrph  E ) )  ->  (
( <. V ,  E >. Neighbors  B )  =  { A ,  C }  <->  ( { B ,  A }  e.  ran  E  /\  { B ,  C }  e.  ran  E ) ) )
4135, 39, 40syl2an 480 . . . . 5  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E ) )  ->  (
( <. V ,  E >. Neighbors  B )  =  { A ,  C }  <->  ( { B ,  A }  e.  ran  E  /\  { B ,  C }  e.  ran  E ) ) )
4241bicomd 205 . . . 4  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E ) )  ->  (
( { B ,  A }  e.  ran  E  /\  { B ,  C }  e.  ran  E )  <->  ( <. V ,  E >. Neighbors  B )  =  { A ,  C }
) )
43 3anrot 988 . . . . . . 7  |-  ( ( C  e.  Z  /\  A  e.  X  /\  B  e.  Y )  <->  ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z )
)
4443biimpri 210 . . . . . 6  |-  ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z )  ->  ( C  e.  Z  /\  A  e.  X  /\  B  e.  Y
) )
45 tprot 4093 . . . . . . . . . 10  |-  { C ,  A ,  B }  =  { A ,  B ,  C }
4645eqcomi 2436 . . . . . . . . 9  |-  { A ,  B ,  C }  =  { C ,  A ,  B }
4746eqeq2i 2441 . . . . . . . 8  |-  ( V  =  { A ,  B ,  C }  <->  V  =  { C ,  A ,  B }
)
4847biimpi 198 . . . . . . 7  |-  ( V  =  { A ,  B ,  C }  ->  V  =  { C ,  A ,  B }
)
4948anim1i 571 . . . . . 6  |-  ( ( V  =  { A ,  B ,  C }  /\  V USGrph  E )  -> 
( V  =  { C ,  A ,  B }  /\  V USGrph  E
) )
50 nb3graprlem1 25171 . . . . . 6  |-  ( ( ( C  e.  Z  /\  A  e.  X  /\  B  e.  Y
)  /\  ( V  =  { C ,  A ,  B }  /\  V USGrph  E ) )  ->  (
( <. V ,  E >. Neighbors  C )  =  { A ,  B }  <->  ( { C ,  A }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) ) )
5144, 49, 50syl2an 480 . . . . 5  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E ) )  ->  (
( <. V ,  E >. Neighbors  C )  =  { A ,  B }  <->  ( { C ,  A }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) ) )
5251bicomd 205 . . . 4  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E ) )  ->  (
( { C ,  A }  e.  ran  E  /\  { C ,  B }  e.  ran  E )  <->  ( <. V ,  E >. Neighbors  C )  =  { A ,  B }
) )
5333, 42, 523anbi123d 1336 . . 3  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E ) )  ->  (
( ( { A ,  B }  e.  ran  E  /\  { A ,  C }  e.  ran  E )  /\  ( { B ,  A }  e.  ran  E  /\  { B ,  C }  e.  ran  E )  /\  ( { C ,  A }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) )  <-> 
( ( <. V ,  E >. Neighbors  A )  =  { B ,  C }  /\  ( <. V ,  E >. Neighbors  B )  =  { A ,  C }  /\  ( <. V ,  E >. Neighbors  C )  =  { A ,  B }
) ) )
54533adant3 1026 . 2  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E )  /\  ( A  =/=  B  /\  A  =/=  C  /\  B  =/= 
C ) )  -> 
( ( ( { A ,  B }  e.  ran  E  /\  { A ,  C }  e.  ran  E )  /\  ( { B ,  A }  e.  ran  E  /\  { B ,  C }  e.  ran  E )  /\  ( { C ,  A }  e.  ran  E  /\  { C ,  B }  e.  ran  E ) )  <-> 
( ( <. V ,  E >. Neighbors  A )  =  { B ,  C }  /\  ( <. V ,  E >. Neighbors  B )  =  { A ,  C }  /\  ( <. V ,  E >. Neighbors  C )  =  { A ,  B }
) ) )
5531, 54bitrd 257 1  |-  ( ( ( A  e.  X  /\  B  e.  Y  /\  C  e.  Z
)  /\  ( V  =  { A ,  B ,  C }  /\  V USGrph  E )  /\  ( A  =/=  B  /\  A  =/=  C  /\  B  =/= 
C ) )  -> 
( ( { A ,  B }  e.  ran  E  /\  { B ,  C }  e.  ran  E  /\  { C ,  A }  e.  ran  E )  <->  ( ( <. V ,  E >. Neighbors  A
)  =  { B ,  C }  /\  ( <. V ,  E >. Neighbors  B
)  =  { A ,  C }  /\  ( <. V ,  E >. Neighbors  C
)  =  { A ,  B } ) ) )
Colors of variables: wff setvar class
Syntax hints:    -> wi 4    <-> wb 188    /\ wa 371    /\ w3a 983    = wceq 1438    e. wcel 1869    =/= wne 2619   {cpr 3999   {ctp 4001   <.cop 4003   class class class wbr 4421   ran crn 4852  (class class class)co 6303   USGrph cusg 25049   Neighbors cnbgra 25137
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1666  ax-4 1679  ax-5 1749  ax-6 1795  ax-7 1840  ax-8 1871  ax-9 1873  ax-10 1888  ax-11 1893  ax-12 1906  ax-13 2054  ax-ext 2401  ax-rep 4534  ax-sep 4544  ax-nul 4553  ax-pow 4600  ax-pr 4658  ax-un 6595  ax-cnex 9597  ax-resscn 9598  ax-1cn 9599  ax-icn 9600  ax-addcl 9601  ax-addrcl 9602  ax-mulcl 9603  ax-mulrcl 9604  ax-mulcom 9605  ax-addass 9606  ax-mulass 9607  ax-distr 9608  ax-i2m1 9609  ax-1ne0 9610  ax-1rid 9611  ax-rnegex 9612  ax-rrecex 9613  ax-cnre 9614  ax-pre-lttri 9615  ax-pre-lttrn 9616  ax-pre-ltadd 9617  ax-pre-mulgt0 9618
This theorem depends on definitions:  df-bi 189  df-or 372  df-an 373  df-3or 984  df-3an 985  df-tru 1441  df-ex 1661  df-nf 1665  df-sb 1788  df-eu 2270  df-mo 2271  df-clab 2409  df-cleq 2415  df-clel 2418  df-nfc 2573  df-ne 2621  df-nel 2622  df-ral 2781  df-rex 2782  df-reu 2783  df-rmo 2784  df-rab 2785  df-v 3084  df-sbc 3301  df-csb 3397  df-dif 3440  df-un 3442  df-in 3444  df-ss 3451  df-pss 3453  df-nul 3763  df-if 3911  df-pw 3982  df-sn 3998  df-pr 4000  df-tp 4002  df-op 4004  df-uni 4218  df-int 4254  df-iun 4299  df-br 4422  df-opab 4481  df-mpt 4482  df-tr 4517  df-eprel 4762  df-id 4766  df-po 4772  df-so 4773  df-fr 4810  df-we 4812  df-xp 4857  df-rel 4858  df-cnv 4859  df-co 4860  df-dm 4861  df-rn 4862  df-res 4863  df-ima 4864  df-pred 5397  df-ord 5443  df-on 5444  df-lim 5445  df-suc 5446  df-iota 5563  df-fun 5601  df-fn 5602  df-f 5603  df-f1 5604  df-fo 5605  df-f1o 5606  df-fv 5607  df-riota 6265  df-ov 6306  df-oprab 6307  df-mpt2 6308  df-om 6705  df-1st 6805  df-2nd 6806  df-wrecs 7034  df-recs 7096  df-rdg 7134  df-1o 7188  df-oadd 7192  df-er 7369  df-en 7576  df-dom 7577  df-sdom 7578  df-fin 7579  df-card 8376  df-cda 8600  df-pnf 9679  df-mnf 9680  df-xr 9681  df-ltxr 9682  df-le 9683  df-sub 9864  df-neg 9865  df-nn 10612  df-2 10670  df-n0 10872  df-z 10940  df-uz 11162  df-fz 11787  df-hash 12517  df-usgra 25052  df-nbgra 25140
This theorem is referenced by: (None)
  Copyright terms: Public domain W3C validator