MATLAB: How to generate a random number in matlab basicMATLAB How to generate a random number in matlab? Best Answer This is shown in the documentation: doc rand , especially: floating-point-numbers-within-specific-rangea = 0.01;b = 50;r = (b-a) * rand + a;Reading the documentation is a very efficient way to solve such questions. The docs of Matlab are excellent. Related SolutionsMATLAB: What algorithm is matlab using to create randn numbers https://www.mathworks.com/matlabcentral/answers/97811-what-is-the-algorithm-used-by-the-normally-distributed-pseudorandom-number-generator-randn-in-matlab MATLAB: Random numbers help randdoc rand Related QuestionGenerating random integer from -x to xMatrix operation
Best Answer