Create a row matrix with different step size

15 次查看(过去 30 天)
I am looking for something like [1 2 3 4 100 150 200] 1:1:4 (step size 1) and the rest 100:50:200 (step size 50)

采纳的回答

Brendan Hamm
Brendan Hamm 2015-5-4
Just utilize the concatenation operator [ ]
x = [1:4 100:50:200];

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Creating and Concatenating Matrices 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by