t=0:0.01:5;
v=exp(-t)+sin(t)
figure
plot(t,v);
h=get(gca,'children')
x = get(h,'XData');
y = get(h,'YData');
dy = diff(y) ./ diff(x);
hold on
plot(x(1:end-1),dy,'r')
legend('原始图像','求导图像')
MATLAB对plot曲线进行求导
最新推荐文章于 2025-04-23 18:14:39 发布