Restricted Partition Calculator
Enter an integer n and the number of parts k to count the partitions.
Result
How to use
- Enter your values in the fields above.
- Press Calculate to see your result instantly.
- Use the Share button to copy a link to your result.
About this calculator
p(n,k) counts the number of ways to write a positive integer n as a sum of exactly k positive parts, ignoring order. It's computed with the classic recurrence p(n,k) = p(n−1,k−1) + p(n−k,k), which splits on whether the smallest part equals 1 or every part can be reduced by 1.
This restricted count is a building block for the broader partition function p(n) and for generating-function techniques in number theory and combinatorics. It's used by math students, competitive programmers, and researchers working on integer partition problems, where counting the ways a number breaks into pieces of a fixed count comes up constantly.
Was this helpful?
Popular calculators
Loan Calculator
Monthly payment, total interest and full amortization schedule.
Percentage Calculator
Percent change, percent of, and ratio calculations.
Discount Calculator
Calculate final price, savings, and discount amount.
BMI Calculator
Body mass index from height and weight (metric or imperial).
Age Calculator
Compute your exact age in years, months and days from a birth date.
Compound Interest Calculator
Calculate the final amount and interest earned with compounding.
All Calculators
No calculators found
Comments (0)