how to set anti diagonal part of matrix with zero value elements ?
4 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
ajeet verma
le 8 Mar 2017
Commenté : Walter Roberson
le 9 Mar 2017
i know that how to set diagonal part of matrix to zero, for that we have a code m=256; n=256; a=ones(m,n); u=triu(a); imshow(u);
but in case of anti diagonal what will be code?
0 commentaires
Réponse acceptée
Nicolai Sanders
le 8 Mar 2017
I think this might do what you need.
m=256; n=256; a=ones(m,n); u=flip(triu(a)); imshow(u);
2 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Get Started with MATLAB dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!