How to efficiently create a matrix of random numbers generating independently?
1 次查看(过去 30 天)
显示 更早的评论
Hi,
I want to have a 100-by-2000 matrix of random numbers. Each column of random numbers is generated by an independent stream. It means there should be 2000 independent streams.
I learn from "Help: Create three independent streams"
[s1,s2,s3] = RandStream.create('mrg32k3a','NumStreams',3);
r1 = rand(s1,100000,1); r2 = rand(s2,100000,1); r3 = rand(s3,100000,1);
It is very easy with 3 independent streams.
How can I efficiently create this matrix of random numbers from 2000 independent streams?
Thank you!
3 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Random Number Generation 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!