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

Theorem wwlksn 26723
Description: The set of walks (in an undirected graph) of a fixed length as words over the set of vertices. (Contributed by Alexander van der Vekens, 15-Jul-2018.) (Revised by AV, 8-Apr-2021.)
Assertion
Ref Expression
wwlksn (𝑁 ∈ ℕ0 → (𝑁 WWalksN 𝐺) = {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)})
Distinct variable groups:   𝑤,𝐺   𝑤,𝑁

Proof of Theorem wwlksn
Dummy variables 𝑔 𝑛 are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 df-wwlksn 26717 . . . . 5 WWalksN = (𝑛 ∈ ℕ0, 𝑔 ∈ V ↦ {𝑤 ∈ (WWalks‘𝑔) ∣ (#‘𝑤) = (𝑛 + 1)})
21a1i 11 . . . 4 ((𝑁 ∈ ℕ0𝐺 ∈ V) → WWalksN = (𝑛 ∈ ℕ0, 𝑔 ∈ V ↦ {𝑤 ∈ (WWalks‘𝑔) ∣ (#‘𝑤) = (𝑛 + 1)}))
3 fveq2 6189 . . . . . . 7 (𝑔 = 𝐺 → (WWalks‘𝑔) = (WWalks‘𝐺))
43adantl 482 . . . . . 6 ((𝑛 = 𝑁𝑔 = 𝐺) → (WWalks‘𝑔) = (WWalks‘𝐺))
5 oveq1 6654 . . . . . . . 8 (𝑛 = 𝑁 → (𝑛 + 1) = (𝑁 + 1))
65eqeq2d 2631 . . . . . . 7 (𝑛 = 𝑁 → ((#‘𝑤) = (𝑛 + 1) ↔ (#‘𝑤) = (𝑁 + 1)))
76adantr 481 . . . . . 6 ((𝑛 = 𝑁𝑔 = 𝐺) → ((#‘𝑤) = (𝑛 + 1) ↔ (#‘𝑤) = (𝑁 + 1)))
84, 7rabeqbidv 3193 . . . . 5 ((𝑛 = 𝑁𝑔 = 𝐺) → {𝑤 ∈ (WWalks‘𝑔) ∣ (#‘𝑤) = (𝑛 + 1)} = {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)})
98adantl 482 . . . 4 (((𝑁 ∈ ℕ0𝐺 ∈ V) ∧ (𝑛 = 𝑁𝑔 = 𝐺)) → {𝑤 ∈ (WWalks‘𝑔) ∣ (#‘𝑤) = (𝑛 + 1)} = {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)})
10 simpl 473 . . . 4 ((𝑁 ∈ ℕ0𝐺 ∈ V) → 𝑁 ∈ ℕ0)
11 simpr 477 . . . 4 ((𝑁 ∈ ℕ0𝐺 ∈ V) → 𝐺 ∈ V)
12 fvex 6199 . . . . . 6 (WWalks‘𝐺) ∈ V
1312rabex 4811 . . . . 5 {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)} ∈ V
1413a1i 11 . . . 4 ((𝑁 ∈ ℕ0𝐺 ∈ V) → {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)} ∈ V)
152, 9, 10, 11, 14ovmpt2d 6785 . . 3 ((𝑁 ∈ ℕ0𝐺 ∈ V) → (𝑁 WWalksN 𝐺) = {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)})
1615expcom 451 . 2 (𝐺 ∈ V → (𝑁 ∈ ℕ0 → (𝑁 WWalksN 𝐺) = {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)}))
171reldmmpt2 6768 . . . . 5 Rel dom WWalksN
1817ovprc2 6682 . . . 4 𝐺 ∈ V → (𝑁 WWalksN 𝐺) = ∅)
19 fvprc 6183 . . . . . 6 𝐺 ∈ V → (WWalks‘𝐺) = ∅)
2019rabeqdv 3192 . . . . 5 𝐺 ∈ V → {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)} = {𝑤 ∈ ∅ ∣ (#‘𝑤) = (𝑁 + 1)})
21 rab0 3953 . . . . 5 {𝑤 ∈ ∅ ∣ (#‘𝑤) = (𝑁 + 1)} = ∅
2220, 21syl6eq 2671 . . . 4 𝐺 ∈ V → {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)} = ∅)
2318, 22eqtr4d 2658 . . 3 𝐺 ∈ V → (𝑁 WWalksN 𝐺) = {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)})
2423a1d 25 . 2 𝐺 ∈ V → (𝑁 ∈ ℕ0 → (𝑁 WWalksN 𝐺) = {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)}))
2516, 24pm2.61i 176 1 (𝑁 ∈ ℕ0 → (𝑁 WWalksN 𝐺) = {𝑤 ∈ (WWalks‘𝐺) ∣ (#‘𝑤) = (𝑁 + 1)})
Colors of variables: wff setvar class
Syntax hints:  ¬ wn 3  wi 4  wb 196  wa 384   = wceq 1482  wcel 1989  {crab 2915  Vcvv 3198  c0 3913  cfv 5886  (class class class)co 6647  cmpt2 6649  1c1 9934   + caddc 9936  0cn0 11289  #chash 13112  WWalkscwwlks 26711   WWalksN cwwlksn 26712
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1721  ax-4 1736  ax-5 1838  ax-6 1887  ax-7 1934  ax-8 1991  ax-9 1998  ax-10 2018  ax-11 2033  ax-12 2046  ax-13 2245  ax-ext 2601  ax-sep 4779  ax-nul 4787  ax-pow 4841  ax-pr 4904
This theorem depends on definitions:  df-bi 197  df-or 385  df-an 386  df-3an 1039  df-tru 1485  df-ex 1704  df-nf 1709  df-sb 1880  df-eu 2473  df-mo 2474  df-clab 2608  df-cleq 2614  df-clel 2617  df-nfc 2752  df-ral 2916  df-rex 2917  df-rab 2920  df-v 3200  df-sbc 3434  df-dif 3575  df-un 3577  df-in 3579  df-ss 3586  df-nul 3914  df-if 4085  df-sn 4176  df-pr 4178  df-op 4182  df-uni 4435  df-br 4652  df-opab 4711  df-id 5022  df-xp 5118  df-rel 5119  df-cnv 5120  df-co 5121  df-dm 5122  df-iota 5849  df-fun 5888  df-fv 5894  df-ov 6650  df-oprab 6651  df-mpt2 6652  df-wwlksn 26717
This theorem is referenced by:  iswwlksn  26724  wwlksn0s  26740  0enwwlksnge1  26743  wwlksnfi  26795
  Copyright terms: Public domain W3C validator