Documentation

This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

comm.gpu.BlockDeinterleaver System object

Restore original ordering of block interleaved sequence with GPU

Description

The BlockDeinterleaver System object™ restores the original ordering of a sequence that was interleaved using the block interleaver System object.

Note

To use this object, you must install a Parallel Computing Toolbox™ license and have access to an appropriate GPU. For more about GPUs, see GPU Computing (Parallel Computing Toolbox).

A GPU-based System object accepts typical MATLAB® arrays or objects that you create using the gpuArray class as an input. GPU-based System objects support input signals with double- or single-precision data types. The output signal inherits its datatype from the input signal.

  • If the input signal is a MATLAB array, then the output signal is also a MATLAB array. In this case, the System object handles data transfer between the CPU and GPU.

  • If the input signal is a gpuArray, then the output signal is also a gpuArray. In this case, the data remains on the GPU. Therefore, when the object is given a gpuArray, calculations take place entirely on the GPU and no data transfer occurs. Passing gpuArray arguments provides increased performance by reducing simulation time. For more information, see Establish Arrays on a GPU (Parallel Computing Toolbox).

To deinterleave the input vector:

  1. Define and set up your block deinterleaver object. See Construction.

  2. Call step to rearrange the elements of the input vector according to the properties of comm.gpu.BlockDeinterleaver. The behavior of step is specific to each object in the toolbox.

Note

Starting in R2016b, instead of using the step method to perform the operation defined by the System object, you can call the object with arguments, as if it were a function. For example, y = step(obj,x) and y = obj(x) perform equivalent operations.

Construction

H = comm.gpu.BlockDeinterleaver creates a GPU-based block deinterleaver System object, H. This object restores the original ordering of a sequence that was interleaved using the BlockInterleaver System object

H = comm.gpu.BlockDeinterleaver(Name,Value) creates a GPU-based block deinterleaver object, H, with the specified property name set to the specified value.

H = comm.gpu.BlockDeinterleaver(PERMVEC) creates a GPU-based block deinterleaver object, H, with the PermutationVector property set to PERMVEC.

Properties

PermutationVector

Permutation vector

Specify the mapping used to permute the input symbols as a column vector of integers. The default is [5;4;3;2;1]. The mapping is a vector where the number of elements is equal to the length, N, of the input to the step method. Each element must be an integer between 1 and N, with no repeated values.

Methods

stepDeinterleave input sequence
Common to All System Objects
clone

Create System object with same property values

getNumInputs

Expected number of inputs to a System object

getNumOutputs

Expected number of outputs of a System object

isLocked

Check locked states of a System object (logical)

release

Allow System object property value changes

Algorithm

This object uses the same algorithm as the comm.BlockDeinterleaver System object. See Algorithms on the comm.BlockDeinterleaver help page for details.

Examples

expand all

Create interleaver and deinterleaver objects.

interleaver = comm.gpu.BlockInterleaver([3 4 1 2]');
deinterleaver = comm.gpu.BlockDeinterleaver([3 4 1 2]');

Pass random data through the interleaver and deinterleaver.

data = randi(7,4,1);
intData = interleaver(data);
deIntData = deinterleaver(intData);

Display the original sequence, interleaved sequence, and restored sequence.

[data intData deIntData]
ans =

     6     1     6
     7     7     7
     1     6     1
     7     7     7

Confirm the original and deinterleaved data are identical.

isequal(data,deIntData)
ans =

     1

Generate a random vector of unique integers as a permutation vector.

permVec = randperm(7)';

Specify permVec as the permutation vector for the interleaver and deinterleaver objects.

interleaver = comm.gpu.BlockInterleaver(permVec);
deinterleaver = comm.gpu.BlockDeinterleaver(permVec);

Pass random data through the interleaver and deinterleaver.

data = randi(10,7,1);
intData = interleaver(data);
deIntData = deinterleaver(intData);

Confirm the original and deinterleaved data are identical.

isequal(data,deIntData)
ans =

     1

Introduced in R2012a

Was this topic helpful?