Metamath Proof Explorer


Theorem elfznelfzo

Description: A value in a finite set of sequential integers is a border value if it is not contained in the half-open integer range contained in the finite set of sequential integers. (Contributed by Alexander van der Vekens, 31-Oct-2017) (Revised by Thierry Arnoux, 22-Dec-2021)

Ref Expression
Assertion elfznelfzo M0K¬M1..^KM=0M=K

Proof

Step Hyp Ref Expression
1 elfz2nn0 M0KM0K0MK
2 nn0z M0M
3 nn0z K0K
4 2 3 anim12i M0K0MK
5 4 3adant3 M0K0MKMK
6 elfzom1b MKM1..^KM10..^K1
7 5 6 syl M0K0MKM1..^KM10..^K1
8 7 notbid M0K0MK¬M1..^K¬M10..^K1
9 elfzo0 M10..^K1M10K1M1<K1
10 9 a1i M0K0MKM10..^K1M10K1M1<K1
11 10 notbid M0K0MK¬M10..^K1¬M10K1M1<K1
12 3ianor ¬M10K1M1<K1¬M10¬K1¬M1<K1
13 elnnne0 MM0M0
14 df-ne M0¬M=0
15 14 anbi2i M0M0M0¬M=0
16 13 15 bitr2i M0¬M=0M
17 nnm1nn0 MM10
18 16 17 sylbi M0¬M=0M10
19 18 ex M0¬M=0M10
20 19 con1d M0¬M10M=0
21 20 imp M0¬M10M=0
22 21 orcd M0¬M10M=0M=K
23 22 ex M0¬M10M=0M=K
24 23 3ad2ant1 M0K0MK¬M10M=0M=K
25 24 com12 ¬M10M0K0MKM=0M=K
26 ioran ¬M=0M=K¬M=0¬M=K
27 nn1m1nn MM=1M1
28 df-ne MK¬M=K
29 necom MKKM
30 nn0re M0M
31 30 ad2antlr K0M0MKM
32 nn0re K0K
33 32 adantr K0M0K
34 33 adantr K0M0MKK
35 simpr K0M0MKMK
36 31 34 35 leltned K0M0MKM<KKM
37 29 36 bitr4id K0M0MKMKM<K
38 37 adantr K0M0MKM=1MKM<K
39 breq1 M=1M<K1<K
40 39 biimpa M=1M<K1<K
41 1red K0M01
42 41 33 41 ltsub1d K0M01<K11<K1
43 1m1e0 11=0
44 43 breq1i 11<K10<K1
45 1zzd K01
46 3 45 zsubcld K0K1
47 46 adantr K0M0K1
48 47 adantr K0M00<K1K1
49 simpr K0M00<K10<K1
50 elnnz K1K10<K1
51 48 49 50 sylanbrc K0M00<K1K1
52 51 ex K0M00<K1K1
53 44 52 biimtrid K0M011<K1K1
54 42 53 sylbid K0M01<KK1
55 40 54 syl5 K0M0M=1M<KK1
56 55 expd K0M0M=1M<KK1
57 56 adantr K0M0MKM=1M<KK1
58 57 imp K0M0MKM=1M<KK1
59 38 58 sylbid K0M0MKM=1MKK1
60 59 exp31 K0M0MKM=1MKK1
61 60 com14 MKMKM=1K0M0K1
62 28 61 sylbir ¬M=KMKM=1K0M0K1
63 62 com23 ¬M=KM=1MKK0M0K1
64 63 com14 K0M0M=1MK¬M=KK1
65 64 ex K0M0M=1MK¬M=KK1
66 65 com14 MKM0M=1K0¬M=KK1
67 66 com13 M=1M0MKK0¬M=KK1
68 30 ad2antlr M1M0K0M
69 32 adantl M1M0K0K
70 1red M1M0K01
71 68 69 70 lesub1d M1M0K0MKM1K1
72 3 ad2antlr M1M0K0M1K1K
73 1zzd M1M0K0M1K11
74 72 73 zsubcld M1M0K0M1K1K1
75 nngt0 M10<M1
76 0red M0K00
77 peano2rem MM1
78 30 77 syl M0M1
79 78 adantr M0K0M1
80 peano2rem KK1
81 32 80 syl K0K1
82 81 adantl M0K0K1
83 ltletr 0M1K10<M1M1K10<K1
84 76 79 82 83 syl3anc M0K00<M1M1K10<K1
85 84 ex M0K00<M1M1K10<K1
86 85 com13 0<M1M1K1K0M00<K1
87 86 ex 0<M1M1K1K0M00<K1
88 87 com24 0<M1M0K0M1K10<K1
89 75 88 syl M1M0K0M1K10<K1
90 89 imp41 M1M0K0M1K10<K1
91 74 90 50 sylanbrc M1M0K0M1K1K1
92 91 a1d M1M0K0M1K1¬M=KK1
93 92 ex M1M0K0M1K1¬M=KK1
94 71 93 sylbid M1M0K0MK¬M=KK1
95 94 ex M1M0K0MK¬M=KK1
96 95 com23 M1M0MKK0¬M=KK1
97 96 ex M1M0MKK0¬M=KK1
98 67 97 jaoi M=1M1M0MKK0¬M=KK1
99 27 98 syl MM0MKK0¬M=KK1
100 13 99 sylbir M0M0M0MKK0¬M=KK1
101 100 ex M0M0M0MKK0¬M=KK1
102 101 pm2.43a M0M0MKK0¬M=KK1
103 102 com24 M0K0MKM0¬M=KK1
104 103 3imp M0K0MKM0¬M=KK1
105 104 com3l M0¬M=KM0K0MKK1
106 14 105 sylbir ¬M=0¬M=KM0K0MKK1
107 106 imp ¬M=0¬M=KM0K0MKK1
108 26 107 sylbi ¬M=0M=KM0K0MKK1
109 108 com12 M0K0MK¬M=0M=KK1
110 109 con1d M0K0MK¬K1M=0M=K
111 110 com12 ¬K1M0K0MKM=0M=K
112 30 adantr M0K0M
113 32 adantl M0K0K
114 1red M0K01
115 112 113 114 3jca M0K0MK1
116 115 3adant3 M0K0MKMK1
117 ltsub1 MK1M<KM1<K1
118 116 117 syl M0K0MKM<KM1<K1
119 118 bicomd M0K0MKM1<K1M<K
120 119 notbid M0K0MK¬M1<K1¬M<K
121 eqlelt MKM=KMK¬M<K
122 30 32 121 syl2an M0K0M=KMK¬M<K
123 122 biimpar M0K0MK¬M<KM=K
124 123 olcd M0K0MK¬M<KM=0M=K
125 124 exp43 M0K0MK¬M<KM=0M=K
126 125 3imp M0K0MK¬M<KM=0M=K
127 120 126 sylbid M0K0MK¬M1<K1M=0M=K
128 127 com12 ¬M1<K1M0K0MKM=0M=K
129 25 111 128 3jaoi ¬M10¬K1¬M1<K1M0K0MKM=0M=K
130 12 129 sylbi ¬M10K1M1<K1M0K0MKM=0M=K
131 130 com12 M0K0MK¬M10K1M1<K1M=0M=K
132 11 131 sylbid M0K0MK¬M10..^K1M=0M=K
133 8 132 sylbid M0K0MK¬M1..^KM=0M=K
134 1 133 sylbi M0K¬M1..^KM=0M=K
135 134 imp M0K¬M1..^KM=0M=K