Creating Matrix between two values

How can I creating 2x6 matrix using matrix operations? Elements of the matrix will be random numbers between 10 and 90.

回答 (1 件)

Mohammad Sami
Mohammad Sami 2019 年 12 月 30 日

5 投票

If I understood correctly, you can use the function randi to generate a matrix of integers for any specified size.
randi([10 90],2,6)

2 件のコメント

Sevval Yildiz
Sevval Yildiz 2019 年 12 月 30 日
Thx:) It worked.
darova
darova 2019 年 12 月 30 日
Please accept the answer

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeCreating and Concatenating Matrices についてさらに検索

製品

リリース

R2018a

質問済み:

2019 年 12 月 28 日

コメント済み:

2019 年 12 月 30 日

Community Treasure Hunt

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

Start Hunting!

Translated by