ILE Home Intuitionistic Logic Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  ILE Home  >  Th. List  >  modqsubmod Unicode version

Theorem modqsubmod 10632
Description: The difference of a number modulo a modulus and another number equals the difference of the two numbers modulo the modulus. (Contributed by Jim Kingdon, 25-Oct-2021.)
Assertion
Ref Expression
modqsubmod  |-  ( ( ( A  e.  QQ  /\  B  e.  QQ )  /\  ( M  e.  QQ  /\  0  < 
M ) )  -> 
( ( ( A  mod  M )  -  B )  mod  M
)  =  ( ( A  -  B )  mod  M ) )

Proof of Theorem modqsubmod
StepHypRef Expression
1 simpll 527 . . 3  |-  ( ( ( A  e.  QQ  /\  B  e.  QQ )  /\  ( M  e.  QQ  /\  0  < 
M ) )  ->  A  e.  QQ )
2 simprl 529 . . 3  |-  ( ( ( A  e.  QQ  /\  B  e.  QQ )  /\  ( M  e.  QQ  /\  0  < 
M ) )  ->  M  e.  QQ )
3 simprr 531 . . 3  |-  ( ( ( A  e.  QQ  /\  B  e.  QQ )  /\  ( M  e.  QQ  /\  0  < 
M ) )  -> 
0  <  M )
41, 2, 3modqcld 10578 . 2  |-  ( ( ( A  e.  QQ  /\  B  e.  QQ )  /\  ( M  e.  QQ  /\  0  < 
M ) )  -> 
( A  mod  M
)  e.  QQ )
5 simplr 528 . 2  |-  ( ( ( A  e.  QQ  /\  B  e.  QQ )  /\  ( M  e.  QQ  /\  0  < 
M ) )  ->  B  e.  QQ )
6 modqabs2 10608 . . 3  |-  ( ( A  e.  QQ  /\  M  e.  QQ  /\  0  <  M )  ->  (
( A  mod  M
)  mod  M )  =  ( A  mod  M ) )
71, 2, 3, 6syl3anc 1271 . 2  |-  ( ( ( A  e.  QQ  /\  B  e.  QQ )  /\  ( M  e.  QQ  /\  0  < 
M ) )  -> 
( ( A  mod  M )  mod  M )  =  ( A  mod  M ) )
8 eqidd 2230 . 2  |-  ( ( ( A  e.  QQ  /\  B  e.  QQ )  /\  ( M  e.  QQ  /\  0  < 
M ) )  -> 
( B  mod  M
)  =  ( B  mod  M ) )
94, 1, 5, 5, 2, 3, 7, 8modqsub12d 10631 1  |-  ( ( ( A  e.  QQ  /\  B  e.  QQ )  /\  ( M  e.  QQ  /\  0  < 
M ) )  -> 
( ( ( A  mod  M )  -  B )  mod  M
)  =  ( ( A  -  B )  mod  M ) )
Colors of variables: wff set class
Syntax hints:    -> wi 4    /\ wa 104    = wceq 1395    e. wcel 2200   class class class wbr 4084  (class class class)co 6011   0cc0 8020    < clt 8202    - cmin 8338   QQcq 9841    mod cmo 10572
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-ia1 106  ax-ia2 107  ax-ia3 108  ax-in1 617  ax-in2 618  ax-io 714  ax-5 1493  ax-7 1494  ax-gen 1495  ax-ie1 1539  ax-ie2 1540  ax-8 1550  ax-10 1551  ax-11 1552  ax-i12 1553  ax-bndl 1555  ax-4 1556  ax-17 1572  ax-i9 1576  ax-ial 1580  ax-i5r 1581  ax-13 2202  ax-14 2203  ax-ext 2211  ax-sep 4203  ax-pow 4260  ax-pr 4295  ax-un 4526  ax-setind 4631  ax-cnex 8111  ax-resscn 8112  ax-1cn 8113  ax-1re 8114  ax-icn 8115  ax-addcl 8116  ax-addrcl 8117  ax-mulcl 8118  ax-mulrcl 8119  ax-addcom 8120  ax-mulcom 8121  ax-addass 8122  ax-mulass 8123  ax-distr 8124  ax-i2m1 8125  ax-0lt1 8126  ax-1rid 8127  ax-0id 8128  ax-rnegex 8129  ax-precex 8130  ax-cnre 8131  ax-pre-ltirr 8132  ax-pre-ltwlin 8133  ax-pre-lttrn 8134  ax-pre-apti 8135  ax-pre-ltadd 8136  ax-pre-mulgt0 8137  ax-pre-mulext 8138  ax-arch 8139
This theorem depends on definitions:  df-bi 117  df-3or 1003  df-3an 1004  df-tru 1398  df-fal 1401  df-nf 1507  df-sb 1809  df-eu 2080  df-mo 2081  df-clab 2216  df-cleq 2222  df-clel 2225  df-nfc 2361  df-ne 2401  df-nel 2496  df-ral 2513  df-rex 2514  df-reu 2515  df-rmo 2516  df-rab 2517  df-v 2802  df-sbc 3030  df-csb 3126  df-dif 3200  df-un 3202  df-in 3204  df-ss 3211  df-pw 3652  df-sn 3673  df-pr 3674  df-op 3676  df-uni 3890  df-int 3925  df-iun 3968  df-br 4085  df-opab 4147  df-mpt 4148  df-id 4386  df-po 4389  df-iso 4390  df-xp 4727  df-rel 4728  df-cnv 4729  df-co 4730  df-dm 4731  df-rn 4732  df-res 4733  df-ima 4734  df-iota 5282  df-fun 5324  df-fn 5325  df-f 5326  df-fv 5330  df-riota 5964  df-ov 6014  df-oprab 6015  df-mpo 6016  df-1st 6296  df-2nd 6297  df-pnf 8204  df-mnf 8205  df-xr 8206  df-ltxr 8207  df-le 8208  df-sub 8340  df-neg 8341  df-reap 8743  df-ap 8750  df-div 8841  df-inn 9132  df-n0 9391  df-z 9468  df-q 9842  df-rp 9877  df-fl 10518  df-mod 10573
This theorem is referenced by: (None)
  Copyright terms: Public domain W3C validator