filter (MathScript RT Module Function)

LabVIEW 2012 MathScript RT模块帮助

版本日期:June 2012

产品编号:373123C-0118

»查看产品信息
下载帮助
(仅限Windows)

Owning Class: filter implementation

Requires: MathScript RT Module

Syntax

y = filter(b, a, x)

y = filter(b, a, x, 'direct')

[y, final] = filter(b, a, x, initial)

[y, final] = filter(b, a, x, initial, 'direct')

Description

Applies a one-dimensional filter. filter works for vectors and matrices only.

Examples

Inputs

Name Description
b Specifies the forward filter coefficients. b is a vector.
a Specifies the backward filter coefficients. If the first backward filter coefficient does not equal 1, LabVIEW normalizes the elements in a by the first backward filter coefficient. a is a vector.
x Specifies the signal to filter. x is a real or complex vector.
initial Specifies the initial conditions. initial is a vector.
'direct' Directs LabVIEW to use a direct convolution instead of a Fourier transform. Fourier transforms are faster for larger signals and filter lengths, but they introduce a small amount of round-off noise.

Outputs

Name Description
y Returns the filtered signal. y is a real or complex vector.
final Returns the final conditions. final is a vector.

Details

The following table lists the support characteristics of this function.

Supported in the LabVIEW Run-Time Engine Yes
Supported on RT targets Yes
Suitable for bounded execution times on RT Not characterized

Examples

x = 0:0.01:1;
b = [1];
a = [1, 1, 1];
y = filter(b, a, x)

Related Topics

filter_2d
filter_fft
filter_zerophase

文章是否对您有帮助?

没有帮助