MATLAB Combination without repetition in Matlab

Click For Summary
In MATLAB, the function to calculate combinations of k from a set of n, denoted as C(n, k), is available through the `nchoosek` function. This function serves a similar purpose to Excel's COMBIN(n, k). Users can utilize `nchoosek(n, k)` to compute the number of combinations efficiently. Additionally, there is a suggestion to explore the `combs()` function, which may also be relevant for generating combinations in MATLAB.
haiha
Messages
136
Reaction score
1
Hi all

I am just new to matlab. This question may seem very easy to most of you. But I can not find it. What is the function of combination of k from set of n: C(n,k) in mlab?. It is available in excel as COMBIN(n,k), so I think there should be one in matlab.
Thanks
 
Physics news on Phys.org

Similar threads

  • · Replies 32 ·
2
Replies
32
Views
4K
  • · Replies 9 ·
Replies
9
Views
3K
  • · Replies 22 ·
Replies
22
Views
4K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 10 ·
Replies
10
Views
4K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
Replies
3
Views
2K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 18 ·
Replies
18
Views
6K