Hauptinhalt

Cascaded Transfer Functions

R2026b

Cascaded transfer functions (CTF) represent a filter as a product of transfer-function sections connected in series, where each factor corresponds to a CTF section. A common use of CTF is to represent a third- or higher-order transfer function as a product of lower-order sections, which can improve numerical robustness and reduce susceptibility to quantization errors.

The CTF form of a transfer function H(z) in terms of the L transfer functions H1(z), H2(z), …, HL(z) is

H(z)==1LHl(z)=H1(z)·H2(z)··HL(z).

Use the CTF Array Format to represent filters in MATLAB® in the CTF form. With Signal Processing Toolbox™ and DSP System Toolbox™, you can design and analyze digital filters using CTF. To achieve this goal, you can either:

  • Specify Digital Filters in CTF Format — Specify or import the numerator and denominator coefficients that define the CTF representation of digital filters. For most functions, you can also specify the scale value of each CTF section, for the entire filter, or both.

  • Return Digital Filters in CTF Format — Return or export the numerator and denominator coefficients that define the CTF representation of digital filters. For some functions, you can also return the scale value for each CTF section or for the entire filter.

CTF Array Format

The CTF format comprises arrays containing coefficients and gain scaling factors (scale values) used to represent the transfer function of a digital filter in CTF form.

Note

  • Although Signal Processing Toolbox and DSP System Toolbox use this format to read and return CTF representations, it is only one of many ways to represent a filter in CTF form. A filter can have multiple equivalent CTF representations. Different choices of sections, section grouping or permutation, pole-zero cancellations, and scale values can produce different CTF representations that realize the same filter.

  • Although the CTF array format supports sections of any order, limit each section to fourth order or lower to maintain numerical robustness.

Assume the L-row matrices B and A, and the L + 1-element vector Γ,

B=[b11b12b1,m+1b21b22b2,m+1bL1bL2bL,m+1],A=[a11a12a1,n+1a21a22a2,n+1aL1aL2aL,n+1],Γ=[γ1γ2γLγS],

where L is the number of CTF sections, B and A contain CTF numerator and denominator coefficients, and Γ contains scale values that apply to each or all the CTF sections.

In terms of the elements of B, A, and Γ, the full transfer function of the filter is

H(z)=γS(γ1b11+b12z1++b1,m+1zma11+a12z1++a1,n+1zn·γ2b21+b22z1++b2,m+1zma21+a22z1++a2,n+1zn··γLbL1+bL2z1++bL,m+1zmaL1+aL2z1++aL,n+1zn).

Numerator and Denominator

Each section of H(z) is a cascaded transfer function, where m ≥ 0 is the numerator order and n ≥ 0 is the denominator order, provided that b,m+1 and a,n+1 are nonzero for = 1,2,…,L.

Depending on the shape of B and A, the underlying system can represent one of these filter types:

  • If B is scalar, the system is a cascade of all-pole IIR filters.

  • If A is scalar, the system is a cascade of FIR filters.

  • If both B and A are vectors, then the underlying system is a one-section IIR filter (L = 1), with B representing the numerator of the transfer function and A representing the denominator.

  • If B and A are L-by-3 matrices (m = n = 2), the system is a cascade of L second-order-section (SOS) filters.

  • If B and A are L-by-5 matrices (m = n = 4), the system is a cascade of L fourth-order-section (FOS) filters.

Scale Values and Gains

Depending on the shape of Γ, the CTF sections are scaled as either of these cases:

  • If Γ is a scalar, then this value represents the overall scale value of the filter.

  • If Γ is a vector, then each of the first L scale values corresponds to a CTF section, and the last value represents the overall scale value of the filter.

Thus, the gain at the -th CTF section and the overall system gain are these:

  • Gain at the th CTF section, g=sgn(γS)|γS|1/Lγb1a1

  • Overall system gain, gS=γS=1Lγb1a1=(γ1·γ2··γL·γS)b11·b21··bL1a11·a21··aL1

Specify Digital Filters in CTF Format

To analyze, visualize, design, and filter signals using digital filters in the CTF format, specify a filter by listing its coefficients B and A. For most functions, you can also include the scale values by specifying a scalar or vector in Γ.

Supported CTF Input

You can specify CTF input in either of these ways:

  • Coefficients — When you specify B and A as a pair of L-row matrices, the filter is treated as a sequence of L cascaded transfer functions with unity scale values.

  • Coefficients and scale values — If you have one or multiple scale values factored out from the coefficient values, you can specify both the coefficients and the scale values in the same syntax (in function and objects) or in the same import dialog box (in apps). Scaling CTF sections is especially important when working with fixed-point arithmetic. Similar output amplitude levels across sections help maintain numerical accuracy and can reduce filter-response distortions caused by limited numeric precision.

    When you specify B, A, and Γ, the filter is treated as a sequence of cascaded transfer functions with scale values.

    • If Γ is a scalar, it is uniformly distributed across all the CTF sections.

    • If Γ is a vector, it must have L + 1 elements, where L is the number of CTF sections. Each of the first L elements is a scale value that applies to the corresponding CTF section, and the (L + 1)-th value is uniformly distributed across all the CTF sections.

Input Support

This table lists the functions, objects, and apps that support specifying or importing input in CTF format.

GoalFunction / Object / AppSupported CTF Input
Filter signals using CTF
  • Coefficients

  • Coefficients and scale values

Create digitalFilter objects for analysis, visualization, and signal filtering
  • Coefficients

  • Coefficients and scale values

Obtain time-domain responses
  • Coefficients

  • Coefficients and scale values

Obtain frequency-domain responses
  • Coefficients

  • Coefficients and scale values

Explore filter properties
  • Coefficients

  • Coefficients and scale values

Obtain zeros and poles from CTF
  • Coefficients

  • Coefficients and scale values

  • Coefficients

Create filter System object™ from CTF
  • Coefficients

  • Coefficients and scale values

Analyze and visualize filters interactively

  • Coefficients

  • Coefficients and scale values

For more information, see Import Filter Coefficients.

Design filters interactively

  • Coefficients

  • Coefficients and scale values

For more information, see Import Filter Coefficients.

Return Digital Filters in CTF Format

To obtain the digital filter representation in the CTF format for analysis, visualization, design, and signal filtering, return the filter coefficients B and A. For some functions, you can also return Γ with the scale value for each CTF section or for the entire filter.

Supported CTF Output

You can return CTF output in either of these ways:

  • Coefficients — Return B and A. These coefficient arrays incorporate the scale values.

  • Coefficients and overall scale value — Return B, A, and Γ, where:

    • The coefficient arrays B and A incorporate the scale values of the CTF sections.

    • The scalar Γ contains the overall scale value of the filter. If the first column of B and A is a unity vector, then Γ also represents the overall system gain of the filter.

  • Coefficients and section scale values — Return B, A, and Γ, where:

    • The coefficient arrays B and A incorporate the overall scale value of the filter. Thus, the last element of Γ is 1.

    • The first L elements of Γ contain the scale values of the CTF sections.

Output Support

This table lists the functions, objects, and apps that support returning or exporting output in CTF format.

GoalFunction / Object / AppSupported CTF Output
Convert second-order section matrices to CTF
  • Coefficients

Convert zero-pole-gain filter representation to CTF
  • Coefficients

  • Coefficients and overall scale value

Convert digitalFilter objects or System objects to CTF
  • Coefficients

  • Coefficients and section scale values
    (only from filter System object)

Design digital filters for analysis, visualization, and signal filtering
  • Coefficients

  • Coefficients

  • Coefficients and section scale values

Design IIR digital filters
  • Coefficients

  • Coefficients and overall scale value

Perform frequency transformation from lowpass IIR filters
  • Coefficients

Design filters interactively

  • Coefficients

For more information, see Export Filter Coefficients.

References

[1] Lyons, Richard G. Understanding Digital Signal Processing. Upper Saddle River, NJ: Prentice Hall, 2004.

See Also

Apps

Functions

Live Editor Tasks

Topics