Metamath Proof Explorer


Theorem fprodm1

Description: Separate out the last term in a finite product. (Contributed by Scott Fenton, 16-Dec-2017)

Ref Expression
Hypotheses fprodm1.1 φ N M
fprodm1.2 φ k M N A
fprodm1.3 k = N A = B
Assertion fprodm1 φ k = M N A = k = M N 1 A B

Proof

Step Hyp Ref Expression
1 fprodm1.1 φ N M
2 fprodm1.2 φ k M N A
3 fprodm1.3 k = N A = B
4 fzp1nel ¬ N - 1 + 1 M N 1
5 eluzelz N M N
6 1 5 syl φ N
7 6 zcnd φ N
8 1cnd φ 1
9 7 8 npcand φ N - 1 + 1 = N
10 9 eleq1d φ N - 1 + 1 M N 1 N M N 1
11 4 10 mtbii φ ¬ N M N 1
12 disjsn M N 1 N = ¬ N M N 1
13 11 12 sylibr φ M N 1 N =
14 eluzel2 N M M
15 1 14 syl φ M
16 peano2zm M M 1
17 15 16 syl φ M 1
18 15 zcnd φ M
19 18 8 npcand φ M - 1 + 1 = M
20 19 fveq2d φ M - 1 + 1 = M
21 1 20 eleqtrrd φ N M - 1 + 1
22 eluzp1m1 M 1 N M - 1 + 1 N 1 M 1
23 17 21 22 syl2anc φ N 1 M 1
24 fzsuc2 M N 1 M 1 M N - 1 + 1 = M N 1 N - 1 + 1
25 15 23 24 syl2anc φ M N - 1 + 1 = M N 1 N - 1 + 1
26 9 oveq2d φ M N - 1 + 1 = M N
27 9 sneqd φ N - 1 + 1 = N
28 27 uneq2d φ M N 1 N - 1 + 1 = M N 1 N
29 25 26 28 3eqtr3d φ M N = M N 1 N
30 fzfid φ M N Fin
31 13 29 30 2 fprodsplit φ k = M N A = k = M N 1 A k N A
32 3 eleq1d k = N A B
33 2 ralrimiva φ k M N A
34 eluzfz2 N M N M N
35 1 34 syl φ N M N
36 32 33 35 rspcdva φ B
37 3 prodsn N M B k N A = B
38 1 36 37 syl2anc φ k N A = B
39 38 oveq2d φ k = M N 1 A k N A = k = M N 1 A B
40 31 39 eqtrd φ k = M N A = k = M N 1 A B