<< slewrate | FOSSEE_Signal_Processing_Toolbox | sos2ss >>

FOSSEE_Signal_Processing_Toolbox >> FOSSEE_Signal_Processing_Toolbox > sos2cell

# sos2cell

Convert a second-order section matrix to a cell array representation.

### Syntax

    cll = sos2cell(s)
    cll = sos2cell(s, g)

### Parameters

s:

  Second-order section matrix (L-by-6 matrix).

- Must have exactly 6 columns in the format:

  [b0 b1 b2 a0 a1 a2].

g:

  Gain factor (optional).

cll:

  Cell array containing second-order sections.

- For unity-gain systems (no gain specified):

Cell array with L elements. Each element contains coefficients:

  {[b0 b1 b2] [a0 a1 a2]}.

- For non-unity gain systems:

Cell array with L+1 elements. The first element contains the gain:

  {g 1}. The remaining elements contain section coefficients.

### Description

The `sos2cell` function converts a second-order section matrix to a cell array representation. It supports both unity-gain and non-unity gain filter systems. For non-unity gain systems, the gain factor is stored in the first cell of the output array.

### Examples

    // Convert a second-order section matrix to a cell array (unity gain):
    sos = [3. 6. 7. 1. 1. 2. ; 1. 4. 5. 1. 9. 3. ; 2. 7. 1. 1. 7. 8.]
    cll = sos2cell(sos)

### Authors

- Abinash Singh

Report an issue
<< slewrate | FOSSEE_Signal_Processing_Toolbox | sos2ss >>