How can we create a vector of length n

292 ビュー (過去 30 日間)
Omar B.
Omar B. 2019 年 9 月 19 日
コメント済み: Omar B. 2019 年 9 月 19 日
Hello,
How can we write in Matlab vector u= [1/10 ,1/10 ,..., 1/10] where u \in{R}^{200}

採用された回答

James Tursa
James Tursa 2019 年 9 月 19 日
編集済み: James Tursa 2019 年 9 月 19 日
There are many ways of doing this. E.g., use the ones( ) function and divide by 10. Or use the zeros( ) function and add 1/10. Or use the repelem( ) function. Etc.
  2 件のコメント
Bruno Luong
Bruno Luong 2019 年 9 月 19 日
1/10+zeros(1,200)
1/10*ones(1,200)
Omar B.
Omar B. 2019 年 9 月 19 日
Thank you so much

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeProgramming についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by