Metamath Proof Explorer


Theorem modsubmodmod

Description: The difference of a real number modulo a positive real number and another real number modulo this positive real number equals the difference of the two real numbers modulo the positive real number. (Contributed by Alexander van der Vekens, 17-May-2018)

Ref Expression
Assertion modsubmodmod ABM+AmodMBmodMmodM=ABmodM

Proof

Step Hyp Ref Expression
1 modcl AM+AmodM
2 1 3adant2 ABM+AmodM
3 simp1 ABM+A
4 modcl BM+BmodM
5 4 3adant1 ABM+BmodM
6 simp2 ABM+B
7 simp3 ABM+M+
8 modabs2 AM+AmodMmodM=AmodM
9 8 3adant2 ABM+AmodMmodM=AmodM
10 modabs2 BM+BmodMmodM=BmodM
11 10 3adant1 ABM+BmodMmodM=BmodM
12 2 3 5 6 7 9 11 modsub12d ABM+AmodMBmodMmodM=ABmodM