I need help with matrix problem!

Hello guys.I am new to matlab.How can i make matrix(7x7) ,main diagonal all zeros, other elements 1?

 Respuesta aceptada

Stephen23
Stephen23 el 10 de Mzo. de 2016
Editada: Stephen23 el 10 de Mzo. de 2016
>> +~eye(7)
ans =
0 1 1 1 1 1 1
1 0 1 1 1 1 1
1 1 0 1 1 1 1
1 1 1 0 1 1 1
1 1 1 1 0 1 1
1 1 1 1 1 0 1
1 1 1 1 1 1 0

Más respuestas (0)

Categorías

Más información sobre Operators and Elementary Operations en Centro de ayuda y File Exchange.

Etiquetas

Preguntada:

el 10 de Mzo. de 2016

Comentada:

el 10 de Mzo. de 2016

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by