how to get the first position in the array and get size array contains matrices
2 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Dear all,
I have a problem and I hope somebody can help.
I want to get the first index in the array, the array contains matrices and I want to get the first matrix, then I will do a loop start from the second matrix to the last matrix.
and I want to get size, I use "size" function but it returns " 4 2", how can I use the first number
note: assume array come form parameter of the function and it's hidden I don't know what array contain and the size of the array is unknown
example of the array :
m1=[ 0 1; 0 0];
m2=[ 0 1; 0 1];
m3=[ 1 1; 0 0];
m4=[ 1 1; 0 1];
array=[m1 m2 m3 m4];
index1=array(1);%not working
I hope I am clear enough.
Thanks in advance,
Ghaida
0 Commenti
Vedere anche
Categorie
Scopri di più su Creating and Concatenating Matrices in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!