how to count row and column of a matrix
Mostrar comentarios más antiguos
if i have a big matrix and i don't know its size, how to find out its size? and how to save it as variable?
Respuesta aceptada
Más respuestas (2)
Md. Kawsar Ahmed Asif
el 13 de Dic. de 2017
Editada: Md. Kawsar Ahmed Asif
el 13 de Dic. de 2017
0 votos
[rownum,colnum]=size(A)
Where 'A' is a mxn matrix.
Anurag Pratap Singh
el 25 de Jun. de 2020
0 votos
Hii Eri
To know the size of a matrix you can use the size function and pass your matrix in it
[NumRows NumCols]=size(your_matrix);
The first output is the Number of rows and second the number of columns
Thank you
Categorías
Más información sobre Matrix Indexing 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!