分别用plot,fplot,ezplot函数绘制下面函数的图形y(x)=x²sin(x²-x-2),

分别用plot,fplot,ezplot函数绘制下面函数的图形y(x)=x²sin(x²-x-2),x大于等于-2小于等于2
myxia1976 1年前 已收到2个回答 举报

小蜘蛛猫猫 幼苗

共回答了19个问题采纳率:89.5% 举报

x=-2:0.01:2;
y=x.^2.*sin(x.^2-x-2);
plot(x,y);
figure(2);
fplot(@(x)[x^2*sin(x^2-x-2)],[-2 2]);
figure(3);
ezplot(@(x)[x.^2.*sin(x.^2-x-2)],[-2,2]);

1年前

1

rememberhyz 幼苗

共回答了3个问题 举报

>> x=-2:0.1:2;
>> y=x.^2.*sin(x.^2-x-2);
>> plot(x,y)
>> figure(2)
>> Y=@(X)X.^2.*sin(X.^2-X-2);
>> fplot(Y,[-2,2])
>>figure(3)
>>syms x3
>> y3=x3.^2.*sin(x3.^2-x3-2);
>> ezplot(y3)
>> axis([-2,2,-4,3])
希望我的回答令你满意!

1年前

1
可能相似的问题
Copyright © 2024 YULUCN.COM - 雨露学习互助 - 18 q. 1.254 s. - webmaster@yulucn.com