How to generate random numbers?
1 回表示 (過去 30 日間)
古いコメントを表示
I wan random number in the range of 10 to 50 but with two decimals of size 1X5
Eg:[10 10.25 13 14.25 45.63] It may be any random numbers
0 件のコメント
回答 (1 件)
Azzi Abdelmalek
2016 年 5 月 6 日
編集済み: Azzi Abdelmalek
2016 年 5 月 6 日
l1=10;
l2=50;
out=l1+(l2-l1)*rand(1,5);
out=round(out*100)/100
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!