MATLABプロットセット[] []

ここに画像を挿入説明

n=50;a=0;b=3;
x=linspace(a,b,n);
e1=exp(-x.^2);
e2=(x.^2).*exp(-x.^2);
e3=x.*exp(-x.^2);
e4=exp(-x);
hold on;
plot(x,e1,'linewidth',1);
plot(x,e2,'linewidth',2);
plot(x,e3,'linewidth',3);
plot(x,e4,'linewidth',4);
legend('y=e^-^x^(^2^)','y=x^2*e^-^x^(^2^)','y=x*e^-^x^(^2^)','y=e^-^x')
hold off

ここに画像を挿入説明

x=linspace(0,10,50);
y=exp(sin(x));
delta=0.15*y;
errorbar(x,y,delta);

ここに画像を挿入説明

x=0:0.25:4;
y=exp(x);
clf reset;
plotyy(x,y,x,y,'plot','semilogy')
hold on;
title('plotyy')
ylabel('linear scale')

ここに画像を挿入説明

x=0:10;
A=[sin(x);x;(x/3).^2]';
clf;
areahandle = area(x,A)
hold on
title('Area plot')
legend(areahandle,'sin(x)','sin(x)+x','sin(x)+x+(x/3)^2',2)

ここに画像を挿入説明

x=linspace(0,7);
y=exp(x);
subplot(2,1,1);plot(x,y);
title('在普通坐标系(上图)和y轴对数刻度坐标系(下图)中绘制指数函数')
subplot(2,1,2);semilogy(x,y);

ここに画像を挿入説明

t=linspace(0,22*pi,1100);
r=exp(cos(t))-2*cos(4*t)+(sin(t./12)).^5;
subplot(2,1,1)
p=polar(t,r);
subplot(2,1,2)
[x,y]=pol2cart(t,r);
plot(x,y)
[x,y]=pol2cart(t,r);
plot(x,y)
公開された22元の記事 ウォンの賞賛3 ビュー1829

おすすめ

転載: blog.csdn.net/qq_42825058/article/details/100181807