how to create a square matrix with unique real values?
3 次查看(过去 30 天)
显示 更早的评论
Hello, I want a random square matrix of size 10*10, where each row must contain random values from 1 to 10...
0 个评论
更多回答(1 个)
Jos (10584)
2018-2-21
编辑:Jos (10584)
2018-2-21
A very simple one-liner will do the trick:
N = 10 ;
[~, A] = sort(rand(N), 2)
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Creating and Concatenating Matrices 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!