Main Content


Permute symbols using set of shift registers with specified delays


The comm.MultiplexedInterleaver System object™ permutes the symbols in the input sequence by using a set of shift registers, each with its own delay value. For more information, see Interleaving.

To permute the symbols in the input sequence:

  1. Create the comm.MultiplexedInterleaver object and set its properties.

  2. Call the object with arguments, as if it were a function.

To learn more about how System objects work, see What Are System Objects?



muxinterleaver = comm.MultiplexedInterleaver creates a default multiplexed interleaver System object. This System object permutes the symbols in the input sequence by using a set of shift registers with specified delays. The muxinterleaver System object consists of N registers, each with a specified delay. With each new input symbol, the System object switches the commutator to a new register and shifts in the new symbol while shifting out the oldest symbol in that register. When the commutator reaches the Nth register, upon the next new input, the commutator returns to the first register.


muxinterleaver = comm.MultiplexedInterleaver(Name,Value) sets the Properties by using one or more name-value arguments. For example, 'InitialConditions',1 sets the initial conditions of the shift registers to 1.


expand all

Unless otherwise indicated, properties are nontunable, which means you cannot change their values after calling the object. Objects lock when you call them, and the release function unlocks them.

If a property is tunable, you can change its value at any time.

For more information on changing property values, see System Design in MATLAB Using System Objects.

Interleaver delay, specified as a column vector of integers. The values in this vector specify the lengths of the shift registers.

Data Types: double

Initial conditions of the shift registers, specified as one of these options.

  • Numeric scalar — The default value is 0. The specified scalar applies to all shift registers.

  • Column vector — The length of this vector must be equal to the length of the Delay property value. The ith initial condition applies to the ith shift register.

Data Types: double



intrlvseq = muxinterleaver(inputseq) permutes the input sequence of symbols, inputseq, by using a set of shift registers with delays specified by the Delay property. The System object returns the interleaved sequence, intrlvseq.

Input Arguments

expand all

Sequence of symbols, specified as a column vector.

Data Types: double | logical | fi

Output Arguments

expand all

Interleaved sequence of symbols, returned as a column vector with the same data type and size as the inputseq input.

Data Types: double | logical | fi

Object Functions

To use an object function, specify the System object as the first input argument. For example, to release system resources of a System object named obj, use this syntax:


expand all

stepRun System object algorithm
releaseRelease resources and allow changes to System object property values and input characteristics
resetReset internal states of System object


collapse all

Create a multiplexed interleaver System object, specifying the interleaver delay.

interleaver = comm.MultiplexedInterleaver('Delay',[1; 0; 2; 1]);

Create a multiplexed deinterleaver System object, specifying the interleaver delay.

deinterleaver = comm.MultiplexedDeinterleaver('Delay',[1; 0; 2; 1]);

Generate a random data sequence. Pass the data sequence through the interleaver and then the deinterleaver.

[dataIn,dataOut] = deal([]); % Initialize data arrays

for index = 1:50
    data = randi([0 7],20,1);
    intrlvSequence = interleaver(data);
    deintrlvSequence = deinterleaver(intrlvSequence);
    % Save original data and deinterleaved data
    dataIn = cat(1,dataIn,data);
    dataOut = cat(1,dataOut,deintrlvSequence);

Determine the delay through the interleaver and deinterleaver.

delay = finddelay(dataIn,dataOut)
delay = 8

After accounting for the delay, confirm that the original and deinterleaved sequences are identical.

ans = logical

Copyright 2012 The MathWorks, Inc.


[1] Heegard, Chris and Stephen B. Wicker. Turbo Coding. Boston: Kluwer Academic Publishers, 1999.

Extended Capabilities

Version History

Introduced in R2012a