Metamath Proof Explorer


Theorem bccbc

Description: The binomial coefficient and generalized binomial coefficient are equal when their arguments are nonnegative integers. (Contributed by Steve Rodriguez, 22-Apr-2020)

Ref Expression
Hypotheses bccbc.c φ N 0
bccbc.k φ K 0
Assertion bccbc φ N C 𝑐 K = ( N K)

Proof

Step Hyp Ref Expression
1 bccbc.c φ N 0
2 bccbc.k φ K 0
3 1 nn0cnd φ N
4 3 2 bccval φ N C 𝑐 K = N K _ K !
5 4 adantr φ K 0 N N C 𝑐 K = N K _ K !
6 bcfallfac K 0 N ( N K) = N K _ K !
7 6 adantl φ K 0 N ( N K) = N K _ K !
8 5 7 eqtr4d φ K 0 N N C 𝑐 K = ( N K)
9 nn0split N 0 0 = 0 N N + 1
10 1 9 syl φ 0 = 0 N N + 1
11 2 10 eleqtrd φ K 0 N N + 1
12 elun K 0 N N + 1 K 0 N K N + 1
13 11 12 sylib φ K 0 N K N + 1
14 13 orcanai φ ¬ K 0 N K N + 1
15 eluzle K N + 1 N + 1 K
16 15 adantl φ K N + 1 N + 1 K
17 1 nn0zd φ N
18 2 nn0zd φ K
19 zltp1le N K N < K N + 1 K
20 17 18 19 syl2anc φ N < K N + 1 K
21 20 adantr φ K N + 1 N < K N + 1 K
22 16 21 mpbird φ K N + 1 N < K
23 14 22 syldan φ ¬ K 0 N N < K
24 1 nn0ge0d φ 0 N
25 0zd φ 0
26 elfzo N 0 K N 0 ..^ K 0 N N < K
27 17 25 18 26 syl3anc φ N 0 ..^ K 0 N N < K
28 27 biimpar φ 0 N N < K N 0 ..^ K
29 fzoval K 0 ..^ K = 0 K 1
30 18 29 syl φ 0 ..^ K = 0 K 1
31 30 eleq2d φ N 0 ..^ K N 0 K 1
32 31 biimpa φ N 0 ..^ K N 0 K 1
33 3 2 bcc0 φ N C 𝑐 K = 0 N 0 K 1
34 33 biimpar φ N 0 K 1 N C 𝑐 K = 0
35 32 34 syldan φ N 0 ..^ K N C 𝑐 K = 0
36 28 35 syldan φ 0 N N < K N C 𝑐 K = 0
37 24 36 sylanr1 φ φ N < K N C 𝑐 K = 0
38 37 anabss5 φ N < K N C 𝑐 K = 0
39 23 38 syldan φ ¬ K 0 N N C 𝑐 K = 0
40 1 18 jca φ N 0 K
41 bcval3 N 0 K ¬ K 0 N ( N K) = 0
42 41 3expa N 0 K ¬ K 0 N ( N K) = 0
43 40 42 sylan φ ¬ K 0 N ( N K) = 0
44 39 43 eqtr4d φ ¬ K 0 N N C 𝑐 K = ( N K)
45 8 44 pm2.61dan φ N C 𝑐 K = ( N K)