Metamath Proof Explorer


Theorem elfzodifsumelfzo

Description: If an integer is in a half-open range of nonnegative integers with a difference as upper bound, the sum of the integer with the subtrahend of the difference is in a half-open range of nonnegative integers containing the minuend of the difference. (Contributed by AV, 13-Nov-2018)

Ref Expression
Assertion elfzodifsumelfzo M0NN0PI0..^NMI+M0..^P

Proof

Step Hyp Ref Expression
1 elfz2nn0 M0NM0N0MN
2 elfz2nn0 N0PN0P0NP
3 elfzo0 I0..^NMI0NMI<NM
4 nn0z M0M
5 nn0z N0N
6 znnsub MNM<NNM
7 4 5 6 syl2an M0N0M<NNM
8 simpr I<NMI0I0
9 simpll M0N0M<NM0
10 nn0addcl I0M0I+M0
11 8 9 10 syl2anr M0N0M<NI<NMI0I+M0
12 11 adantr M0N0M<NI<NMI0P0NPI+M0
13 0red M0N00
14 nn0re M0M
15 14 adantr M0N0M
16 nn0re N0N
17 16 adantl M0N0N
18 13 15 17 3jca M0N00MN
19 18 adantr M0N0M<N0MN
20 nn0ge0 M00M
21 20 adantr M0N00M
22 21 anim1i M0N0M<N0MM<N
23 lelttr 0MN0MM<N0<N
24 19 22 23 sylc M0N0M<N0<N
25 24 ex M0N0M<N0<N
26 0red P0N00
27 16 adantl P0N0N
28 nn0re P0P
29 28 adantr P0N0P
30 ltletr 0NP0<NNP0<P
31 26 27 29 30 syl3anc P0N00<NNP0<P
32 nn0z P0P
33 elnnz PP0<P
34 33 simplbi2 P0<PP
35 32 34 syl P00<PP
36 35 adantr P0N00<PP
37 31 36 syld P0N00<NNPP
38 37 exp4b P0N00<NNPP
39 38 com24 P0NP0<NN0P
40 39 imp P0NP0<NN0P
41 40 com13 N00<NP0NPP
42 41 adantl M0N00<NP0NPP
43 25 42 syld M0N0M<NP0NPP
44 43 imp M0N0M<NP0NPP
45 44 adantr M0N0M<NI<NMI0P0NPP
46 45 imp M0N0M<NI<NMI0P0NPP
47 nn0re I0I
48 47 adantl I<NMI0I
49 15 adantr M0N0M<NM
50 readdcl IMI+M
51 48 49 50 syl2anr M0N0M<NI<NMI0I+M
52 51 adantr M0N0M<NI<NMI0P0I+M
53 17 adantr M0N0M<NN
54 53 adantr M0N0M<NI<NMI0N
55 54 adantr M0N0M<NI<NMI0P0N
56 28 adantl M0N0M<NI<NMI0P0P
57 52 55 56 3jca M0N0M<NI<NMI0P0I+MNP
58 57 adantr M0N0M<NI<NMI0P0NPI+MNP
59 47 adantl M0N0I0I
60 15 adantr M0N0I0M
61 17 adantr M0N0I0N
62 59 60 61 ltaddsubd M0N0I0I+M<NI<NM
63 62 exbiri M0N0I0I<NMI+M<N
64 63 impcomd M0N0I<NMI0I+M<N
65 64 adantr M0N0M<NI<NMI0I+M<N
66 65 imp M0N0M<NI<NMI0I+M<N
67 66 adantr M0N0M<NI<NMI0P0I+M<N
68 67 anim1i M0N0M<NI<NMI0P0NPI+M<NNP
69 ltletr I+MNPI+M<NNPI+M<P
70 58 68 69 sylc M0N0M<NI<NMI0P0NPI+M<P
71 70 anasss M0N0M<NI<NMI0P0NPI+M<P
72 elfzo0 I+M0..^PI+M0PI+M<P
73 12 46 71 72 syl3anbrc M0N0M<NI<NMI0P0NPI+M0..^P
74 73 exp53 M0N0M<NI<NMI0P0NPI+M0..^P
75 7 74 sylbird M0N0NMI<NMI0P0NPI+M0..^P
76 75 3adant3 M0N0MNNMI<NMI0P0NPI+M0..^P
77 76 com14 I0NMI<NMM0N0MNP0NPI+M0..^P
78 77 3imp I0NMI<NMM0N0MNP0NPI+M0..^P
79 3 78 sylbi I0..^NMM0N0MNP0NPI+M0..^P
80 79 com13 P0NPM0N0MNI0..^NMI+M0..^P
81 80 3adant1 N0P0NPM0N0MNI0..^NMI+M0..^P
82 2 81 sylbi N0PM0N0MNI0..^NMI+M0..^P
83 82 com12 M0N0MNN0PI0..^NMI+M0..^P
84 1 83 sylbi M0NN0PI0..^NMI+M0..^P
85 84 imp M0NN0PI0..^NMI+M0..^P