Re-generate random matrix
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Fahd Alqahtani
il 12 Apr 2018
Commentato: Fahd Alqahtani
il 12 Apr 2018
Hi
I have a matrix A (9X9) and I want to generate a new matrix B using the same matrix of A and should be distributed randomly and each number should be used once to generate matrix B.
0 Commenti
Risposta accettata
David Fletcher
il 12 Apr 2018
Modificato: David Fletcher
il 12 Apr 2018
ind=randperm(81)
B=reshape(A(ind),9,9)
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Random Number Generation in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!