How could i write matlab code for Sequencing of machining operation using for loop?
Mostrar comentarios más antiguos
How could i get these 16 possibl combinations using matlab code?

2 comentarios
Darshan Ramakant Bhat
el 30 de Dic. de 2019
You should put more context to this question. It is hard to understand what you are trying to do from the question
Usman Ahmed
el 30 de Dic. de 2019
Respuestas (1)
KALYAN ACHARJYA
el 30 de Dic. de 2019
I have reached this label, do apply more logic and get the exact result, it can be possible, but here code is little non efficient. If you manage any efficient way, it would be recomended.
count=1;j=1;
for i=1:6
while count<=8
data{count,i}=['Seq',num2str(i),num2str(j)];
count=count+1;
end
while count<=16
data{count,i}=['Seq',num2str(i),num2str(j+1)];
count=count+1;
end
count=1;
end
data
Result:
'Seq11' 'Seq21' 'Seq31' 'Seq41' 'Seq51' 'Seq61'
'Seq11' 'Seq21' 'Seq31' 'Seq41' 'Seq51' 'Seq61'
'Seq11' 'Seq21' 'Seq31' 'Seq41' 'Seq51' 'Seq61'
'Seq11' 'Seq21' 'Seq31' 'Seq41' 'Seq51' 'Seq61'
'Seq11' 'Seq21' 'Seq31' 'Seq41' 'Seq51' 'Seq61'
'Seq11' 'Seq21' 'Seq31' 'Seq41' 'Seq51' 'Seq61'
'Seq11' 'Seq21' 'Seq31' 'Seq41' 'Seq51' 'Seq61'
'Seq11' 'Seq21' 'Seq31' 'Seq41' 'Seq51' 'Seq61'
'Seq12' 'Seq22' 'Seq32' 'Seq42' 'Seq52' 'Seq62'
'Seq12' 'Seq22' 'Seq32' 'Seq42' 'Seq52' 'Seq62'
'Seq12' 'Seq22' 'Seq32' 'Seq42' 'Seq52' 'Seq62'
'Seq12' 'Seq22' 'Seq32' 'Seq42' 'Seq52' 'Seq62'
'Seq12' 'Seq22' 'Seq32' 'Seq42' 'Seq52' 'Seq62'
'Seq12' 'Seq22' 'Seq32' 'Seq42' 'Seq52' 'Seq62'
'Seq12' 'Seq22' 'Seq32' 'Seq42' 'Seq52' 'Seq62'
'Seq12' 'Seq22' 'Seq32' 'Seq42' 'Seq52' 'Seq62'
Categorías
Más información sobre Loops and Conditional Statements en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!