Metamath Proof Explorer


Theorem plyco0

Description: Two ways to say that a function on the nonnegative integers has finite support. (Contributed by Mario Carneiro, 22-Jul-2014)

Ref Expression
Assertion plyco0 N 0 A : 0 A N + 1 = 0 k 0 A k 0 k N

Proof

Step Hyp Ref Expression
1 simprr N 0 A : 0 A N + 1 = 0 k 0 A k 0 A k 0
2 ffun A : 0 Fun A
3 2 adantl N 0 A : 0 Fun A
4 peano2nn0 N 0 N + 1 0
5 4 adantr N 0 A : 0 N + 1 0
6 eluznn0 N + 1 0 k N + 1 k 0
7 6 ex N + 1 0 k N + 1 k 0
8 5 7 syl N 0 A : 0 k N + 1 k 0
9 8 ssrdv N 0 A : 0 N + 1 0
10 fdm A : 0 dom A = 0
11 10 adantl N 0 A : 0 dom A = 0
12 9 11 sseqtrrd N 0 A : 0 N + 1 dom A
13 funfvima2 Fun A N + 1 dom A k N + 1 A k A N + 1
14 3 12 13 syl2anc N 0 A : 0 k N + 1 A k A N + 1
15 14 ad2antrr N 0 A : 0 A N + 1 = 0 k 0 A k 0 k N + 1 A k A N + 1
16 nn0z N 0 N
17 16 adantr N 0 A : 0 N
18 17 peano2zd N 0 A : 0 N + 1
19 18 ad2antrr N 0 A : 0 A N + 1 = 0 k 0 A k 0 N + 1
20 nn0z k 0 k
21 20 ad2antrl N 0 A : 0 A N + 1 = 0 k 0 A k 0 k
22 eluz N + 1 k k N + 1 N + 1 k
23 19 21 22 syl2anc N 0 A : 0 A N + 1 = 0 k 0 A k 0 k N + 1 N + 1 k
24 simplr N 0 A : 0 A N + 1 = 0 k 0 A k 0 A N + 1 = 0
25 24 eleq2d N 0 A : 0 A N + 1 = 0 k 0 A k 0 A k A N + 1 A k 0
26 fvex A k V
27 26 elsn A k 0 A k = 0
28 25 27 bitrdi N 0 A : 0 A N + 1 = 0 k 0 A k 0 A k A N + 1 A k = 0
29 15 23 28 3imtr3d N 0 A : 0 A N + 1 = 0 k 0 A k 0 N + 1 k A k = 0
30 29 necon3ad N 0 A : 0 A N + 1 = 0 k 0 A k 0 A k 0 ¬ N + 1 k
31 1 30 mpd N 0 A : 0 A N + 1 = 0 k 0 A k 0 ¬ N + 1 k
32 nn0re k 0 k
33 32 ad2antrl N 0 A : 0 A N + 1 = 0 k 0 A k 0 k
34 18 zred N 0 A : 0 N + 1
35 34 ad2antrr N 0 A : 0 A N + 1 = 0 k 0 A k 0 N + 1
36 33 35 ltnled N 0 A : 0 A N + 1 = 0 k 0 A k 0 k < N + 1 ¬ N + 1 k
37 31 36 mpbird N 0 A : 0 A N + 1 = 0 k 0 A k 0 k < N + 1
38 17 ad2antrr N 0 A : 0 A N + 1 = 0 k 0 A k 0 N
39 zleltp1 k N k N k < N + 1
40 21 38 39 syl2anc N 0 A : 0 A N + 1 = 0 k 0 A k 0 k N k < N + 1
41 37 40 mpbird N 0 A : 0 A N + 1 = 0 k 0 A k 0 k N
42 41 expr N 0 A : 0 A N + 1 = 0 k 0 A k 0 k N
43 42 ralrimiva N 0 A : 0 A N + 1 = 0 k 0 A k 0 k N
44 simpr k 0 A k 0 k N n N + 1 n N + 1
45 eluznn0 N + 1 0 n N + 1 n 0
46 5 44 45 syl2an N 0 A : 0 k 0 A k 0 k N n N + 1 n 0
47 nn0re N 0 N
48 47 adantr N 0 A : 0 N
49 48 adantr N 0 A : 0 k 0 A k 0 k N n N + 1 N
50 34 adantr N 0 A : 0 k 0 A k 0 k N n N + 1 N + 1
51 46 nn0red N 0 A : 0 k 0 A k 0 k N n N + 1 n
52 49 ltp1d N 0 A : 0 k 0 A k 0 k N n N + 1 N < N + 1
53 eluzle n N + 1 N + 1 n
54 53 ad2antll N 0 A : 0 k 0 A k 0 k N n N + 1 N + 1 n
55 49 50 51 52 54 ltletrd N 0 A : 0 k 0 A k 0 k N n N + 1 N < n
56 49 51 ltnled N 0 A : 0 k 0 A k 0 k N n N + 1 N < n ¬ n N
57 55 56 mpbid N 0 A : 0 k 0 A k 0 k N n N + 1 ¬ n N
58 fveq2 k = n A k = A n
59 58 neeq1d k = n A k 0 A n 0
60 breq1 k = n k N n N
61 59 60 imbi12d k = n A k 0 k N A n 0 n N
62 simprl N 0 A : 0 k 0 A k 0 k N n N + 1 k 0 A k 0 k N
63 61 62 46 rspcdva N 0 A : 0 k 0 A k 0 k N n N + 1 A n 0 n N
64 63 necon1bd N 0 A : 0 k 0 A k 0 k N n N + 1 ¬ n N A n = 0
65 57 64 mpd N 0 A : 0 k 0 A k 0 k N n N + 1 A n = 0
66 ffn A : 0 A Fn 0
67 66 ad2antlr N 0 A : 0 k 0 A k 0 k N n N + 1 A Fn 0
68 fniniseg A Fn 0 n A -1 0 n 0 A n = 0
69 67 68 syl N 0 A : 0 k 0 A k 0 k N n N + 1 n A -1 0 n 0 A n = 0
70 46 65 69 mpbir2and N 0 A : 0 k 0 A k 0 k N n N + 1 n A -1 0
71 70 expr N 0 A : 0 k 0 A k 0 k N n N + 1 n A -1 0
72 71 ssrdv N 0 A : 0 k 0 A k 0 k N N + 1 A -1 0
73 funimass3 Fun A N + 1 dom A A N + 1 0 N + 1 A -1 0
74 3 12 73 syl2anc N 0 A : 0 A N + 1 0 N + 1 A -1 0
75 74 adantr N 0 A : 0 k 0 A k 0 k N A N + 1 0 N + 1 A -1 0
76 72 75 mpbird N 0 A : 0 k 0 A k 0 k N A N + 1 0
77 48 ltp1d N 0 A : 0 N < N + 1
78 48 34 ltnled N 0 A : 0 N < N + 1 ¬ N + 1 N
79 77 78 mpbid N 0 A : 0 ¬ N + 1 N
80 79 adantr N 0 A : 0 k 0 A k 0 k N ¬ N + 1 N
81 fveq2 k = N + 1 A k = A N + 1
82 81 neeq1d k = N + 1 A k 0 A N + 1 0
83 breq1 k = N + 1 k N N + 1 N
84 82 83 imbi12d k = N + 1 A k 0 k N A N + 1 0 N + 1 N
85 84 rspcva N + 1 0 k 0 A k 0 k N A N + 1 0 N + 1 N
86 5 85 sylan N 0 A : 0 k 0 A k 0 k N A N + 1 0 N + 1 N
87 86 necon1bd N 0 A : 0 k 0 A k 0 k N ¬ N + 1 N A N + 1 = 0
88 80 87 mpd N 0 A : 0 k 0 A k 0 k N A N + 1 = 0
89 uzid N + 1 N + 1 N + 1
90 18 89 syl N 0 A : 0 N + 1 N + 1
91 funfvima2 Fun A N + 1 dom A N + 1 N + 1 A N + 1 A N + 1
92 3 12 91 syl2anc N 0 A : 0 N + 1 N + 1 A N + 1 A N + 1
93 90 92 mpd N 0 A : 0 A N + 1 A N + 1
94 93 adantr N 0 A : 0 k 0 A k 0 k N A N + 1 A N + 1
95 88 94 eqeltrrd N 0 A : 0 k 0 A k 0 k N 0 A N + 1
96 95 snssd N 0 A : 0 k 0 A k 0 k N 0 A N + 1
97 76 96 eqssd N 0 A : 0 k 0 A k 0 k N A N + 1 = 0
98 43 97 impbida N 0 A : 0 A N + 1 = 0 k 0 A k 0 k N