# designMultistageDecimator

## Syntax

## Description

designs a multistage decimator that has an overall decimation factor of
`C`

= designMultistageDecimator(`M`

)`M`

. In order for `C`

to be multistage,
`M`

must not be a prime number. For details, see Algorithms. The design process can
take a while if `M`

has many factors.

specifies additional design parameters using one or more name-value pair arguments.`C`

= designMultistageDecimator(___,`Name,Value`

)

**Example: **```
C =
designMultistageDecimator(48,48000,200,80,'NumStages','auto')
```

designs a
multistage decimator with the least number of multiplications per input sample
(MPIS).

## Examples

## Input Arguments

## Output Arguments

## Algorithms

The overall decimation factor is split into smaller factors with each factor being the decimation factor of the corresponding individual stage. The combined decimation of all the individual stages must equal the overall decimation. The combined response must meet or exceed the given design specifications.

The function determines the number of decimator stages through the
`'NumStages'`

argument. The sequence of stages is determined based on the
implementation cost. By default, `'NumStages'`

is set to
`'auto'`

, resulting in a sequence that gives the lowest number of MPIS.
When multiple configurations result in the same lowest MPIS within the tolerance specified,
the configuration that yields the lowest number of coefficients overall is chosen. If
`'MinTotalCoeffs'`

is set to `true`

, the function
determines the sequence that requires the lowest number of total coefficients.

By default, the `'CostMethod'`

is set to `'estimate'`

.
In this mode, the function estimates the filter order required for each stage and designs the
filter based on the estimate. This method is faster than `'design'`

, but can
lead to suboptimal designs. For an optimal design, set `'CostMethod'`

to
`'design'`

. In this mode, the function designs each stage and computes the
filter order.

## Version History

**Introduced in R2018b**