Accelerating the pace of engineering and science

# Documentation Center

• Trial Software

# algdeintrlv

Restore ordering of symbols using algebraically derived permutation table

## Syntax

deintrlvd = algdeintrlv(data,num,'takeshita-costello',k,h)
deintrlvd = algdeintrlv(data,num,'welch-costas',alph)

## Description

deintrlvd = algdeintrlv(data,num,'takeshita-costello',k,h) restores the original ordering of the elements in data using a permutation table that is algebraically derived using the Takeshita-Costello method. num is the number of elements in data if data is a vector, or the number of rows of data if data is a matrix with multiple columns. In the Takeshita-Costello method, num must be a power of 2. The multiplicative factor, k, must be an odd integer less than num, and the cyclic shift, h, must be a nonnegative integer less than num. If data is a matrix with multiple rows and columns, the function processes the columns independently.

deintrlvd = algdeintrlv(data,num,'welch-costas',alph) uses the Welch-Costas method. In the Welch-Costas method, num+1 must be a prime number. alph is an integer between 1 and num that represents a primitive element of the finite field GF(num+1).

To use this function as an inverse of the algintrlv function, use the same inputs in both functions, except for the data input. In that case, the two functions are inverses in the sense that applying algintrlv followed by algdeintrlv leaves data unchanged.

## Examples

The code below uses the Takeshita-Costello method of algintrlv and algdeintrlv.

```num = 16; % Power of 2
ncols = 3; % Number of columns of data to interleave
data = rand(num,ncols); % Random data to interleave
k = 3;
h = 4;
intdata = algintrlv(data,num,'takeshita-costello',k,h);
deintdata = algdeintrlv(intdata,num,'takeshita-costello',k,h);```