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

Theorem nnmcom 8247
Description: Multiplication of natural numbers is commutative. Theorem 4K(5) of [Enderton] p. 81. (Contributed by NM, 21-Sep-1995.) (Proof shortened by Andrew Salmon, 22-Oct-2011.)
Assertion
Ref Expression
nnmcom ((𝐴 ∈ ω ∧ 𝐵 ∈ ω) → (𝐴 ·o 𝐵) = (𝐵 ·o 𝐴))

Proof of Theorem nnmcom
Dummy variables 𝑥 𝑦 are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 oveq1 7157 . . . . 5 (𝑥 = 𝐴 → (𝑥 ·o 𝐵) = (𝐴 ·o 𝐵))
2 oveq2 7158 . . . . 5 (𝑥 = 𝐴 → (𝐵 ·o 𝑥) = (𝐵 ·o 𝐴))
31, 2eqeq12d 2842 . . . 4 (𝑥 = 𝐴 → ((𝑥 ·o 𝐵) = (𝐵 ·o 𝑥) ↔ (𝐴 ·o 𝐵) = (𝐵 ·o 𝐴)))
43imbi2d 342 . . 3 (𝑥 = 𝐴 → ((𝐵 ∈ ω → (𝑥 ·o 𝐵) = (𝐵 ·o 𝑥)) ↔ (𝐵 ∈ ω → (𝐴 ·o 𝐵) = (𝐵 ·o 𝐴))))
5 oveq1 7157 . . . . 5 (𝑥 = ∅ → (𝑥 ·o 𝐵) = (∅ ·o 𝐵))
6 oveq2 7158 . . . . 5 (𝑥 = ∅ → (𝐵 ·o 𝑥) = (𝐵 ·o ∅))
75, 6eqeq12d 2842 . . . 4 (𝑥 = ∅ → ((𝑥 ·o 𝐵) = (𝐵 ·o 𝑥) ↔ (∅ ·o 𝐵) = (𝐵 ·o ∅)))
8 oveq1 7157 . . . . 5 (𝑥 = 𝑦 → (𝑥 ·o 𝐵) = (𝑦 ·o 𝐵))
9 oveq2 7158 . . . . 5 (𝑥 = 𝑦 → (𝐵 ·o 𝑥) = (𝐵 ·o 𝑦))
108, 9eqeq12d 2842 . . . 4 (𝑥 = 𝑦 → ((𝑥 ·o 𝐵) = (𝐵 ·o 𝑥) ↔ (𝑦 ·o 𝐵) = (𝐵 ·o 𝑦)))
11 oveq1 7157 . . . . 5 (𝑥 = suc 𝑦 → (𝑥 ·o 𝐵) = (suc 𝑦 ·o 𝐵))
12 oveq2 7158 . . . . 5 (𝑥 = suc 𝑦 → (𝐵 ·o 𝑥) = (𝐵 ·o suc 𝑦))
1311, 12eqeq12d 2842 . . . 4 (𝑥 = suc 𝑦 → ((𝑥 ·o 𝐵) = (𝐵 ·o 𝑥) ↔ (suc 𝑦 ·o 𝐵) = (𝐵 ·o suc 𝑦)))
14 nnm0r 8231 . . . . 5 (𝐵 ∈ ω → (∅ ·o 𝐵) = ∅)
15 nnm0 8226 . . . . 5 (𝐵 ∈ ω → (𝐵 ·o ∅) = ∅)
1614, 15eqtr4d 2864 . . . 4 (𝐵 ∈ ω → (∅ ·o 𝐵) = (𝐵 ·o ∅))
17 oveq1 7157 . . . . . 6 ((𝑦 ·o 𝐵) = (𝐵 ·o 𝑦) → ((𝑦 ·o 𝐵) +o 𝐵) = ((𝐵 ·o 𝑦) +o 𝐵))
18 nnmsucr 8246 . . . . . . 7 ((𝑦 ∈ ω ∧ 𝐵 ∈ ω) → (suc 𝑦 ·o 𝐵) = ((𝑦 ·o 𝐵) +o 𝐵))
19 nnmsuc 8228 . . . . . . . 8 ((𝐵 ∈ ω ∧ 𝑦 ∈ ω) → (𝐵 ·o suc 𝑦) = ((𝐵 ·o 𝑦) +o 𝐵))
2019ancoms 459 . . . . . . 7 ((𝑦 ∈ ω ∧ 𝐵 ∈ ω) → (𝐵 ·o suc 𝑦) = ((𝐵 ·o 𝑦) +o 𝐵))
2118, 20eqeq12d 2842 . . . . . 6 ((𝑦 ∈ ω ∧ 𝐵 ∈ ω) → ((suc 𝑦 ·o 𝐵) = (𝐵 ·o suc 𝑦) ↔ ((𝑦 ·o 𝐵) +o 𝐵) = ((𝐵 ·o 𝑦) +o 𝐵)))
2217, 21syl5ibr 247 . . . . 5 ((𝑦 ∈ ω ∧ 𝐵 ∈ ω) → ((𝑦 ·o 𝐵) = (𝐵 ·o 𝑦) → (suc 𝑦 ·o 𝐵) = (𝐵 ·o suc 𝑦)))
2322ex 413 . . . 4 (𝑦 ∈ ω → (𝐵 ∈ ω → ((𝑦 ·o 𝐵) = (𝐵 ·o 𝑦) → (suc 𝑦 ·o 𝐵) = (𝐵 ·o suc 𝑦))))
247, 10, 13, 16, 23finds2 7603 . . 3 (𝑥 ∈ ω → (𝐵 ∈ ω → (𝑥 ·o 𝐵) = (𝐵 ·o 𝑥)))
254, 24vtoclga 3579 . 2 (𝐴 ∈ ω → (𝐵 ∈ ω → (𝐴 ·o 𝐵) = (𝐵 ·o 𝐴)))
2625imp 407 1 ((𝐴 ∈ ω ∧ 𝐵 ∈ ω) → (𝐴 ·o 𝐵) = (𝐵 ·o 𝐴))
Colors of variables: wff setvar class
Syntax hints:  wi 4  wa 396   = wceq 1530  wcel 2107  c0 4295  suc csuc 6192  (class class class)co 7150  ωcom 7573   +o coa 8095   ·o comu 8096
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1789  ax-4 1803  ax-5 1904  ax-6 1963  ax-7 2008  ax-8 2109  ax-9 2117  ax-10 2138  ax-11 2153  ax-12 2169  ax-ext 2798  ax-sep 5200  ax-nul 5207  ax-pow 5263  ax-pr 5326  ax-un 7455
This theorem depends on definitions:  df-bi 208  df-an 397  df-or 844  df-3or 1082  df-3an 1083  df-tru 1533  df-ex 1774  df-nf 1778  df-sb 2063  df-mo 2620  df-eu 2652  df-clab 2805  df-cleq 2819  df-clel 2898  df-nfc 2968  df-ne 3022  df-ral 3148  df-rex 3149  df-reu 3150  df-rab 3152  df-v 3502  df-sbc 3777  df-csb 3888  df-dif 3943  df-un 3945  df-in 3947  df-ss 3956  df-pss 3958  df-nul 4296  df-if 4471  df-pw 4544  df-sn 4565  df-pr 4567  df-tp 4569  df-op 4571  df-uni 4838  df-iun 4919  df-br 5064  df-opab 5126  df-mpt 5144  df-tr 5170  df-id 5459  df-eprel 5464  df-po 5473  df-so 5474  df-fr 5513  df-we 5515  df-xp 5560  df-rel 5561  df-cnv 5562  df-co 5563  df-dm 5564  df-rn 5565  df-res 5566  df-ima 5567  df-pred 6147  df-ord 6193  df-on 6194  df-lim 6195  df-suc 6196  df-iota 6313  df-fun 6356  df-fn 6357  df-f 6358  df-f1 6359  df-fo 6360  df-f1o 6361  df-fv 6362  df-ov 7153  df-oprab 7154  df-mpo 7155  df-om 7574  df-wrecs 7943  df-recs 8004  df-rdg 8042  df-oadd 8102  df-omul 8103
This theorem is referenced by:  nnmwordri  8257  nn2m  8272  omopthlem1  8277  mulcompi  10312
  Copyright terms: Public domain W3C validator