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

Theorem modmulnn 11846
Description: Move a positive integer in and out of a floor in the first argument of a modulo operation. (Contributed by NM, 2-Jan-2009.)
Assertion
Ref Expression
modmulnn  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  (
( N  x.  ( |_ `  A ) )  mod  ( N  x.  M ) )  <_ 
( ( |_ `  ( N  x.  A
) )  mod  ( N  x.  M )
) )

Proof of Theorem modmulnn
StepHypRef Expression
1 nnre 10444 . . . . 5  |-  ( N  e.  NN  ->  N  e.  RR )
2 reflcl 11767 . . . . 5  |-  ( A  e.  RR  ->  ( |_ `  A )  e.  RR )
3 remulcl 9482 . . . . 5  |-  ( ( N  e.  RR  /\  ( |_ `  A )  e.  RR )  -> 
( N  x.  ( |_ `  A ) )  e.  RR )
41, 2, 3syl2an 477 . . . 4  |-  ( ( N  e.  NN  /\  A  e.  RR )  ->  ( N  x.  ( |_ `  A ) )  e.  RR )
543adant3 1008 . . 3  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( N  x.  ( |_ `  A ) )  e.  RR )
6 remulcl 9482 . . . . . 6  |-  ( ( N  e.  RR  /\  A  e.  RR )  ->  ( N  x.  A
)  e.  RR )
71, 6sylan 471 . . . . 5  |-  ( ( N  e.  NN  /\  A  e.  RR )  ->  ( N  x.  A
)  e.  RR )
8 reflcl 11767 . . . . 5  |-  ( ( N  x.  A )  e.  RR  ->  ( |_ `  ( N  x.  A ) )  e.  RR )
97, 8syl 16 . . . 4  |-  ( ( N  e.  NN  /\  A  e.  RR )  ->  ( |_ `  ( N  x.  A )
)  e.  RR )
1093adant3 1008 . . 3  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( |_ `  ( N  x.  A ) )  e.  RR )
11 nnmulcl 10460 . . . . . 6  |-  ( ( N  e.  NN  /\  M  e.  NN )  ->  ( N  x.  M
)  e.  NN )
1211nnred 10452 . . . . 5  |-  ( ( N  e.  NN  /\  M  e.  NN )  ->  ( N  x.  M
)  e.  RR )
13123adant2 1007 . . . 4  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( N  x.  M )  e.  RR )
14 nncn 10445 . . . . . . . . 9  |-  ( N  e.  NN  ->  N  e.  CC )
15 nnne0 10469 . . . . . . . . 9  |-  ( N  e.  NN  ->  N  =/=  0 )
1614, 15jca 532 . . . . . . . 8  |-  ( N  e.  NN  ->  ( N  e.  CC  /\  N  =/=  0 ) )
17 nncn 10445 . . . . . . . . 9  |-  ( M  e.  NN  ->  M  e.  CC )
18 nnne0 10469 . . . . . . . . 9  |-  ( M  e.  NN  ->  M  =/=  0 )
1917, 18jca 532 . . . . . . . 8  |-  ( M  e.  NN  ->  ( M  e.  CC  /\  M  =/=  0 ) )
20 mulne0 10093 . . . . . . . 8  |-  ( ( ( N  e.  CC  /\  N  =/=  0 )  /\  ( M  e.  CC  /\  M  =/=  0 ) )  -> 
( N  x.  M
)  =/=  0 )
2116, 19, 20syl2an 477 . . . . . . 7  |-  ( ( N  e.  NN  /\  M  e.  NN )  ->  ( N  x.  M
)  =/=  0 )
22213adant2 1007 . . . . . 6  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( N  x.  M )  =/=  0 )
235, 13, 22redivcld 10274 . . . . 5  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  (
( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) )  e.  RR )
24 reflcl 11767 . . . . 5  |-  ( ( ( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) )  e.  RR  ->  ( |_ `  ( ( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) ) )  e.  RR )
2523, 24syl 16 . . . 4  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( |_ `  ( ( N  x.  ( |_ `  A ) )  / 
( N  x.  M
) ) )  e.  RR )
2613, 25remulcld 9529 . . 3  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  (
( N  x.  M
)  x.  ( |_
`  ( ( N  x.  ( |_ `  A ) )  / 
( N  x.  M
) ) ) )  e.  RR )
27 nnnn0 10701 . . . . 5  |-  ( N  e.  NN  ->  N  e.  NN0 )
28 flmulnn0 11793 . . . . 5  |-  ( ( N  e.  NN0  /\  A  e.  RR )  ->  ( N  x.  ( |_ `  A ) )  <_  ( |_ `  ( N  x.  A
) ) )
2927, 28sylan 471 . . . 4  |-  ( ( N  e.  NN  /\  A  e.  RR )  ->  ( N  x.  ( |_ `  A ) )  <_  ( |_ `  ( N  x.  A
) ) )
30293adant3 1008 . . 3  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( N  x.  ( |_ `  A ) )  <_ 
( |_ `  ( N  x.  A )
) )
315, 10, 26, 30lesub1dd 10070 . 2  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  (
( N  x.  ( |_ `  A ) )  -  ( ( N  x.  M )  x.  ( |_ `  (
( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) ) ) ) )  <_  (
( |_ `  ( N  x.  A )
)  -  ( ( N  x.  M )  x.  ( |_ `  ( ( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) ) ) ) ) )
3211nnrpd 11141 . . . 4  |-  ( ( N  e.  NN  /\  M  e.  NN )  ->  ( N  x.  M
)  e.  RR+ )
33323adant2 1007 . . 3  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( N  x.  M )  e.  RR+ )
34 modval 11831 . . 3  |-  ( ( ( N  x.  ( |_ `  A ) )  e.  RR  /\  ( N  x.  M )  e.  RR+ )  ->  (
( N  x.  ( |_ `  A ) )  mod  ( N  x.  M ) )  =  ( ( N  x.  ( |_ `  A ) )  -  ( ( N  x.  M )  x.  ( |_ `  ( ( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) ) ) ) ) )
355, 33, 34syl2anc 661 . 2  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  (
( N  x.  ( |_ `  A ) )  mod  ( N  x.  M ) )  =  ( ( N  x.  ( |_ `  A ) )  -  ( ( N  x.  M )  x.  ( |_ `  ( ( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) ) ) ) ) )
36 modval 11831 . . . 4  |-  ( ( ( |_ `  ( N  x.  A )
)  e.  RR  /\  ( N  x.  M
)  e.  RR+ )  ->  ( ( |_ `  ( N  x.  A
) )  mod  ( N  x.  M )
)  =  ( ( |_ `  ( N  x.  A ) )  -  ( ( N  x.  M )  x.  ( |_ `  (
( |_ `  ( N  x.  A )
)  /  ( N  x.  M ) ) ) ) ) )
3710, 33, 36syl2anc 661 . . 3  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  (
( |_ `  ( N  x.  A )
)  mod  ( N  x.  M ) )  =  ( ( |_ `  ( N  x.  A
) )  -  (
( N  x.  M
)  x.  ( |_
`  ( ( |_
`  ( N  x.  A ) )  / 
( N  x.  M
) ) ) ) ) )
3873adant3 1008 . . . . . . 7  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( N  x.  A )  e.  RR )
39113adant2 1007 . . . . . . 7  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( N  x.  M )  e.  NN )
40 fldiv 11820 . . . . . . 7  |-  ( ( ( N  x.  A
)  e.  RR  /\  ( N  x.  M
)  e.  NN )  ->  ( |_ `  ( ( |_ `  ( N  x.  A
) )  /  ( N  x.  M )
) )  =  ( |_ `  ( ( N  x.  A )  /  ( N  x.  M ) ) ) )
4138, 39, 40syl2anc 661 . . . . . 6  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( |_ `  ( ( |_
`  ( N  x.  A ) )  / 
( N  x.  M
) ) )  =  ( |_ `  (
( N  x.  A
)  /  ( N  x.  M ) ) ) )
42 fldiv 11820 . . . . . . . . 9  |-  ( ( A  e.  RR  /\  M  e.  NN )  ->  ( |_ `  (
( |_ `  A
)  /  M ) )  =  ( |_
`  ( A  /  M ) ) )
43423adant3 1008 . . . . . . . 8  |-  ( ( A  e.  RR  /\  M  e.  NN  /\  N  e.  NN )  ->  ( |_ `  ( ( |_
`  A )  /  M ) )  =  ( |_ `  ( A  /  M ) ) )
442recnd 9527 . . . . . . . . . 10  |-  ( A  e.  RR  ->  ( |_ `  A )  e.  CC )
45 divcan5 10148 . . . . . . . . . 10  |-  ( ( ( |_ `  A
)  e.  CC  /\  ( M  e.  CC  /\  M  =/=  0 )  /\  ( N  e.  CC  /\  N  =/=  0 ) )  -> 
( ( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) )  =  ( ( |_
`  A )  /  M ) )
4644, 19, 16, 45syl3an 1261 . . . . . . . . 9  |-  ( ( A  e.  RR  /\  M  e.  NN  /\  N  e.  NN )  ->  (
( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) )  =  ( ( |_ `  A )  /  M
) )
4746fveq2d 5806 . . . . . . . 8  |-  ( ( A  e.  RR  /\  M  e.  NN  /\  N  e.  NN )  ->  ( |_ `  ( ( N  x.  ( |_ `  A ) )  / 
( N  x.  M
) ) )  =  ( |_ `  (
( |_ `  A
)  /  M ) ) )
48 recn 9487 . . . . . . . . . 10  |-  ( A  e.  RR  ->  A  e.  CC )
49 divcan5 10148 . . . . . . . . . 10  |-  ( ( A  e.  CC  /\  ( M  e.  CC  /\  M  =/=  0 )  /\  ( N  e.  CC  /\  N  =/=  0 ) )  -> 
( ( N  x.  A )  /  ( N  x.  M )
)  =  ( A  /  M ) )
5048, 19, 16, 49syl3an 1261 . . . . . . . . 9  |-  ( ( A  e.  RR  /\  M  e.  NN  /\  N  e.  NN )  ->  (
( N  x.  A
)  /  ( N  x.  M ) )  =  ( A  /  M ) )
5150fveq2d 5806 . . . . . . . 8  |-  ( ( A  e.  RR  /\  M  e.  NN  /\  N  e.  NN )  ->  ( |_ `  ( ( N  x.  A )  / 
( N  x.  M
) ) )  =  ( |_ `  ( A  /  M ) ) )
5243, 47, 513eqtr4rd 2506 . . . . . . 7  |-  ( ( A  e.  RR  /\  M  e.  NN  /\  N  e.  NN )  ->  ( |_ `  ( ( N  x.  A )  / 
( N  x.  M
) ) )  =  ( |_ `  (
( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) ) ) )
53523comr 1196 . . . . . 6  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( |_ `  ( ( N  x.  A )  / 
( N  x.  M
) ) )  =  ( |_ `  (
( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) ) ) )
5441, 53eqtrd 2495 . . . . 5  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  ( |_ `  ( ( |_
`  ( N  x.  A ) )  / 
( N  x.  M
) ) )  =  ( |_ `  (
( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) ) ) )
5554oveq2d 6219 . . . 4  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  (
( N  x.  M
)  x.  ( |_
`  ( ( |_
`  ( N  x.  A ) )  / 
( N  x.  M
) ) ) )  =  ( ( N  x.  M )  x.  ( |_ `  (
( N  x.  ( |_ `  A ) )  /  ( N  x.  M ) ) ) ) )
5655oveq2d 6219 . . 3  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  (
( |_ `  ( N  x.  A )
)  -  ( ( N  x.  M )  x.  ( |_ `  ( ( |_ `  ( N  x.  A
) )  /  ( N  x.  M )
) ) ) )  =  ( ( |_
`  ( N  x.  A ) )  -  ( ( N  x.  M )  x.  ( |_ `  ( ( N  x.  ( |_ `  A ) )  / 
( N  x.  M
) ) ) ) ) )
5737, 56eqtrd 2495 . 2  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  (
( |_ `  ( N  x.  A )
)  mod  ( N  x.  M ) )  =  ( ( |_ `  ( N  x.  A
) )  -  (
( N  x.  M
)  x.  ( |_
`  ( ( N  x.  ( |_ `  A ) )  / 
( N  x.  M
) ) ) ) ) )
5831, 35, 573brtr4d 4433 1  |-  ( ( N  e.  NN  /\  A  e.  RR  /\  M  e.  NN )  ->  (
( N  x.  ( |_ `  A ) )  mod  ( N  x.  M ) )  <_ 
( ( |_ `  ( N  x.  A
) )  mod  ( N  x.  M )
) )
Colors of variables: wff setvar class
Syntax hints:    -> wi 4    /\ wa 369    /\ w3a 965    = wceq 1370    e. wcel 1758    =/= wne 2648   class class class wbr 4403   ` cfv 5529  (class class class)co 6203   CCcc 9395   RRcr 9396   0cc0 9397    x. cmul 9402    <_ cle 9534    - cmin 9710    / cdiv 10108   NNcn 10437   NN0cn0 10694   RR+crp 11106   |_cfl 11761    mod cmo 11829
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1592  ax-4 1603  ax-5 1671  ax-6 1710  ax-7 1730  ax-8 1760  ax-9 1762  ax-10 1777  ax-11 1782  ax-12 1794  ax-13 1955  ax-ext 2432  ax-sep 4524  ax-nul 4532  ax-pow 4581  ax-pr 4642  ax-un 6485  ax-cnex 9453  ax-resscn 9454  ax-1cn 9455  ax-icn 9456  ax-addcl 9457  ax-addrcl 9458  ax-mulcl 9459  ax-mulrcl 9460  ax-mulcom 9461  ax-addass 9462  ax-mulass 9463  ax-distr 9464  ax-i2m1 9465  ax-1ne0 9466  ax-1rid 9467  ax-rnegex 9468  ax-rrecex 9469  ax-cnre 9470  ax-pre-lttri 9471  ax-pre-lttrn 9472  ax-pre-ltadd 9473  ax-pre-mulgt0 9474  ax-pre-sup 9475
This theorem depends on definitions:  df-bi 185  df-or 370  df-an 371  df-3or 966  df-3an 967  df-tru 1373  df-ex 1588  df-nf 1591  df-sb 1703  df-eu 2266  df-mo 2267  df-clab 2440  df-cleq 2446  df-clel 2449  df-nfc 2604  df-ne 2650  df-nel 2651  df-ral 2804  df-rex 2805  df-reu 2806  df-rmo 2807  df-rab 2808  df-v 3080  df-sbc 3295  df-csb 3399  df-dif 3442  df-un 3444  df-in 3446  df-ss 3453  df-pss 3455  df-nul 3749  df-if 3903  df-pw 3973  df-sn 3989  df-pr 3991  df-tp 3993  df-op 3995  df-uni 4203  df-iun 4284  df-br 4404  df-opab 4462  df-mpt 4463  df-tr 4497  df-eprel 4743  df-id 4747  df-po 4752  df-so 4753  df-fr 4790  df-we 4792  df-ord 4833  df-on 4834  df-lim 4835  df-suc 4836  df-xp 4957  df-rel 4958  df-cnv 4959  df-co 4960  df-dm 4961  df-rn 4962  df-res 4963  df-ima 4964  df-iota 5492  df-fun 5531  df-fn 5532  df-f 5533  df-f1 5534  df-fo 5535  df-f1o 5536  df-fv 5537  df-riota 6164  df-ov 6206  df-oprab 6207  df-mpt2 6208  df-om 6590  df-recs 6945  df-rdg 6979  df-er 7214  df-en 7424  df-dom 7425  df-sdom 7426  df-sup 7806  df-pnf 9535  df-mnf 9536  df-xr 9537  df-ltxr 9538  df-le 9539  df-sub 9712  df-neg 9713  df-div 10109  df-nn 10438  df-n0 10695  df-z 10762  df-uz 10977  df-rp 11107  df-fl 11763  df-mod 11830
This theorem is referenced by:  digit1  12119
  Copyright terms: Public domain W3C validator