How to generate data
14 次查看(过去 30 天)
显示 更早的评论
Dear experts,
I need help to generate the data for the following situation.
I want to generate data for x in the range of 0 to 5 with the interval of 0.01. For each x there is y in the range of 0 to 3 in the interval of 0.01. After that I want to make two columns of x and y.
Kindly help.
0 个评论
采纳的回答
更多回答(1 个)
Jos (10584)
2019-3-7
I suggest you read parts of the starters manual and the help, and start exploring matlab :-)
help linspace
help colon
x = 1:2:5
f = 3/5
y = f .* x
2 个评论
Jos (10584)
2019-3-7
help reshape
help transpose
Is there a relationship between a value of x and a value of y, like a formula?
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Matrices and Arrays 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!