Metamath Proof Explorer


Theorem subfzo0

Description: The difference between two elements in a half-open range of nonnegative integers is greater than the negation of the upper bound and less than the upper bound of the range. (Contributed by AV, 20-Mar-2021)

Ref Expression
Assertion subfzo0 I0..^NJ0..^NN<IJIJ<N

Proof

Step Hyp Ref Expression
1 elfzo0 I0..^NI0NI<N
2 elfzo0 J0..^NJ0NJ<N
3 nn0re I0I
4 3 adantr I0I<NI
5 nnre NN
6 nn0re J0J
7 resubcl NJNJ
8 5 6 7 syl2an NJ0NJ
9 8 ancoms J0NNJ
10 9 3adant3 J0NJ<NNJ
11 4 10 anim12i I0I<NJ0NJ<NINJ
12 nn0ge0 I00I
13 12 adantr I0I<N0I
14 posdif JNJ<N0<NJ
15 6 5 14 syl2an J0NJ<N0<NJ
16 15 biimp3a J0NJ<N0<NJ
17 13 16 anim12i I0I<NJ0NJ<N0I0<NJ
18 addgegt0 INJ0I0<NJ0<I+N-J
19 11 17 18 syl2anc I0I<NJ0NJ<N0<I+N-J
20 nn0cn I0I
21 20 adantr I0I<NI
22 21 adantr I0I<NJ0NJ<NI
23 nn0cn J0J
24 23 3ad2ant1 J0NJ<NJ
25 24 adantl I0I<NJ0NJ<NJ
26 nncn NN
27 26 3ad2ant2 J0NJ<NN
28 27 adantl I0I<NJ0NJ<NN
29 22 25 28 subadd23d I0I<NJ0NJ<NI-J+N=I+N-J
30 19 29 breqtrrd I0I<NJ0NJ<N0<I-J+N
31 6 3ad2ant1 J0NJ<NJ
32 resubcl IJIJ
33 4 31 32 syl2an I0I<NJ0NJ<NIJ
34 5 3ad2ant2 J0NJ<NN
35 34 adantl I0I<NJ0NJ<NN
36 33 35 possumd I0I<NJ0NJ<N0<I-J+NN<IJ
37 30 36 mpbid I0I<NJ0NJ<NN<IJ
38 3 adantr I0J0NJ<NI
39 34 adantl I0J0NJ<NN
40 readdcl JNJ+N
41 6 5 40 syl2an J0NJ+N
42 41 3adant3 J0NJ<NJ+N
43 42 adantl I0J0NJ<NJ+N
44 38 39 43 3jca I0J0NJ<NINJ+N
45 nn0ge0 J00J
46 45 3ad2ant1 J0NJ<N0J
47 46 adantl I0J0NJ<N0J
48 5 6 anim12i NJ0NJ
49 48 ancoms J0NNJ
50 49 3adant3 J0NJ<NNJ
51 50 adantl I0J0NJ<NNJ
52 addge02 NJ0JNJ+N
53 51 52 syl I0J0NJ<N0JNJ+N
54 47 53 mpbid I0J0NJ<NNJ+N
55 44 54 lelttrdi I0J0NJ<NI<NI<J+N
56 55 impancom I0I<NJ0NJ<NI<J+N
57 56 imp I0I<NJ0NJ<NI<J+N
58 4 adantr I0I<NJ0NJ<NI
59 31 adantl I0I<NJ0NJ<NJ
60 58 59 35 ltsubadd2d I0I<NJ0NJ<NIJ<NI<J+N
61 57 60 mpbird I0I<NJ0NJ<NIJ<N
62 37 61 jca I0I<NJ0NJ<NN<IJIJ<N
63 62 ex I0I<NJ0NJ<NN<IJIJ<N
64 2 63 biimtrid I0I<NJ0..^NN<IJIJ<N
65 64 3adant2 I0NI<NJ0..^NN<IJIJ<N
66 1 65 sylbi I0..^NJ0..^NN<IJIJ<N
67 66 imp I0..^NJ0..^NN<IJIJ<N