文档

FIR Rate Conversion

升级,,,,filter, and downsample input signals

图书馆

过滤 /多室过滤器

DSPMLTI4

Description

这FIR Rate Conversion block resamples the discrete-time input such that its sample period isk/l次输入样本期(tsi)。k是您指定的整数值拆卸因子参数,和l是您指定的整数值插值因子范围。

该块将输入的每一列视为一个单独的通道,并随着时间的推移独立地对每个通道中的数据重新示例。为此,该块实现了多相滤波器结构并执行以下操作:

  1. 通过插入将输入提高到更高的速率l-1输入样品之间的零。

  2. 通过直接形式的II转置FIR滤波器传递UP采样数据。

  3. 通过丢弃,将过滤的数据下调至较低的速率k-1遵循块保留的每个样品的连续样品。

这polyphase filter implementation is more efficient than a straightforward upsample-filter-decimate algorithm. See Orfanidis[1]for more information.

Specifying the Resampling Rate

您可以使用拆卸因子插值因子参数。为m一世-by-n矩阵输入,拆卸因子,,,,k,和插值因子,,,,l,必须满足以下要求:

  • kl必须是相对主要的整数;即,比率k/l不能减少较小整数的比率。

  • k l = m 一世 m o ,,,,在哪里m一世mo输入的整数帧大小和outpu吗t, respectively.

您可以通过设置拆卸因子,,,,k,等于输入帧大小,m一世。当您这样做时,输出帧大小,mo,,,,equals the插值因子,,,,l

通过以这种方式更改帧大小,该块能够保持帧周期常数(tfi=tfo)和achieve the desired conversion of the sample period, such that

t s o = k l × t s 一世

在哪里t所以是输出样本周期。

Specifying the FIR Filter Coefficients

要指定过滤器系数,请选择要进入FIR率转换块的模式。在系数源组盒。

  • 对话参数— Enter information about the filter, such as coefficients, in the block dialog box.

  • 过滤对象- 使用A指定过滤器dsp.firrateconverter系统对象™。

  • 汽车(默认) - 自动选择过滤器系数。

当您选择对话参数选项,您使用FIR滤波器系数参数以指定FIR滤波器传输功能的分子系数H((z)。

H (( z = b (( z = b 1 + b 2 z - 1 + + b m z - (( m - 1

You can generate the FIR filter coefficient vector,[B(1)B(2)... B(M)],,,,using one of the DSP System Toolbox™ filter design functions such asDesignMultirateFir,,,,firnyquist,,,,firhalfband,,,,firgr或者firceqrip

这coefficient vector you specify must have a length greater than the interpolation factor (m>l)。FIR过滤器必须是具有归一化截止频率的低通滤波器,不超过最小((1/l,,,,1/k)。这block internally initializes all filter states to zero.

当您选择时汽车,该块设计了一个FIR多胎过滤器,其中指定的拆卸因子拆卸因子和插值因子在插值因子。这DesignMultirateFirFunction designs the filter and returns the coefficients used by the block. For more information on the filter design, see Orfanidis[1]

Fixed-Point Data Types

下图显示了定点信号的FIR速率转换块中使用的数据类型。

您可以在“块”对话框中设置系数,产品输出,累加器和输出数据类型对话框。这diagram shows that input data is stored in the input buffer in the same data type and scaling as the input. Filtered data resides in the output buffer in the output data type and scaling that you set in the block dialog. The block stores any initial conditions in the output buffer using the output data type and scaling that you set in the block dialog box.

当乘数至少一个输入是真实的,乘数的输出位于产品输出数据类型中。当乘数的两个输入都是复杂的时,乘法的结果在于累加器数据类型。有关执行的复杂乘法的详细信息,请参见乘法数据类型

笔记

当块输入为固定点时,所有内部数据类型均为固定点。

Examples

示例1

这following figure shows how the FIR Rate Conversion block converts a4-by-1一世nput with a sample period of3/4,到3-by-1output with a sample period of1。框架期(tF)3保持恒定。

示例2

ex_audio_frc模型提供了一种简单的说明,说明一种将语音信号从一个样本速率转换为另一种样本率的方法。在此模型中,首先以22,050 Hz采样数据,然后以8000 Hz重新采样。如果您收听输出,您会听到高频内容已从信号中删除,尽管语音听起来基本相同。

对话框

Coefficient Source

FIR率转换块可以以三种不同的模式运行。选择模式系数源组盒。

  • 对话参数- 在块掩模中输入有关过滤器(例如系数)的信息。

  • 过滤对象- 使用A指定过滤器dsp.firrateconverter系统对象。

  • 汽车(默认) - 自动选择过滤器系数。

根据您是否选择对话参数,,,,过滤对象, 或者汽车一世n the系数源组盒。

Specify Filter Characteristics in Dialog

指定多条过滤对象

Choose Filter Coefficients Automatically

References

[1] Orfanidis, Sophocles J.信号处理简介。新泽西州上萨德尔河:Prentice-Hall,1996年。

金宝app支持的数据类型

港口 金宝app支持的数据类型

Input

  • 双精度浮点

  • 单精度浮点

  • 固定点

  • 8-, 16-, and 32-bit signed integers

  • 8-,16和32位未签名的整数

输出

  • 双精度浮点

  • 单精度浮点

  • 固定点

  • 8-, 16-, and 32-bit signed integers

  • 8-,16和32位未签名的整数

也可以看看

Downsample DSP System Toolbox
升级 DSP System Toolbox
FIR拆除 DSP System Toolbox
FIR插值 DSP System Toolbox
CIC拆卸 DSP System Toolbox
CIC Interpolation DSP System Toolbox
FIR半乐队插值器 DSP System Toolbox
FIR Halfband Decimator DSP System Toolbox
IIR Halfband插值器 DSP System Toolbox
IIR半乐队删除器 DSP System Toolbox
CIC补偿插装器 DSP System Toolbox
CIC补偿分解器 DSP System Toolbox
dsp.ciccompensation -ectecator DSP System Toolbox
dsp.ciccompensation Interpolator DSP System Toolbox
dsp.firhalfbanddecemator DSP System Toolbox
dsp.firhalfbandinterpolator DSP System Toolbox
dsp.firdecemator DSP System Toolbox
dsp.firinterpolator DSP System Toolbox
firnyquist DSP System Toolbox
firhalfband DSP System Toolbox
firgr DSP System Toolbox
firceqrip DSP System Toolbox

看the following sections for related information:

扩展功能

定点转换
Design and simulate fixed-point systems using Fixed-Point Designer™.

在R2006a之前引入