Could any body check my work? (Plot the function)
显示 更早的评论
x = [-56:64];
y = [3.*x^2-5.*x-6];
plot(x,y,'--r','LineWidth',0.5)
xlabel('e')
ylabel('n')
title('kg')
Is this the proper answer for the question? Is there anything I should change for it to become the correct answer?

采纳的回答
Your x and y doesn’t need square brackets. Check your title once again.
9 个评论
So should this be the answer i should give?
x = -56:64;
y = 3.*x^2-5.*x-6;
plot(x,y,'--y','LineWidth',0.5)
xlabel('e')
ylabel('n')
title('kg')
Seems about right, but the title part is confusing , "your weight in kg" , are you calculating any weight?
No I need to create a title for the plot, It's a question I learn, we are not calculating any weight
So why not proceed with the latter code?
What do u mean? which latter code? Could you give me some example?
x = -56:64;
y = 3*x.^2-5*x-6;
plot(x,y,'--y','LineWidth',0.5)
xlabel('e')
ylabel('n')
title('kg')
So I shouldn't use 3.*x Can you explain why it should be that format? why not 3.*x is there any difference?
https://in.mathworks.com/matlabcentral/answers/477409-could-any-body-check-my-work-plot-the-function#comment_738540 - probably reading that link in the comment should help you understand basically you’re still stuck in the fundamentals of MATLAB.
I still need to improve more, I will read and try to understand it from the link you gave me. Thank you so much for helping me all this times!
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Control System Toolbox 的更多信息
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!选择网站
选择网站以获取翻译的可用内容,以及查看当地活动和优惠。根据您的位置,我们建议您选择:。
您也可以从以下列表中选择网站:
如何获得最佳网站性能
选择中国网站(中文或英文)以获得最佳网站性能。其他 MathWorks 国家/地区网站并未针对您所在位置的访问进行优化。
美洲
- América Latina (Español)
- Canada (English)
- United States (English)
欧洲
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
