【 MATLAB 】filter 函数介绍(一维数字滤波器)

了解这个函数,先看看这个基础知识:【 MATLAB 】Rational Transfer Function(有理传递函数)

filter

1-D digital filter

Syntax

y = filter(b,a,x)

y = filter(b,a,x,zi)

y = filter(b,a,x,zi,dim)

[y,zf] = filter(___)

Description

y = filter(b,a,x) 使用由分子和分母系数 b 和 a 定义的有理传递函数对输入数据 x 进行滤波。

If a(1) is not equal to 1, then filter normalizes the filter coefficients by a(1). Therefore, a(1) must be nonzero.

  • If x is a vector, then filter returns the filtered data as a vector of the same size as x.

  • If x is a matrix, then filter acts along the first dimension and returns the filtered data for each column.

  • If x is a multidimensional array, then filter acts along the first array dimension whose size does not equal 1.


针对这条语法举个例子:

Moving-Average Filter

移动平均滤波器是用于平滑噪声数据的常用方法。 此示例使用过滤器函数计算沿数据向量的平均值。

Create a 1-by-100 row vector of sinusoidal data that is corrupted by random noise.

t = linspace(-pi,pi,100);
rng default  %initialize random number generator
x = sin(t) + 0.25*rand(size(t));

A moving-average filter slides a window o

  • 7
    点赞
  • 84
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

李锐博恩

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值