Info
이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.
How to find all possible combinations of 3 nos chosen from 3 different sets??
조회 수: 1 (최근 30일)
이전 댓글 표시
How to find all possible combinations of 3 numbers taking 1 from each set defined below C=1:1:100 D=1:1:150 E=1:1:125 Which means I want to make matrix of the order [(100C1 * 150C1*125C1)cross3] with all possible combinations
nchoosek(N,K) is not workin for multiple sets of nos..
댓글 수: 0
답변 (1개)
Iman Ansari
2013년 5월 1일
Hi.
C=1:1:100;
D=1:1:150;
E=1:1:125;
[x,y,z]=meshgrid(C,D,E);
A=[y(:) x(:) z(:)];
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!