matlab 一组数求导后波动大,怎么才能使其波动小一点.甚至没有波动!F=zeros(501,1);fdEk1=500*diff(Ek1);fdEk2=500*diff(Ek2);fdEk3=500*diff(Ek3);for j=1:1:500dEk1(j+1)=fdEk1(j);dEk2(j+1)=fdEk1(j);dEk3(j+1)=fdEk1(j);F(j)=(dEk1(j)+dEk
来源:学生作业帮助网 编辑:作业帮 时间:2024/09/03 08:48:04
![matlab 一组数求导后波动大,怎么才能使其波动小一点.甚至没有波动!F=zeros(501,1);fdEk1=500*diff(Ek1);fdEk2=500*diff(Ek2);fdEk3=500*diff(Ek3);for j=1:1:500dEk1(j+1)=fdEk1(j);dEk2(j+1)=fdEk1(j);dEk3(j+1)=fdEk1(j);F(j)=(dEk1(j)+dEk](/uploads/image/z/1790708-68-8.jpg?t=matlab+%E4%B8%80%E7%BB%84%E6%95%B0%E6%B1%82%E5%AF%BC%E5%90%8E%E6%B3%A2%E5%8A%A8%E5%A4%A7%2C%E6%80%8E%E4%B9%88%E6%89%8D%E8%83%BD%E4%BD%BF%E5%85%B6%E6%B3%A2%E5%8A%A8%E5%B0%8F%E4%B8%80%E7%82%B9.%E7%94%9A%E8%87%B3%E6%B2%A1%E6%9C%89%E6%B3%A2%E5%8A%A8%21F%3Dzeros%28501%2C1%29%3BfdEk1%3D500%2Adiff%28Ek1%29%3BfdEk2%3D500%2Adiff%28Ek2%29%3BfdEk3%3D500%2Adiff%28Ek3%29%3Bfor+j%3D1%3A1%3A500dEk1%28j%2B1%29%3DfdEk1%28j%29%3BdEk2%28j%2B1%29%3DfdEk1%28j%29%3BdEk3%28j%2B1%29%3DfdEk1%28j%29%3BF%28j%29%3D%28dEk1%28j%29%2BdEk)
matlab 一组数求导后波动大,怎么才能使其波动小一点.甚至没有波动!F=zeros(501,1);fdEk1=500*diff(Ek1);fdEk2=500*diff(Ek2);fdEk3=500*diff(Ek3);for j=1:1:500dEk1(j+1)=fdEk1(j);dEk2(j+1)=fdEk1(j);dEk3(j+1)=fdEk1(j);F(j)=(dEk1(j)+dEk
matlab 一组数求导后波动大,怎么才能使其波动小一点.甚至没有波动!
F=zeros(501,1);
fdEk1=500*diff(Ek1);
fdEk2=500*diff(Ek2);
fdEk3=500*diff(Ek3);
for j=1:1:500
dEk1(j+1)=fdEk1(j);
dEk2(j+1)=fdEk1(j);
dEk3(j+1)=fdEk1(j);
F(j)=(dEk1(j)+dEk2(j)+dEk3(j)-P1(j)-P2(j)-P3(j)-PG1(j)-PG2(j)-PG3(j))/(sqrt(Vkx(j)*Vkx(j)+Vky(j)*Vky(j)));
end
figure
plot(F)
matlab 一组数求导后波动大,怎么才能使其波动小一点.甚至没有波动!F=zeros(501,1);fdEk1=500*diff(Ek1);fdEk2=500*diff(Ek2);fdEk3=500*diff(Ek3);for j=1:1:500dEk1(j+1)=fdEk1(j);dEk2(j+1)=fdEk1(j);dEk3(j+1)=fdEk1(j);F(j)=(dEk1(j)+dEk
把数据代码贴上来瞧瞧~
/(sqrt(Vkx(j)*Vkx(j)+Vky(j)*Vky(j))%这里是做类似于归一化的操作吧
嗯这个程序觉得应该问题不大
Vkx Vky Vkz 这里的数值还有前面
dEk1(j)+dEk2(j)+dEk3(j)
-P1(j)-P2(j)-P3(j)
-PG1(j)-PG2(j)-PG3(j)这是不是三种不同的数据?数据本身差异大连续性不好.后面画图效果就会出现你说的问题吧.
建议就是:
1、数据预处理,比如对原始数据做一些拟合,去掉一些点,做一些差值什么的;
2、或者就是对结果的F(j)作拟合吧,matlab有个拟合工具箱可以试一下.
help 一下 cftool 其他的我是没好办法来