Binomial Coefficient Calculator
Calculate binomial coefficients C(n, k) with exact BigInt precision. Supports Pascal's triangle visualization, properties, and history.
About
The binomial coefficient C(n, k) counts the number of ways to choose k elements from a set of n without regard to order. It appears in probability distributions, polynomial expansions, and error-correcting codes. A miscalculated coefficient propagates through every downstream formula that depends on it. This tool computes exact results using native arbitrary-precision arithmetic, eliminating the floating-point truncation that plagues spreadsheet implementations for n > 66. It assumes n and k are non-negative integers with k โค n.
The multiplicative formula is used instead of the factorial definition to avoid intermediate overflow. The tool exploits the symmetry property C(n, k) = C(n, n โ k) to minimize the number of multiplications. Pro tip: for very large n, verify your result against Kummer's theorem for carry counting in base-p arithmetic when you need the coefficient modulo a prime.
Formulas
The binomial coefficient is defined as the ratio of factorials. The factorial definition is:
This tool uses the numerically stable multiplicative form to avoid computing large intermediate factorials:
Key identities used internally:
Where n = total number of elements in the set, k = number of elements chosen, i = iteration index in the product, and C(n, k) = the number of k-combinations from n elements.
Reference Data
| n | C(n,0) | C(n,1) | C(n,2) | C(n,3) | C(n,4) | C(n,5) | C(n,6) | C(n,7) | C(n,8) | C(n,9) | C(n,10) |
|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | 1 | ||||||||||
| 1 | 1 | 1 | |||||||||
| 2 | 1 | 2 | 1 | ||||||||
| 3 | 1 | 3 | 3 | 1 | |||||||
| 4 | 1 | 4 | 6 | 4 | 1 | ||||||
| 5 | 1 | 5 | 10 | 10 | 5 | 1 | |||||
| 6 | 1 | 6 | 15 | 20 | 15 | 6 | 1 | ||||
| 7 | 1 | 7 | 21 | 35 | 35 | 21 | 7 | 1 | |||
| 8 | 1 | 8 | 28 | 56 | 70 | 56 | 28 | 8 | 1 | ||
| 9 | 1 | 9 | 36 | 84 | 126 | 126 | 84 | 36 | 9 | 1 | |
| 10 | 1 | 10 | 45 | 120 | 210 | 252 | 210 | 120 | 45 | 10 | 1 |
| 12 | 1 | 12 | 66 | 220 | 495 | 792 | 924 | 792 | 495 | 220 | 66 |
| 15 | 1 | 15 | 105 | 455 | 1365 | 3003 | 5005 | 6435 | 6435 | 5005 | 3003 |
| 20 | 1 | 20 | 190 | 1140 | 4845 | 15504 | 38760 | 77520 | 125970 | 167960 | 184756 |
| 25 | 1 | 25 | 300 | 2300 | 12650 | 53130 | 177100 | 480700 | 1081575 | 2042975 | 3268760 |
| 30 | 1 | 30 | 435 | 4060 | 27405 | 142506 | 593775 | 2035800 | 5852925 | 14307150 | 30045015 |
| 40 | 1 | 40 | 780 | 9880 | 91390 | 658008 | 3838380 | 18643560 | 76904685 | 273438880 | 847660528 |
| 50 | 1 | 50 | 1225 | 19600 | 230300 | 2118760 | 15890700 | 99884400 | 536878650 | 2505433700 | 10272278170 |
| 100 | 1 | 100 | 4950 | 161700 | 3921225 | 75287520 | 1192052400 | 16007560800 | 186087894300 | 1902231808400 | 17310309456440 |