how to flatten a matrix in row major order
1 072 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
hi , how do i flatten a matrix in row major order. thanks.
0 commentaires
Réponse acceptée
Plus de réponses (1)
Zhendong Zhao
le 16 Août 2015
B=A'; B(:)'
1 commentaire
Walter Roberson
le 16 Août 2015
Using ' instead of .' makes extra work because ' is conjugate transpose. Your code does the conjugate transpose twice so you do end up with the original values, but it is work that doesn't have to be done.
Voir également
Catégories
En savoir plus sur Multidimensional Arrays 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!