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

Theorem vtxdgfval 26419
 Description: The value of the vertex degree function. (Contributed by Mario Carneiro, 12-Mar-2015.) (Revised by Alexander van der Vekens, 20-Dec-2017.) (Revised by AV, 9-Dec-2020.)
Hypotheses
Ref Expression
vtxdgfval.v 𝑉 = (Vtx‘𝐺)
vtxdgfval.i 𝐼 = (iEdg‘𝐺)
vtxdgfval.a 𝐴 = dom 𝐼
Assertion
Ref Expression
vtxdgfval (𝐺𝑊 → (VtxDeg‘𝐺) = (𝑢𝑉 ↦ ((#‘{𝑥𝐴𝑢 ∈ (𝐼𝑥)}) +𝑒 (#‘{𝑥𝐴 ∣ (𝐼𝑥) = {𝑢}}))))
Distinct variable groups:   𝑥,𝑢   𝑥,𝐴   𝑢,𝐺,𝑥   𝑢,𝑉
Allowed substitution hints:   𝐴(𝑢)   𝐼(𝑥,𝑢)   𝑉(𝑥)   𝑊(𝑥,𝑢)

Proof of Theorem vtxdgfval
Dummy variables 𝑒 𝑔 𝑣 are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 df-vtxdg 26418 . . 3 VtxDeg = (𝑔 ∈ V ↦ (Vtx‘𝑔) / 𝑣(iEdg‘𝑔) / 𝑒(𝑢𝑣 ↦ ((#‘{𝑥 ∈ dom 𝑒𝑢 ∈ (𝑒𝑥)}) +𝑒 (#‘{𝑥 ∈ dom 𝑒 ∣ (𝑒𝑥) = {𝑢}}))))
21a1i 11 . 2 (𝐺𝑊 → VtxDeg = (𝑔 ∈ V ↦ (Vtx‘𝑔) / 𝑣(iEdg‘𝑔) / 𝑒(𝑢𝑣 ↦ ((#‘{𝑥 ∈ dom 𝑒𝑢 ∈ (𝑒𝑥)}) +𝑒 (#‘{𝑥 ∈ dom 𝑒 ∣ (𝑒𝑥) = {𝑢}})))))
3 fvex 6239 . . . 4 (Vtx‘𝑔) ∈ V
4 fvex 6239 . . . 4 (iEdg‘𝑔) ∈ V
5 simpl 472 . . . . 5 ((𝑣 = (Vtx‘𝑔) ∧ 𝑒 = (iEdg‘𝑔)) → 𝑣 = (Vtx‘𝑔))
6 dmeq 5356 . . . . . . . . 9 (𝑒 = (iEdg‘𝑔) → dom 𝑒 = dom (iEdg‘𝑔))
7 fveq1 6228 . . . . . . . . . 10 (𝑒 = (iEdg‘𝑔) → (𝑒𝑥) = ((iEdg‘𝑔)‘𝑥))
87eleq2d 2716 . . . . . . . . 9 (𝑒 = (iEdg‘𝑔) → (𝑢 ∈ (𝑒𝑥) ↔ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)))
96, 8rabeqbidv 3226 . . . . . . . 8 (𝑒 = (iEdg‘𝑔) → {𝑥 ∈ dom 𝑒𝑢 ∈ (𝑒𝑥)} = {𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)})
109fveq2d 6233 . . . . . . 7 (𝑒 = (iEdg‘𝑔) → (#‘{𝑥 ∈ dom 𝑒𝑢 ∈ (𝑒𝑥)}) = (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)}))
117eqeq1d 2653 . . . . . . . . 9 (𝑒 = (iEdg‘𝑔) → ((𝑒𝑥) = {𝑢} ↔ ((iEdg‘𝑔)‘𝑥) = {𝑢}))
126, 11rabeqbidv 3226 . . . . . . . 8 (𝑒 = (iEdg‘𝑔) → {𝑥 ∈ dom 𝑒 ∣ (𝑒𝑥) = {𝑢}} = {𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}})
1312fveq2d 6233 . . . . . . 7 (𝑒 = (iEdg‘𝑔) → (#‘{𝑥 ∈ dom 𝑒 ∣ (𝑒𝑥) = {𝑢}}) = (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}}))
1410, 13oveq12d 6708 . . . . . 6 (𝑒 = (iEdg‘𝑔) → ((#‘{𝑥 ∈ dom 𝑒𝑢 ∈ (𝑒𝑥)}) +𝑒 (#‘{𝑥 ∈ dom 𝑒 ∣ (𝑒𝑥) = {𝑢}})) = ((#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)}) +𝑒 (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}})))
1514adantl 481 . . . . 5 ((𝑣 = (Vtx‘𝑔) ∧ 𝑒 = (iEdg‘𝑔)) → ((#‘{𝑥 ∈ dom 𝑒𝑢 ∈ (𝑒𝑥)}) +𝑒 (#‘{𝑥 ∈ dom 𝑒 ∣ (𝑒𝑥) = {𝑢}})) = ((#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)}) +𝑒 (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}})))
165, 15mpteq12dv 4766 . . . 4 ((𝑣 = (Vtx‘𝑔) ∧ 𝑒 = (iEdg‘𝑔)) → (𝑢𝑣 ↦ ((#‘{𝑥 ∈ dom 𝑒𝑢 ∈ (𝑒𝑥)}) +𝑒 (#‘{𝑥 ∈ dom 𝑒 ∣ (𝑒𝑥) = {𝑢}}))) = (𝑢 ∈ (Vtx‘𝑔) ↦ ((#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)}) +𝑒 (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}}))))
173, 4, 16csbie2 3596 . . 3 (Vtx‘𝑔) / 𝑣(iEdg‘𝑔) / 𝑒(𝑢𝑣 ↦ ((#‘{𝑥 ∈ dom 𝑒𝑢 ∈ (𝑒𝑥)}) +𝑒 (#‘{𝑥 ∈ dom 𝑒 ∣ (𝑒𝑥) = {𝑢}}))) = (𝑢 ∈ (Vtx‘𝑔) ↦ ((#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)}) +𝑒 (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}})))
18 fveq2 6229 . . . . . 6 (𝑔 = 𝐺 → (Vtx‘𝑔) = (Vtx‘𝐺))
19 vtxdgfval.v . . . . . 6 𝑉 = (Vtx‘𝐺)
2018, 19syl6eqr 2703 . . . . 5 (𝑔 = 𝐺 → (Vtx‘𝑔) = 𝑉)
21 fveq2 6229 . . . . . . . . . 10 (𝑔 = 𝐺 → (iEdg‘𝑔) = (iEdg‘𝐺))
2221dmeqd 5358 . . . . . . . . 9 (𝑔 = 𝐺 → dom (iEdg‘𝑔) = dom (iEdg‘𝐺))
23 vtxdgfval.a . . . . . . . . . 10 𝐴 = dom 𝐼
24 vtxdgfval.i . . . . . . . . . . 11 𝐼 = (iEdg‘𝐺)
2524dmeqi 5357 . . . . . . . . . 10 dom 𝐼 = dom (iEdg‘𝐺)
2623, 25eqtri 2673 . . . . . . . . 9 𝐴 = dom (iEdg‘𝐺)
2722, 26syl6eqr 2703 . . . . . . . 8 (𝑔 = 𝐺 → dom (iEdg‘𝑔) = 𝐴)
2821, 24syl6eqr 2703 . . . . . . . . . 10 (𝑔 = 𝐺 → (iEdg‘𝑔) = 𝐼)
2928fveq1d 6231 . . . . . . . . 9 (𝑔 = 𝐺 → ((iEdg‘𝑔)‘𝑥) = (𝐼𝑥))
3029eleq2d 2716 . . . . . . . 8 (𝑔 = 𝐺 → (𝑢 ∈ ((iEdg‘𝑔)‘𝑥) ↔ 𝑢 ∈ (𝐼𝑥)))
3127, 30rabeqbidv 3226 . . . . . . 7 (𝑔 = 𝐺 → {𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)} = {𝑥𝐴𝑢 ∈ (𝐼𝑥)})
3231fveq2d 6233 . . . . . 6 (𝑔 = 𝐺 → (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)}) = (#‘{𝑥𝐴𝑢 ∈ (𝐼𝑥)}))
3329eqeq1d 2653 . . . . . . . 8 (𝑔 = 𝐺 → (((iEdg‘𝑔)‘𝑥) = {𝑢} ↔ (𝐼𝑥) = {𝑢}))
3427, 33rabeqbidv 3226 . . . . . . 7 (𝑔 = 𝐺 → {𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}} = {𝑥𝐴 ∣ (𝐼𝑥) = {𝑢}})
3534fveq2d 6233 . . . . . 6 (𝑔 = 𝐺 → (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}}) = (#‘{𝑥𝐴 ∣ (𝐼𝑥) = {𝑢}}))
3632, 35oveq12d 6708 . . . . 5 (𝑔 = 𝐺 → ((#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)}) +𝑒 (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}})) = ((#‘{𝑥𝐴𝑢 ∈ (𝐼𝑥)}) +𝑒 (#‘{𝑥𝐴 ∣ (𝐼𝑥) = {𝑢}})))
3720, 36mpteq12dv 4766 . . . 4 (𝑔 = 𝐺 → (𝑢 ∈ (Vtx‘𝑔) ↦ ((#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)}) +𝑒 (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}}))) = (𝑢𝑉 ↦ ((#‘{𝑥𝐴𝑢 ∈ (𝐼𝑥)}) +𝑒 (#‘{𝑥𝐴 ∣ (𝐼𝑥) = {𝑢}}))))
3837adantl 481 . . 3 ((𝐺𝑊𝑔 = 𝐺) → (𝑢 ∈ (Vtx‘𝑔) ↦ ((#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ 𝑢 ∈ ((iEdg‘𝑔)‘𝑥)}) +𝑒 (#‘{𝑥 ∈ dom (iEdg‘𝑔) ∣ ((iEdg‘𝑔)‘𝑥) = {𝑢}}))) = (𝑢𝑉 ↦ ((#‘{𝑥𝐴𝑢 ∈ (𝐼𝑥)}) +𝑒 (#‘{𝑥𝐴 ∣ (𝐼𝑥) = {𝑢}}))))
3917, 38syl5eq 2697 . 2 ((𝐺𝑊𝑔 = 𝐺) → (Vtx‘𝑔) / 𝑣(iEdg‘𝑔) / 𝑒(𝑢𝑣 ↦ ((#‘{𝑥 ∈ dom 𝑒𝑢 ∈ (𝑒𝑥)}) +𝑒 (#‘{𝑥 ∈ dom 𝑒 ∣ (𝑒𝑥) = {𝑢}}))) = (𝑢𝑉 ↦ ((#‘{𝑥𝐴𝑢 ∈ (𝐼𝑥)}) +𝑒 (#‘{𝑥𝐴 ∣ (𝐼𝑥) = {𝑢}}))))
40 elex 3243 . 2 (𝐺𝑊𝐺 ∈ V)
41 fvex 6239 . . . 4 (Vtx‘𝐺) ∈ V
4219, 41eqeltri 2726 . . 3 𝑉 ∈ V
43 mptexg 6525 . . 3 (𝑉 ∈ V → (𝑢𝑉 ↦ ((#‘{𝑥𝐴𝑢 ∈ (𝐼𝑥)}) +𝑒 (#‘{𝑥𝐴 ∣ (𝐼𝑥) = {𝑢}}))) ∈ V)
4442, 43mp1i 13 . 2 (𝐺𝑊 → (𝑢𝑉 ↦ ((#‘{𝑥𝐴𝑢 ∈ (𝐼𝑥)}) +𝑒 (#‘{𝑥𝐴 ∣ (𝐼𝑥) = {𝑢}}))) ∈ V)
452, 39, 40, 44fvmptd 6327 1 (𝐺𝑊 → (VtxDeg‘𝐺) = (𝑢𝑉 ↦ ((#‘{𝑥𝐴𝑢 ∈ (𝐼𝑥)}) +𝑒 (#‘{𝑥𝐴 ∣ (𝐼𝑥) = {𝑢}}))))
 Colors of variables: wff setvar class Syntax hints:   → wi 4   ∧ wa 383   = wceq 1523   ∈ wcel 2030  {crab 2945  Vcvv 3231  ⦋csb 3566  {csn 4210   ↦ cmpt 4762  dom cdm 5143  ‘cfv 5926  (class class class)co 6690   +𝑒 cxad 11982  #chash 13157  Vtxcvtx 25919  iEdgciedg 25920  VtxDegcvtxdg 26417 This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1762  ax-4 1777  ax-5 1879  ax-6 1945  ax-7 1981  ax-9 2039  ax-10 2059  ax-11 2074  ax-12 2087  ax-13 2282  ax-ext 2631  ax-rep 4804  ax-sep 4814  ax-nul 4822  ax-pr 4936 This theorem depends on definitions:  df-bi 197  df-or 384  df-an 385  df-3an 1056  df-tru 1526  df-ex 1745  df-nf 1750  df-sb 1938  df-eu 2502  df-mo 2503  df-clab 2638  df-cleq 2644  df-clel 2647  df-nfc 2782  df-ne 2824  df-ral 2946  df-rex 2947  df-reu 2948  df-rab 2950  df-v 3233  df-sbc 3469  df-csb 3567  df-dif 3610  df-un 3612  df-in 3614  df-ss 3621  df-nul 3949  df-if 4120  df-sn 4211  df-pr 4213  df-op 4217  df-uni 4469  df-iun 4554  df-br 4686  df-opab 4746  df-mpt 4763  df-id 5053  df-xp 5149  df-rel 5150  df-cnv 5151  df-co 5152  df-dm 5153  df-rn 5154  df-res 5155  df-ima 5156  df-iota 5889  df-fun 5928  df-fn 5929  df-f 5930  df-f1 5931  df-fo 5932  df-f1o 5933  df-fv 5934  df-ov 6693  df-vtxdg 26418 This theorem is referenced by:  vtxdgval  26420  vtxdgop  26422  vtxdgf  26423  vtxdeqd  26429
 Copyright terms: Public domain W3C validator