Generate random matrix ‘r’ of size 3 by 4 with number varying between -4 and 6

1 次查看(过去 30 天)
Q

采纳的回答

KSSV
KSSV 2016-10-1
a = -4;
b = 6;
r = (b-a).*rand(3,4) + a;

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Random Number Generation 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by