binomial.m

This program computes the binomial coefficient C(n,m).

You are now following this Submission

Given nonnegative integers m and n with m <= n, this program computes the binomial coefficient C(n,m). It's about time someone wrote code to do this! I couldn't find it anywhere.

Cite As

David Terr (2026). binomial.m (https://www.mathworks.com/matlabcentral/fileexchange/4901-binomial-m), MATLAB Central File Exchange. Retrieved .

General Information

MATLAB Release Compatibility

  • Compatible with any release

Platform Compatibility

  • Windows
  • macOS
  • Linux
Version Published Release Notes Action
1.0.0.0

Greg von Winckel sent me another version, which although not as accurate is much faster for large input, so I use his version when n>100.