Database
SUPPLEMENTARY MATERIAL (USERS' MATHBOXES)
Mathbox for Mario Carneiro
The Erdős-Szekeres theorem
erdszelem9
Next ⟩
erdszelem10
Metamath Proof Explorer
Ascii
Unicode
Theorem
erdszelem9
Description:
Lemma for
erdsze
.
(Contributed by
Mario Carneiro
, 22-Jan-2015)
Ref
Expression
Hypotheses
erdsze.n
⊢
φ
→
N
∈
ℕ
erdsze.f
⊢
φ
→
F
:
1
…
N
⟶
1-1
ℝ
erdszelem.i
⊢
I
=
x
∈
1
…
N
⟼
sup
.
y
∈
𝒫
1
…
x
|
F
↾
y
Isom
<
,
<
y
F
y
∧
x
∈
y
ℝ
<
erdszelem.j
⊢
J
=
x
∈
1
…
N
⟼
sup
.
y
∈
𝒫
1
…
x
|
F
↾
y
Isom
<
,
<
-1
y
F
y
∧
x
∈
y
ℝ
<
erdszelem.t
⊢
T
=
n
∈
1
…
N
⟼
I
n
J
n
Assertion
erdszelem9
⊢
φ
→
T
:
1
…
N
⟶
1-1
ℕ
×
ℕ
Proof
Step
Hyp
Ref
Expression
1
erdsze.n
⊢
φ
→
N
∈
ℕ
2
erdsze.f
⊢
φ
→
F
:
1
…
N
⟶
1-1
ℝ
3
erdszelem.i
⊢
I
=
x
∈
1
…
N
⟼
sup
.
y
∈
𝒫
1
…
x
|
F
↾
y
Isom
<
,
<
y
F
y
∧
x
∈
y
ℝ
<
4
erdszelem.j
⊢
J
=
x
∈
1
…
N
⟼
sup
.
y
∈
𝒫
1
…
x
|
F
↾
y
Isom
<
,
<
-1
y
F
y
∧
x
∈
y
ℝ
<
5
erdszelem.t
⊢
T
=
n
∈
1
…
N
⟼
I
n
J
n
6
ltso
⊢
<
Or
ℝ
7
1
2
3
6
erdszelem6
⊢
φ
→
I
:
1
…
N
⟶
ℕ
8
7
ffvelcdmda
⊢
φ
∧
n
∈
1
…
N
→
I
n
∈
ℕ
9
gtso
⊢
<
-1
Or
ℝ
10
1
2
4
9
erdszelem6
⊢
φ
→
J
:
1
…
N
⟶
ℕ
11
10
ffvelcdmda
⊢
φ
∧
n
∈
1
…
N
→
J
n
∈
ℕ
12
opelxpi
⊢
I
n
∈
ℕ
∧
J
n
∈
ℕ
→
I
n
J
n
∈
ℕ
×
ℕ
13
8
11
12
syl2anc
⊢
φ
∧
n
∈
1
…
N
→
I
n
J
n
∈
ℕ
×
ℕ
14
13
5
fmptd
⊢
φ
→
T
:
1
…
N
⟶
ℕ
×
ℕ
15
fveq2
⊢
a
=
z
→
T
a
=
T
z
16
fveq2
⊢
b
=
w
→
T
b
=
T
w
17
15
16
eqeqan12d
⊢
a
=
z
∧
b
=
w
→
T
a
=
T
b
↔
T
z
=
T
w
18
eqeq12
⊢
a
=
z
∧
b
=
w
→
a
=
b
↔
z
=
w
19
17
18
imbi12d
⊢
a
=
z
∧
b
=
w
→
T
a
=
T
b
→
a
=
b
↔
T
z
=
T
w
→
z
=
w
20
fveq2
⊢
a
=
w
→
T
a
=
T
w
21
fveq2
⊢
b
=
z
→
T
b
=
T
z
22
20
21
eqeqan12d
⊢
a
=
w
∧
b
=
z
→
T
a
=
T
b
↔
T
w
=
T
z
23
eqcom
⊢
T
w
=
T
z
↔
T
z
=
T
w
24
22
23
bitrdi
⊢
a
=
w
∧
b
=
z
→
T
a
=
T
b
↔
T
z
=
T
w
25
eqeq12
⊢
a
=
w
∧
b
=
z
→
a
=
b
↔
w
=
z
26
eqcom
⊢
w
=
z
↔
z
=
w
27
25
26
bitrdi
⊢
a
=
w
∧
b
=
z
→
a
=
b
↔
z
=
w
28
24
27
imbi12d
⊢
a
=
w
∧
b
=
z
→
T
a
=
T
b
→
a
=
b
↔
T
z
=
T
w
→
z
=
w
29
elfzelz
⊢
z
∈
1
…
N
→
z
∈
ℤ
30
29
zred
⊢
z
∈
1
…
N
→
z
∈
ℝ
31
30
ssriv
⊢
1
…
N
⊆
ℝ
32
31
a1i
⊢
φ
→
1
…
N
⊆
ℝ
33
biidd
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
→
T
z
=
T
w
→
z
=
w
↔
T
z
=
T
w
→
z
=
w
34
simpr1
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
z
∈
1
…
N
35
fveq2
⊢
n
=
z
→
I
n
=
I
z
36
fveq2
⊢
n
=
z
→
J
n
=
J
z
37
35
36
opeq12d
⊢
n
=
z
→
I
n
J
n
=
I
z
J
z
38
opex
⊢
I
z
J
z
∈
V
39
37
5
38
fvmpt
⊢
z
∈
1
…
N
→
T
z
=
I
z
J
z
40
34
39
syl
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
T
z
=
I
z
J
z
41
simpr2
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
w
∈
1
…
N
42
fveq2
⊢
n
=
w
→
I
n
=
I
w
43
fveq2
⊢
n
=
w
→
J
n
=
J
w
44
42
43
opeq12d
⊢
n
=
w
→
I
n
J
n
=
I
w
J
w
45
opex
⊢
I
w
J
w
∈
V
46
44
5
45
fvmpt
⊢
w
∈
1
…
N
→
T
w
=
I
w
J
w
47
41
46
syl
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
T
w
=
I
w
J
w
48
40
47
eqeq12d
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
T
z
=
T
w
↔
I
z
J
z
=
I
w
J
w
49
fvex
⊢
I
z
∈
V
50
fvex
⊢
J
z
∈
V
51
49
50
opth
⊢
I
z
J
z
=
I
w
J
w
↔
I
z
=
I
w
∧
J
z
=
J
w
52
34
30
syl
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
z
∈
ℝ
53
31
41
sselid
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
w
∈
ℝ
54
simpr3
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
z
≤
w
55
52
53
54
leltned
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
z
<
w
↔
w
≠
z
56
2
adantr
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
F
:
1
…
N
⟶
1-1
ℝ
57
f1fveq
⊢
F
:
1
…
N
⟶
1-1
ℝ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
→
F
z
=
F
w
↔
z
=
w
58
56
34
41
57
syl12anc
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
F
z
=
F
w
↔
z
=
w
59
58
26
bitr4di
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
F
z
=
F
w
↔
w
=
z
60
59
necon3bid
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
F
z
≠
F
w
↔
w
≠
z
61
55
60
bitr4d
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
z
<
w
↔
F
z
≠
F
w
62
61
biimpa
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
F
z
≠
F
w
63
f1f
⊢
F
:
1
…
N
⟶
1-1
ℝ
→
F
:
1
…
N
⟶
ℝ
64
2
63
syl
⊢
φ
→
F
:
1
…
N
⟶
ℝ
65
64
ad2antrr
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
F
:
1
…
N
⟶
ℝ
66
34
adantr
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
z
∈
1
…
N
67
65
66
ffvelcdmd
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
F
z
∈
ℝ
68
41
adantr
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
w
∈
1
…
N
69
65
68
ffvelcdmd
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
F
w
∈
ℝ
70
67
69
lttri2d
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
F
z
≠
F
w
↔
F
z
<
F
w
∨
F
w
<
F
z
71
62
70
mpbid
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
F
z
<
F
w
∨
F
w
<
F
z
72
1
ad2antrr
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
N
∈
ℕ
73
2
ad2antrr
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
F
:
1
…
N
⟶
1-1
ℝ
74
simpr
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
z
<
w
75
72
73
3
6
66
68
74
erdszelem8
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
I
z
=
I
w
→
¬
F
z
<
F
w
76
72
73
4
9
66
68
74
erdszelem8
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
J
z
=
J
w
→
¬
F
z
<
-1
F
w
77
75
76
anim12d
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
I
z
=
I
w
∧
J
z
=
J
w
→
¬
F
z
<
F
w
∧
¬
F
z
<
-1
F
w
78
ioran
⊢
¬
F
z
<
F
w
∨
F
w
<
F
z
↔
¬
F
z
<
F
w
∧
¬
F
w
<
F
z
79
fvex
⊢
F
z
∈
V
80
fvex
⊢
F
w
∈
V
81
79
80
brcnv
⊢
F
z
<
-1
F
w
↔
F
w
<
F
z
82
81
notbii
⊢
¬
F
z
<
-1
F
w
↔
¬
F
w
<
F
z
83
82
anbi2i
⊢
¬
F
z
<
F
w
∧
¬
F
z
<
-1
F
w
↔
¬
F
z
<
F
w
∧
¬
F
w
<
F
z
84
78
83
bitr4i
⊢
¬
F
z
<
F
w
∨
F
w
<
F
z
↔
¬
F
z
<
F
w
∧
¬
F
z
<
-1
F
w
85
77
84
syl6ibr
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
I
z
=
I
w
∧
J
z
=
J
w
→
¬
F
z
<
F
w
∨
F
w
<
F
z
86
71
85
mt2d
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
∧
z
<
w
→
¬
I
z
=
I
w
∧
J
z
=
J
w
87
86
ex
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
z
<
w
→
¬
I
z
=
I
w
∧
J
z
=
J
w
88
55
87
sylbird
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
w
≠
z
→
¬
I
z
=
I
w
∧
J
z
=
J
w
89
88
necon4ad
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
I
z
=
I
w
∧
J
z
=
J
w
→
w
=
z
90
51
89
biimtrid
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
I
z
J
z
=
I
w
J
w
→
w
=
z
91
48
90
sylbid
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
T
z
=
T
w
→
w
=
z
92
91
26
imbitrdi
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
∧
z
≤
w
→
T
z
=
T
w
→
z
=
w
93
19
28
32
33
92
wlogle
⊢
φ
∧
z
∈
1
…
N
∧
w
∈
1
…
N
→
T
z
=
T
w
→
z
=
w
94
93
ralrimivva
⊢
φ
→
∀
z
∈
1
…
N
∀
w
∈
1
…
N
T
z
=
T
w
→
z
=
w
95
dff13
⊢
T
:
1
…
N
⟶
1-1
ℕ
×
ℕ
↔
T
:
1
…
N
⟶
ℕ
×
ℕ
∧
∀
z
∈
1
…
N
∀
w
∈
1
…
N
T
z
=
T
w
→
z
=
w
96
14
94
95
sylanbrc
⊢
φ
→
T
:
1
…
N
⟶
1-1
ℕ
×
ℕ