vector with spacing (predefined)
3 次查看(过去 30 天)
显示 更早的评论
采纳的回答
David Fletcher
2021-4-18
Maybe I am missing something, but this?
initial_value=-25;
step_size=5;
final_value=15;
vector=initial_value:step_size:final_value
0 个评论
更多回答(1 个)
the cyclist
2021-4-18
Does
v = -25:5:15
do what you want? Or maybe you meant
initial_value = -25;
step_size = 5;
final_value = 15;
v = initial_value : step_size : final_value
If neither of those is what you meant, then I don't understand.
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!