Modified Discrete Cosine Transform: Difference between revisions

From Hydrogenaudio Knowledgebase
No edit summary
 
(4 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{{stub}}
{{stub}}


 
The '''Modified Discrete Cosine Transform''' ('''MDCT''') is a [[DCT]]-IV transform. The MDCT tries to minimize blocking artifacts. It is common in lossy audio codecs including  [[MP3]], [[Vorbis]], and [[AAC]].  
The [[MDCT]] (Modified Discrete Cosine Transform) is a [[DCT]]-IV transform. The MDCT tries to minimize blocking artifacts. It is common in lossy audio codecs including  [[MP3]], [[Vorbis]], and [[AAC]].  
 


As a lapped transform, the MDCT is a bit unusual compared to other Fourier-related transforms in that it has half as many outputs as inputs (instead of the same number).  In particular, it is a linear function ''F'' : '''R'''<sup>2''n''</sup> <tt>-></tt> '''R'''<sup>''n''</sup> (where '''R''' denotes the set of real numbers).  The 2''n'' real numbers ''x''<sub>0</sub>, ..., ''x''<sub>2''n''-1</sub> are transformed into the ''n'' real numbers ''f''<sub>0</sub>, ..., ''f''<sub>''n''-1</sub> according to the formula:
As a lapped transform, the MDCT is a bit unusual compared to other Fourier-related transforms in that it has half as many outputs as inputs (instead of the same number).  In particular, it is a linear function ''F'' : '''R'''<sup>2''n''</sup> <tt>-></tt> '''R'''<sup>''n''</sup> (where '''R''' denotes the set of real numbers).  The 2''n'' real numbers ''x''<sub>0</sub>, ..., ''x''<sub>2''n''-1</sub> are transformed into the ''n'' real numbers ''f''<sub>0</sub>, ..., ''f''<sub>''n''-1</sub> according to the formula:
Line 9: Line 7:
<center>[[Image:MDCT.png|MDCT formula]]</center>
<center>[[Image:MDCT.png|MDCT formula]]</center>


 
The inverse MDCT is known as the '''IMDCT'''. Because there are different numbers of inputs and outputs, at first glance it might seem that the MDCT should not be invertible.  However, perfect invertibility is achieved by ''adding'' the overlapped IMDCTs of subsequent overlapping blocks, causing the errors to ''cancel'' and the original data to be retrieved; this technique is known as ''time-domain aliasing cancellation'' (TDAC).
The inverse MDCT is known as the '''IMDCT'''. Because there are different numbers of inputs and outputs, at first glance it might seem that the MDCT should not be invertible.  However, perfect invertibility is achieved by ''adding'' the overlapped IMDCTs of subsequent overlapping blocks, causing the errors to ''cancel'' and the original data to be retrieved; this technique is known as ''time-domain aliasing cancellation'' (TDAC).


The IMDCT transforms ''n'' real numbers ''f''<sub>0</sub>, ..., ''f''<sub>''n''-1</sub> into 2''n'' real numbers ''y''<sub>0</sub>, ..., ''y''<sub>2''n''-1</sub> according to the formula:
The IMDCT transforms ''n'' real numbers ''f''<sub>0</sub>, ..., ''f''<sub>''n''-1</sub> into 2''n'' real numbers ''y''<sub>0</sub>, ..., ''y''<sub>2''n''-1</sub> according to the formula:
Line 16: Line 13:
<center>[[Image:IMDCT.png|IMDCT formula]]</center>
<center>[[Image:IMDCT.png|IMDCT formula]]</center>


The MDCT was developed by Henrique Malvar, an engineer now working for Microsoft who had considerable participation in creating the [[WMA]] format.


The MDCT was developed by Henrique Malvar, and engineer now working for Microsoft and that had considerable participation in creating the [[WMA]] format.
== References ==
 
==References==
 
* [http://www.dspguide.com/ch8.htm Discrete Fourier Transform] it's basic properties and applications.
* [http://www.dspguide.com/ch8.htm Discrete Fourier Transform] it's basic properties and applications.
* [http://ccrma-www.stanford.edu/~bosse/proj/node27.html Planet CCRMA] description of the DCT-IV.  
* [http://ccrma-www.stanford.edu/~bosse/proj/node27.html Planet CCRMA] description of the DCT-IV.  
* [http://www.comp.nus.edu.sg/~wangye/publications/Conference%20papers/00027_aes22.pdf Modified Discrete Cosine Transform] a complete research paper on MDCT presented at the 22nd AES conference.
* [http://www.comp.nus.edu.sg/~wangye/publications/Conference%20papers/00027_aes22.pdf Modified Discrete Cosine Transform] a complete research paper on MDCT presented at the 22nd AES conference.


[[Category:Algorithms]]
 
[[Category:Digital Signal Processing]]
[[Category:Signal Processing]]

Latest revision as of 13:07, 5 October 2016

The Modified Discrete Cosine Transform (MDCT) is a DCT-IV transform. The MDCT tries to minimize blocking artifacts. It is common in lossy audio codecs including MP3, Vorbis, and AAC.

As a lapped transform, the MDCT is a bit unusual compared to other Fourier-related transforms in that it has half as many outputs as inputs (instead of the same number). In particular, it is a linear function F : R2n -> Rn (where R denotes the set of real numbers). The 2n real numbers x0, ..., x2n-1 are transformed into the n real numbers f0, ..., fn-1 according to the formula:

MDCT formula

The inverse MDCT is known as the IMDCT. Because there are different numbers of inputs and outputs, at first glance it might seem that the MDCT should not be invertible. However, perfect invertibility is achieved by adding the overlapped IMDCTs of subsequent overlapping blocks, causing the errors to cancel and the original data to be retrieved; this technique is known as time-domain aliasing cancellation (TDAC).

The IMDCT transforms n real numbers f0, ..., fn-1 into 2n real numbers y0, ..., y2n-1 according to the formula:

IMDCT formula

The MDCT was developed by Henrique Malvar, an engineer now working for Microsoft who had considerable participation in creating the WMA format.

References