How can i make function 'rand' in matlab?

Hello i'm Korean student. I want to make 'rand' function(random number generation). I can't find it's code in google search. Pleas answer to me, what is this code? I LOVE MATLAB! good bye.

回答 (2 件)

John D'Errico
John D'Errico 2016 年 3 月 23 日
編集済み: John D'Errico 2016 年 3 月 23 日

0 投票

The code for rand is NOT available to you (or to anyone else.) Unless of course, you can manage to get a job offer at the MathWorks.
Nothing stops you from researching the ideas behind pseudo-random number generation tools like rand. They have come a long way over the years though, through much diligent research. Don't just use the first simple congruential random number generator and expect good results.
Walter Roberson
Walter Roberson 2016 年 3 月 23 日

0 投票

If you look at http://www.mathworks.com/help/matlab/math/creating-and-controlling-a-random-number-stream.html then it has references to all of the supported random number generators.

カテゴリ

ヘルプ センター および File ExchangeLoops and Conditional Statements についてさらに検索

質問済み:

2016 年 3 月 23 日

回答済み:

2016 年 3 月 23 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by