how can i add 2 row
6 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
A=[-1,-1,0,0,0;0,0,0,-1,0;0,1,-1,0,-1;0,0,1,0,0;1,0,0,1,1]
With that matrix how can i add row to row command (code)
And in any kind of matrix?
0 comentarios
Respuesta aceptada
Walter Roberson
el 6 de Jun. de 2013
A(FirstRow,:) + A(SecondRow,:)
Or if you want to get fancier,
sum(A([FirstRow, SecondRow],:))
Más respuestas (0)
Ver también
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!