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

Theorem mulp1mod1 13820
Description: The product of an integer and an integer greater than 1 increased by 1 is 1 modulo the integer greater than 1. (Contributed by AV, 15-Jul-2021.)
Assertion
Ref Expression
mulp1mod1 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → (((𝑁 · 𝐴) + 1) mod 𝑁) = 1)

Proof of Theorem mulp1mod1
StepHypRef Expression
1 eluzelcn 12750 . . . . . . . . 9 (𝑁 ∈ (ℤ‘2) → 𝑁 ∈ ℂ)
21adantl 481 . . . . . . . 8 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → 𝑁 ∈ ℂ)
3 zcn 12480 . . . . . . . . 9 (𝐴 ∈ ℤ → 𝐴 ∈ ℂ)
43adantr 480 . . . . . . . 8 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → 𝐴 ∈ ℂ)
52, 4mulcomd 11140 . . . . . . 7 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → (𝑁 · 𝐴) = (𝐴 · 𝑁))
65oveq1d 7367 . . . . . 6 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → ((𝑁 · 𝐴) mod 𝑁) = ((𝐴 · 𝑁) mod 𝑁))
7 eluz2nn 12788 . . . . . . . 8 (𝑁 ∈ (ℤ‘2) → 𝑁 ∈ ℕ)
87nnrpd 12934 . . . . . . 7 (𝑁 ∈ (ℤ‘2) → 𝑁 ∈ ℝ+)
9 mulmod0 13783 . . . . . . 7 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ ℝ+) → ((𝐴 · 𝑁) mod 𝑁) = 0)
108, 9sylan2 593 . . . . . 6 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → ((𝐴 · 𝑁) mod 𝑁) = 0)
116, 10eqtrd 2768 . . . . 5 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → ((𝑁 · 𝐴) mod 𝑁) = 0)
1211oveq1d 7367 . . . 4 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → (((𝑁 · 𝐴) mod 𝑁) + 1) = (0 + 1))
13 0p1e1 12249 . . . 4 (0 + 1) = 1
1412, 13eqtrdi 2784 . . 3 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → (((𝑁 · 𝐴) mod 𝑁) + 1) = 1)
1514oveq1d 7367 . 2 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → ((((𝑁 · 𝐴) mod 𝑁) + 1) mod 𝑁) = (1 mod 𝑁))
16 eluzelre 12749 . . . . 5 (𝑁 ∈ (ℤ‘2) → 𝑁 ∈ ℝ)
1716adantl 481 . . . 4 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → 𝑁 ∈ ℝ)
18 zre 12479 . . . . 5 (𝐴 ∈ ℤ → 𝐴 ∈ ℝ)
1918adantr 480 . . . 4 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → 𝐴 ∈ ℝ)
2017, 19remulcld 11149 . . 3 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → (𝑁 · 𝐴) ∈ ℝ)
21 1red 11120 . . 3 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → 1 ∈ ℝ)
228adantl 481 . . 3 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → 𝑁 ∈ ℝ+)
23 modaddmod 13818 . . 3 (((𝑁 · 𝐴) ∈ ℝ ∧ 1 ∈ ℝ ∧ 𝑁 ∈ ℝ+) → ((((𝑁 · 𝐴) mod 𝑁) + 1) mod 𝑁) = (((𝑁 · 𝐴) + 1) mod 𝑁))
2420, 21, 22, 23syl3anc 1373 . 2 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → ((((𝑁 · 𝐴) mod 𝑁) + 1) mod 𝑁) = (((𝑁 · 𝐴) + 1) mod 𝑁))
25 eluz2gt1 12820 . . . . 5 (𝑁 ∈ (ℤ‘2) → 1 < 𝑁)
2616, 25jca 511 . . . 4 (𝑁 ∈ (ℤ‘2) → (𝑁 ∈ ℝ ∧ 1 < 𝑁))
2726adantl 481 . . 3 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → (𝑁 ∈ ℝ ∧ 1 < 𝑁))
28 1mod 13809 . . 3 ((𝑁 ∈ ℝ ∧ 1 < 𝑁) → (1 mod 𝑁) = 1)
2927, 28syl 17 . 2 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → (1 mod 𝑁) = 1)
3015, 24, 293eqtr3d 2776 1 ((𝐴 ∈ ℤ ∧ 𝑁 ∈ (ℤ‘2)) → (((𝑁 · 𝐴) + 1) mod 𝑁) = 1)
Colors of variables: wff setvar class
Syntax hints:  wi 4  wa 395   = wceq 1541  wcel 2113   class class class wbr 5093  cfv 6486  (class class class)co 7352  cc 11011  cr 11012  0cc0 11013  1c1 11014   + caddc 11016   · cmul 11018   < clt 11153  2c2 12187  cz 12475  cuz 12738  +crp 12892   mod cmo 13775
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1796  ax-4 1810  ax-5 1911  ax-6 1968  ax-7 2009  ax-8 2115  ax-9 2123  ax-10 2146  ax-11 2162  ax-12 2182  ax-ext 2705  ax-sep 5236  ax-nul 5246  ax-pow 5305  ax-pr 5372  ax-un 7674  ax-cnex 11069  ax-resscn 11070  ax-1cn 11071  ax-icn 11072  ax-addcl 11073  ax-addrcl 11074  ax-mulcl 11075  ax-mulrcl 11076  ax-mulcom 11077  ax-addass 11078  ax-mulass 11079  ax-distr 11080  ax-i2m1 11081  ax-1ne0 11082  ax-1rid 11083  ax-rnegex 11084  ax-rrecex 11085  ax-cnre 11086  ax-pre-lttri 11087  ax-pre-lttrn 11088  ax-pre-ltadd 11089  ax-pre-mulgt0 11090  ax-pre-sup 11091
This theorem depends on definitions:  df-bi 207  df-an 396  df-or 848  df-3or 1087  df-3an 1088  df-tru 1544  df-fal 1554  df-ex 1781  df-nf 1785  df-sb 2068  df-mo 2537  df-eu 2566  df-clab 2712  df-cleq 2725  df-clel 2808  df-nfc 2882  df-ne 2930  df-nel 3034  df-ral 3049  df-rex 3058  df-rmo 3347  df-reu 3348  df-rab 3397  df-v 3439  df-sbc 3738  df-csb 3847  df-dif 3901  df-un 3903  df-in 3905  df-ss 3915  df-pss 3918  df-nul 4283  df-if 4475  df-pw 4551  df-sn 4576  df-pr 4578  df-op 4582  df-uni 4859  df-iun 4943  df-br 5094  df-opab 5156  df-mpt 5175  df-tr 5201  df-id 5514  df-eprel 5519  df-po 5527  df-so 5528  df-fr 5572  df-we 5574  df-xp 5625  df-rel 5626  df-cnv 5627  df-co 5628  df-dm 5629  df-rn 5630  df-res 5631  df-ima 5632  df-pred 6253  df-ord 6314  df-on 6315  df-lim 6316  df-suc 6317  df-iota 6442  df-fun 6488  df-fn 6489  df-f 6490  df-f1 6491  df-fo 6492  df-f1o 6493  df-fv 6494  df-riota 7309  df-ov 7355  df-oprab 7356  df-mpo 7357  df-om 7803  df-2nd 7928  df-frecs 8217  df-wrecs 8248  df-recs 8297  df-rdg 8335  df-er 8628  df-en 8876  df-dom 8877  df-sdom 8878  df-sup 9333  df-inf 9334  df-pnf 11155  df-mnf 11156  df-xr 11157  df-ltxr 11158  df-le 11159  df-sub 11353  df-neg 11354  df-div 11782  df-nn 12133  df-2 12195  df-n0 12389  df-z 12476  df-uz 12739  df-rp 12893  df-fl 13698  df-mod 13776
This theorem is referenced by:  fmtnoprmfac2lem1  47691
  Copyright terms: Public domain W3C validator