Metamath Proof Explorer


Theorem seqid2

Description: The last few partial sums of a sequence that ends with all zeroes (or any element which is a right-identity for .+ ) are all the same. (Contributed by Mario Carneiro, 13-Jul-2013) (Revised by Mario Carneiro, 27-May-2014)

Ref Expression
Hypotheses seqid2.1 φ x S x + ˙ Z = x
seqid2.2 φ K M
seqid2.3 φ N K
seqid2.4 φ seq M + ˙ F K S
seqid2.5 φ x K + 1 N F x = Z
Assertion seqid2 φ seq M + ˙ F K = seq M + ˙ F N

Proof

Step Hyp Ref Expression
1 seqid2.1 φ x S x + ˙ Z = x
2 seqid2.2 φ K M
3 seqid2.3 φ N K
4 seqid2.4 φ seq M + ˙ F K S
5 seqid2.5 φ x K + 1 N F x = Z
6 eluzfz2 N K N K N
7 3 6 syl φ N K N
8 eleq1 x = K x K N K K N
9 fveq2 x = K seq M + ˙ F x = seq M + ˙ F K
10 9 eqeq2d x = K seq M + ˙ F K = seq M + ˙ F x seq M + ˙ F K = seq M + ˙ F K
11 8 10 imbi12d x = K x K N seq M + ˙ F K = seq M + ˙ F x K K N seq M + ˙ F K = seq M + ˙ F K
12 11 imbi2d x = K φ x K N seq M + ˙ F K = seq M + ˙ F x φ K K N seq M + ˙ F K = seq M + ˙ F K
13 eleq1 x = n x K N n K N
14 fveq2 x = n seq M + ˙ F x = seq M + ˙ F n
15 14 eqeq2d x = n seq M + ˙ F K = seq M + ˙ F x seq M + ˙ F K = seq M + ˙ F n
16 13 15 imbi12d x = n x K N seq M + ˙ F K = seq M + ˙ F x n K N seq M + ˙ F K = seq M + ˙ F n
17 16 imbi2d x = n φ x K N seq M + ˙ F K = seq M + ˙ F x φ n K N seq M + ˙ F K = seq M + ˙ F n
18 eleq1 x = n + 1 x K N n + 1 K N
19 fveq2 x = n + 1 seq M + ˙ F x = seq M + ˙ F n + 1
20 19 eqeq2d x = n + 1 seq M + ˙ F K = seq M + ˙ F x seq M + ˙ F K = seq M + ˙ F n + 1
21 18 20 imbi12d x = n + 1 x K N seq M + ˙ F K = seq M + ˙ F x n + 1 K N seq M + ˙ F K = seq M + ˙ F n + 1
22 21 imbi2d x = n + 1 φ x K N seq M + ˙ F K = seq M + ˙ F x φ n + 1 K N seq M + ˙ F K = seq M + ˙ F n + 1
23 eleq1 x = N x K N N K N
24 fveq2 x = N seq M + ˙ F x = seq M + ˙ F N
25 24 eqeq2d x = N seq M + ˙ F K = seq M + ˙ F x seq M + ˙ F K = seq M + ˙ F N
26 23 25 imbi12d x = N x K N seq M + ˙ F K = seq M + ˙ F x N K N seq M + ˙ F K = seq M + ˙ F N
27 26 imbi2d x = N φ x K N seq M + ˙ F K = seq M + ˙ F x φ N K N seq M + ˙ F K = seq M + ˙ F N
28 eqidd K K N seq M + ˙ F K = seq M + ˙ F K
29 28 2a1i K φ K K N seq M + ˙ F K = seq M + ˙ F K
30 peano2fzr n K n + 1 K N n K N
31 30 adantl φ n K n + 1 K N n K N
32 31 expr φ n K n + 1 K N n K N
33 32 imim1d φ n K n K N seq M + ˙ F K = seq M + ˙ F n n + 1 K N seq M + ˙ F K = seq M + ˙ F n
34 oveq1 seq M + ˙ F K = seq M + ˙ F n seq M + ˙ F K + ˙ F n + 1 = seq M + ˙ F n + ˙ F n + 1
35 fveqeq2 x = n + 1 F x = Z F n + 1 = Z
36 5 ralrimiva φ x K + 1 N F x = Z
37 36 adantr φ n K n + 1 K N x K + 1 N F x = Z
38 eluzp1p1 n K n + 1 K + 1
39 38 ad2antrl φ n K n + 1 K N n + 1 K + 1
40 elfzuz3 n + 1 K N N n + 1
41 40 ad2antll φ n K n + 1 K N N n + 1
42 elfzuzb n + 1 K + 1 N n + 1 K + 1 N n + 1
43 39 41 42 sylanbrc φ n K n + 1 K N n + 1 K + 1 N
44 35 37 43 rspcdva φ n K n + 1 K N F n + 1 = Z
45 44 oveq2d φ n K n + 1 K N seq M + ˙ F K + ˙ F n + 1 = seq M + ˙ F K + ˙ Z
46 oveq1 x = seq M + ˙ F K x + ˙ Z = seq M + ˙ F K + ˙ Z
47 id x = seq M + ˙ F K x = seq M + ˙ F K
48 46 47 eqeq12d x = seq M + ˙ F K x + ˙ Z = x seq M + ˙ F K + ˙ Z = seq M + ˙ F K
49 1 ralrimiva φ x S x + ˙ Z = x
50 48 49 4 rspcdva φ seq M + ˙ F K + ˙ Z = seq M + ˙ F K
51 50 adantr φ n K n + 1 K N seq M + ˙ F K + ˙ Z = seq M + ˙ F K
52 45 51 eqtr2d φ n K n + 1 K N seq M + ˙ F K = seq M + ˙ F K + ˙ F n + 1
53 simprl φ n K n + 1 K N n K
54 2 adantr φ n K n + 1 K N K M
55 uztrn n K K M n M
56 53 54 55 syl2anc φ n K n + 1 K N n M
57 seqp1 n M seq M + ˙ F n + 1 = seq M + ˙ F n + ˙ F n + 1
58 56 57 syl φ n K n + 1 K N seq M + ˙ F n + 1 = seq M + ˙ F n + ˙ F n + 1
59 52 58 eqeq12d φ n K n + 1 K N seq M + ˙ F K = seq M + ˙ F n + 1 seq M + ˙ F K + ˙ F n + 1 = seq M + ˙ F n + ˙ F n + 1
60 34 59 syl5ibr φ n K n + 1 K N seq M + ˙ F K = seq M + ˙ F n seq M + ˙ F K = seq M + ˙ F n + 1
61 33 60 animpimp2impd n K φ n K N seq M + ˙ F K = seq M + ˙ F n φ n + 1 K N seq M + ˙ F K = seq M + ˙ F n + 1
62 12 17 22 27 29 61 uzind4 N K φ N K N seq M + ˙ F K = seq M + ˙ F N
63 3 62 mpcom φ N K N seq M + ˙ F K = seq M + ˙ F N
64 7 63 mpd φ seq M + ˙ F K = seq M + ˙ F N