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

Theorem frghash2spot 24855
Description: The number of simple paths of length 2 is n*(n-1) in a friendship graph with  n vertices. This corresponds to the proof of the third claim in the proof of the friendship theorem in [Huneke] p. 2: "... the paths of length two in G: by assumption there are ( n 2 ) such paths.". However, the order of vertices is not respected by Huneke, so he only counts half of the paths which are existing when respecting the order as it is the case for simple paths represented by orderes triples. (Contributed by Alexander van der Vekens, 6-Mar-2018.)
Assertion
Ref Expression
frghash2spot  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  -> 
( # `  ( V 2SPathOnOt  E ) )  =  ( ( # `  V
)  x.  ( (
# `  V )  -  1 ) ) )

Proof of Theorem frghash2spot
Dummy variables  a 
b are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 frisusgra 24783 . . . . 5  |-  ( V FriendGrph  E  ->  V USGrph  E )
2 usgrav 24129 . . . . 5  |-  ( V USGrph  E  ->  ( V  e. 
_V  /\  E  e.  _V ) )
3 2spot2iun2spont 24682 . . . . 5  |-  ( ( V  e.  _V  /\  E  e.  _V )  ->  ( V 2SPathOnOt  E )  =  U_ a  e.  V  U_ b  e.  ( V 
\  { a } ) ( a ( V 2SPathOnOt  E ) b ) )
41, 2, 33syl 20 . . . 4  |-  ( V FriendGrph  E  ->  ( V 2SPathOnOt  E )  =  U_ a  e.  V  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) )
54fveq2d 5875 . . 3  |-  ( V FriendGrph  E  ->  ( # `  ( V 2SPathOnOt  E ) )  =  ( # `  U_ a  e.  V  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) ) )
65adantr 465 . 2  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  -> 
( # `  ( V 2SPathOnOt  E ) )  =  ( # `  U_ a  e.  V  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) ) )
7 simpl 457 . . . 4  |-  ( ( V  e.  Fin  /\  V  =/=  (/) )  ->  V  e.  Fin )
87adantl 466 . . 3  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  ->  V  e.  Fin )
9 diffi 7761 . . . . . . 7  |-  ( V  e.  Fin  ->  ( V  \  { a } )  e.  Fin )
109adantr 465 . . . . . 6  |-  ( ( V  e.  Fin  /\  V  =/=  (/) )  ->  ( V  \  { a } )  e.  Fin )
1110adantl 466 . . . . 5  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  -> 
( V  \  {
a } )  e. 
Fin )
1211adantr 465 . . . 4  |-  ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  ->  ( V  \  { a } )  e.  Fin )
13 simpr 461 . . . . . . . . . 10  |-  ( ( V  e.  _V  /\  E  e.  _V )  ->  E  e.  _V )
141, 2, 133syl 20 . . . . . . . . 9  |-  ( V FriendGrph  E  ->  E  e.  _V )
1514, 7anim12ci 567 . . . . . . . 8  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  -> 
( V  e.  Fin  /\  E  e.  _V )
)
1615adantr 465 . . . . . . 7  |-  ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  ->  ( V  e.  Fin  /\  E  e. 
_V ) )
1716adantr 465 . . . . . 6  |-  ( ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  /\  b  e.  ( V  \  { a } ) )  -> 
( V  e.  Fin  /\  E  e.  _V )
)
18 simpr 461 . . . . . . 7  |-  ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  ->  a  e.  V )
19 eldifi 3631 . . . . . . 7  |-  ( b  e.  ( V  \  { a } )  ->  b  e.  V
)
2018, 19anim12i 566 . . . . . 6  |-  ( ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  /\  b  e.  ( V  \  { a } ) )  -> 
( a  e.  V  /\  b  e.  V
) )
21 2spotfi 24683 . . . . . 6  |-  ( ( ( V  e.  Fin  /\  E  e.  _V )  /\  ( a  e.  V  /\  b  e.  V
) )  ->  (
a ( V 2SPathOnOt  E ) b )  e.  Fin )
2217, 20, 21syl2anc 661 . . . . 5  |-  ( ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  /\  b  e.  ( V  \  { a } ) )  -> 
( a ( V 2SPathOnOt  E ) b )  e.  Fin )
2322ralrimiva 2881 . . . 4  |-  ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  ->  A. b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b )  e.  Fin )
24 iunfi 7818 . . . 4  |-  ( ( ( V  \  {
a } )  e. 
Fin  /\  A. b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b )  e.  Fin )  ->  U_ b  e.  ( V  \  { a } ) ( a ( V 2SPathOnOt  E )
b )  e.  Fin )
2512, 23, 24syl2anc 661 . . 3  |-  ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  ->  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b )  e.  Fin )
26 2spotiundisj 24854 . . . . 5  |-  ( ( V  e.  _V  /\  E  e.  _V )  -> Disj  a  e.  V  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) )
271, 2, 263syl 20 . . . 4  |-  ( V FriendGrph  E  -> Disj  a  e.  V  U_ b  e.  ( V  \  { a } ) ( a ( V 2SPathOnOt  E ) b ) )
2827adantr 465 . . 3  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  -> Disj  a  e.  V  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) )
298, 25, 28hashiun 13611 . 2  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  -> 
( # `  U_ a  e.  V  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) )  = 
sum_ a  e.  V  ( # `  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) ) )
30 2spotdisj 24853 . . . . . . 7  |-  ( ( ( V  e.  Fin  /\  E  e.  _V )  /\  a  e.  V
)  -> Disj  b  e.  ( V  \  { a } ) ( a ( V 2SPathOnOt  E )
b ) )
3115, 30sylan 471 . . . . . 6  |-  ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  -> Disj  b  e.  ( V  \  { a } ) ( a ( V 2SPathOnOt  E )
b ) )
3212, 22, 31hashiun 13611 . . . . 5  |-  ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  ->  ( # `  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) )  = 
sum_ b  e.  ( V  \  { a } ) ( # `  ( a ( V 2SPathOnOt  E ) b ) ) )
33 simplll 757 . . . . . . 7  |-  ( ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  /\  b  e.  ( V  \  { a } ) )  ->  V FriendGrph  E )
34 eldifsni 4158 . . . . . . . . 9  |-  ( b  e.  ( V  \  { a } )  ->  b  =/=  a
)
3534necomd 2738 . . . . . . . 8  |-  ( b  e.  ( V  \  { a } )  ->  a  =/=  b
)
3635adantl 466 . . . . . . 7  |-  ( ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  /\  b  e.  ( V  \  { a } ) )  -> 
a  =/=  b )
37 frg2spot1 24850 . . . . . . 7  |-  ( ( V FriendGrph  E  /\  (
a  e.  V  /\  b  e.  V )  /\  a  =/=  b
)  ->  ( # `  (
a ( V 2SPathOnOt  E ) b ) )  =  1 )
3833, 20, 36, 37syl3anc 1228 . . . . . 6  |-  ( ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  /\  b  e.  ( V  \  { a } ) )  -> 
( # `  ( a ( V 2SPathOnOt  E )
b ) )  =  1 )
3938sumeq2dv 13500 . . . . 5  |-  ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  ->  sum_ b  e.  ( V  \  {
a } ) (
# `  ( a
( V 2SPathOnOt  E ) b ) )  =  sum_ b  e.  ( V  \  { a } ) 1 )
40 ax-1cn 9560 . . . . . . . . . . 11  |-  1  e.  CC
419, 40jctir 538 . . . . . . . . . 10  |-  ( V  e.  Fin  ->  (
( V  \  {
a } )  e. 
Fin  /\  1  e.  CC ) )
4241adantr 465 . . . . . . . . 9  |-  ( ( V  e.  Fin  /\  V  =/=  (/) )  ->  (
( V  \  {
a } )  e. 
Fin  /\  1  e.  CC ) )
4342adantr 465 . . . . . . . 8  |-  ( ( ( V  e.  Fin  /\  V  =/=  (/) )  /\  a  e.  V )  ->  ( ( V  \  { a } )  e.  Fin  /\  1  e.  CC ) )
44 fsumconst 13580 . . . . . . . 8  |-  ( ( ( V  \  {
a } )  e. 
Fin  /\  1  e.  CC )  ->  sum_ b  e.  ( V  \  {
a } ) 1  =  ( ( # `  ( V  \  {
a } ) )  x.  1 ) )
4543, 44syl 16 . . . . . . 7  |-  ( ( ( V  e.  Fin  /\  V  =/=  (/) )  /\  a  e.  V )  -> 
sum_ b  e.  ( V  \  { a } ) 1  =  ( ( # `  ( V  \  { a } ) )  x.  1 ) )
46 hashdifsn 12452 . . . . . . . . 9  |-  ( ( V  e.  Fin  /\  a  e.  V )  ->  ( # `  ( V  \  { a } ) )  =  ( ( # `  V
)  -  1 ) )
4746adantlr 714 . . . . . . . 8  |-  ( ( ( V  e.  Fin  /\  V  =/=  (/) )  /\  a  e.  V )  ->  ( # `  ( V  \  { a } ) )  =  ( ( # `  V
)  -  1 ) )
4847oveq1d 6309 . . . . . . 7  |-  ( ( ( V  e.  Fin  /\  V  =/=  (/) )  /\  a  e.  V )  ->  ( ( # `  ( V  \  { a } ) )  x.  1 )  =  ( ( ( # `  V
)  -  1 )  x.  1 ) )
49 hashnncl 12414 . . . . . . . . . . . 12  |-  ( V  e.  Fin  ->  (
( # `  V )  e.  NN  <->  V  =/=  (/) ) )
5049biimpar 485 . . . . . . . . . . 11  |-  ( ( V  e.  Fin  /\  V  =/=  (/) )  ->  ( # `
 V )  e.  NN )
51 nnm1nn0 10847 . . . . . . . . . . 11  |-  ( (
# `  V )  e.  NN  ->  ( ( # `
 V )  - 
1 )  e.  NN0 )
5250, 51syl 16 . . . . . . . . . 10  |-  ( ( V  e.  Fin  /\  V  =/=  (/) )  ->  (
( # `  V )  -  1 )  e. 
NN0 )
5352nn0red 10863 . . . . . . . . 9  |-  ( ( V  e.  Fin  /\  V  =/=  (/) )  ->  (
( # `  V )  -  1 )  e.  RR )
54 ax-1rid 9572 . . . . . . . . 9  |-  ( ( ( # `  V
)  -  1 )  e.  RR  ->  (
( ( # `  V
)  -  1 )  x.  1 )  =  ( ( # `  V
)  -  1 ) )
5553, 54syl 16 . . . . . . . 8  |-  ( ( V  e.  Fin  /\  V  =/=  (/) )  ->  (
( ( # `  V
)  -  1 )  x.  1 )  =  ( ( # `  V
)  -  1 ) )
5655adantr 465 . . . . . . 7  |-  ( ( ( V  e.  Fin  /\  V  =/=  (/) )  /\  a  e.  V )  ->  ( ( ( # `  V )  -  1 )  x.  1 )  =  ( ( # `  V )  -  1 ) )
5745, 48, 563eqtrd 2512 . . . . . 6  |-  ( ( ( V  e.  Fin  /\  V  =/=  (/) )  /\  a  e.  V )  -> 
sum_ b  e.  ( V  \  { a } ) 1  =  ( ( # `  V
)  -  1 ) )
5857adantll 713 . . . . 5  |-  ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  ->  sum_ b  e.  ( V  \  {
a } ) 1  =  ( ( # `  V )  -  1 ) )
5932, 39, 583eqtrd 2512 . . . 4  |-  ( ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  /\  a  e.  V
)  ->  ( # `  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) )  =  ( ( # `  V
)  -  1 ) )
6059sumeq2dv 13500 . . 3  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  ->  sum_ a  e.  V  (
# `  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) )  = 
sum_ a  e.  V  ( ( # `  V
)  -  1 ) )
61 hashcl 12406 . . . . . . . 8  |-  ( V  e.  Fin  ->  ( # `
 V )  e. 
NN0 )
6261nn0cnd 10864 . . . . . . 7  |-  ( V  e.  Fin  ->  ( # `
 V )  e.  CC )
6340a1i 11 . . . . . . 7  |-  ( V  e.  Fin  ->  1  e.  CC )
6462, 63subcld 9940 . . . . . 6  |-  ( V  e.  Fin  ->  (
( # `  V )  -  1 )  e.  CC )
65 fsumconst 13580 . . . . . 6  |-  ( ( V  e.  Fin  /\  ( ( # `  V
)  -  1 )  e.  CC )  ->  sum_ a  e.  V  ( ( # `  V
)  -  1 )  =  ( ( # `  V )  x.  (
( # `  V )  -  1 ) ) )
6664, 65mpdan 668 . . . . 5  |-  ( V  e.  Fin  ->  sum_ a  e.  V  ( ( # `
 V )  - 
1 )  =  ( ( # `  V
)  x.  ( (
# `  V )  -  1 ) ) )
6766adantr 465 . . . 4  |-  ( ( V  e.  Fin  /\  V  =/=  (/) )  ->  sum_ a  e.  V  ( ( # `
 V )  - 
1 )  =  ( ( # `  V
)  x.  ( (
# `  V )  -  1 ) ) )
6867adantl 466 . . 3  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  ->  sum_ a  e.  V  ( ( # `  V
)  -  1 )  =  ( ( # `  V )  x.  (
( # `  V )  -  1 ) ) )
6960, 68eqtrd 2508 . 2  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  ->  sum_ a  e.  V  (
# `  U_ b  e.  ( V  \  {
a } ) ( a ( V 2SPathOnOt  E ) b ) )  =  ( ( # `  V
)  x.  ( (
# `  V )  -  1 ) ) )
706, 29, 693eqtrd 2512 1  |-  ( ( V FriendGrph  E  /\  ( V  e.  Fin  /\  V  =/=  (/) ) )  -> 
( # `  ( V 2SPathOnOt  E ) )  =  ( ( # `  V
)  x.  ( (
# `  V )  -  1 ) ) )
Colors of variables: wff setvar class
Syntax hints:    -> wi 4    /\ wa 369    = wceq 1379    e. wcel 1767    =/= wne 2662   A.wral 2817   _Vcvv 3118    \ cdif 3478   (/)c0 3790   {csn 4032   U_ciun 4330  Disj wdisj 4422   class class class wbr 4452   ` cfv 5593  (class class class)co 6294   Fincfn 7526   CCcc 9500   RRcr 9501   1c1 9503    x. cmul 9507    - cmin 9815   NNcn 10546   NN0cn0 10805   #chash 12383   sum_csu 13483   USGrph cusg 24121   2SPathOnOt c2spthot 24647   2SPathOnOt c2pthonot 24648   FriendGrph cfrgra 24779
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1601  ax-4 1612  ax-5 1680  ax-6 1719  ax-7 1739  ax-8 1769  ax-9 1771  ax-10 1786  ax-11 1791  ax-12 1803  ax-13 1968  ax-ext 2445  ax-rep 4563  ax-sep 4573  ax-nul 4581  ax-pow 4630  ax-pr 4691  ax-un 6586  ax-inf2 8068  ax-cnex 9558  ax-resscn 9559  ax-1cn 9560  ax-icn 9561  ax-addcl 9562  ax-addrcl 9563  ax-mulcl 9564  ax-mulrcl 9565  ax-mulcom 9566  ax-addass 9567  ax-mulass 9568  ax-distr 9569  ax-i2m1 9570  ax-1ne0 9571  ax-1rid 9572  ax-rnegex 9573  ax-rrecex 9574  ax-cnre 9575  ax-pre-lttri 9576  ax-pre-lttrn 9577  ax-pre-ltadd 9578  ax-pre-mulgt0 9579  ax-pre-sup 9580
This theorem depends on definitions:  df-bi 185  df-or 370  df-an 371  df-3or 974  df-3an 975  df-tru 1382  df-fal 1385  df-ex 1597  df-nf 1600  df-sb 1712  df-eu 2279  df-mo 2280  df-clab 2453  df-cleq 2459  df-clel 2462  df-nfc 2617  df-ne 2664  df-nel 2665  df-ral 2822  df-rex 2823  df-reu 2824  df-rmo 2825  df-rab 2826  df-v 3120  df-sbc 3337  df-csb 3441  df-dif 3484  df-un 3486  df-in 3488  df-ss 3495  df-pss 3497  df-nul 3791  df-if 3945  df-pw 4017  df-sn 4033  df-pr 4035  df-tp 4037  df-op 4039  df-ot 4041  df-uni 4251  df-int 4288  df-iun 4332  df-disj 4423  df-br 4453  df-opab 4511  df-mpt 4512  df-tr 4546  df-eprel 4796  df-id 4800  df-po 4805  df-so 4806  df-fr 4843  df-se 4844  df-we 4845  df-ord 4886  df-on 4887  df-lim 4888  df-suc 4889  df-xp 5010  df-rel 5011  df-cnv 5012  df-co 5013  df-dm 5014  df-rn 5015  df-res 5016  df-ima 5017  df-iota 5556  df-fun 5595  df-fn 5596  df-f 5597  df-f1 5598  df-fo 5599  df-f1o 5600  df-fv 5601  df-isom 5602  df-riota 6255  df-ov 6297  df-oprab 6298  df-mpt2 6299  df-om 6695  df-1st 6794  df-2nd 6795  df-recs 7052  df-rdg 7086  df-1o 7140  df-oadd 7144  df-er 7321  df-map 7432  df-pm 7433  df-en 7527  df-dom 7528  df-sdom 7529  df-fin 7530  df-sup 7911  df-oi 7945  df-card 8330  df-cda 8558  df-pnf 9640  df-mnf 9641  df-xr 9642  df-ltxr 9643  df-le 9644  df-sub 9817  df-neg 9818  df-div 10217  df-nn 10547  df-2 10604  df-3 10605  df-n0 10806  df-z 10875  df-uz 11093  df-rp 11231  df-fz 11683  df-fzo 11803  df-seq 12086  df-exp 12145  df-hash 12384  df-word 12518  df-cj 12907  df-re 12908  df-im 12909  df-sqrt 13043  df-abs 13044  df-clim 13286  df-sum 13484  df-usgra 24124  df-wlk 24299  df-trail 24300  df-pth 24301  df-spth 24302  df-wlkon 24305  df-spthon 24308  df-2wlkonot 24649  df-2spthonot 24651  df-2spthsot 24652  df-frgra 24780
This theorem is referenced by:  frgregordn0  24862
  Copyright terms: Public domain W3C validator