y-values from a given function
显示 更早的评论
I have a function and two values of x and I would like to find the values corresponding to the x-values, how should I start ? I was thinking to do for loop but it does not work it only gave me one of the answers (as you can see below)!
for x = 0.36 : 0.40
y = x^4 + 5*x^2 + sqrt(x-1)
end
y =
0.6648 + 0.8000i
1 个评论
John D'Errico
2017-1-9
So your code was wrong. Show your code, and someone will show you how to fix it.
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Loops and Conditional Statements 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!