Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要应用一个巴特沃斯过滤器。为了证明我的截止频率,我需要像图片的第二个正方形那样绘制“残差与截止频率”图。
残差来自
所以我想申请一个
-巴特沃斯滤波器
-低通
订单 n=2
截止频率 wn= [0,20] Hz
所以我怀疑是否有办法通过matlab找到残差。然后根据截止频率绘制它们。
非常感谢任何帮助。
您可以获取输入信号(调用它x)并执行类似的操作
x
[b,a]=butter(2, [0 0.3]) % assuming the cutoff is 0.3 times the Nyquist frequency y = filter(b,a,x) n = length(x) z = x - y z = z.^2 z = sum(z) / n R = sqrt(z)