Compute 2-D inverse discrete cosine transform (IDCT)
Computer Vision Toolbox / Transforms
The 2-D IDCT block calculates the two-dimensional inverse discrete cosine transform of the input signal. The equation for the two-dimensional IDCT of an input signal is:
where F(m,n) is the discrete cosine transform (DCT) of the signal f(x,y). If , then . Otherwise .
Port_1 — Input data
matrix | vector
Specify input data as a vector or matrix of intensity values. The number of elements in the input data must be a power of two.
Port_1 — Output data
matrix | vector
Output data containing the 2-D IDCT of the input, returned as a matrix or vector. The size and data type of the output are the same as those of the input.
Sine and cosine computation — How the block computes sine and cosine terms
Table lookup (default) |
Specify how the block computes the sine and cosine terms to find the 2-D IDCT.
Table lookup— The block computes and stores the trigonometric values before the simulation starts. This option requires more memory than the
Trigonometric fcn— The block computes the sine and cosine values during the simulation.
For details on the fixed-point block parameters, see Specify Fixed-Point Attributes for Blocks.
Lock data type settings against change by the fixed-point tools — Data type override
off (default) |
Select this parameter to prevent the fixed-point tools from overriding the data types you specify in this block. For more information, see Lock the Output Data Type Setting (Fixed-Point Designer).
Fixed-Point Data Types
The following diagram shows the data types used in the 2-D IDCT block for fixed-point signals. Inputs are first cast to the output data type and stored in the output buffer. Each butterfly stage processes signals in the accumulator data type, with the final output of the butterfly being cast back into the output data type.
When at least one of the inputs to the multiplier is real, the output of the multiplier is in the product output data type. When both of the inputs to the multiplier are complex, the multiplication result is in the accumulator data type. For more information on the multiplication of real and complex numbers, see Multiplication Data Types.
 Wen-Hsiung Chen, C. Smith, and S. Fralick. “A Fast Computational Algorithm for the Discrete Cosine Transform.” IEEE Transactions on Communications 25, no. 9 (September 1977): 1004–9. https://doi.org/10.1109/TCOM.1977.1093941.
 Zhongde Wang. “Fast Algorithms for the Discrete W Transform and for the Discrete Fourier Transform.” IEEE Transactions on Acoustics, Speech, and Signal Processing 32, no. 4 (August 1984): 803–16. https://doi.org/10.1109/TASSP.1984.1164399.