| • Science | • People | • Locations | • Timeline |
The most common variant of discrete cosine transform is the type-II DCT, which is often called simply "the DCT"; its inverse, the type-III DCT, is correspondingly often called simply "the inverse DCT" or "the IDCT".
Two related transforms are the discrete sine transform (DST), which is equivalent to a DFT of real and odd functions, and the modified discrete cosine transform (MDCT), which is based on a DCT of overlapping data.
The DCT, and in particular the DCT-II, is often used in signal and image processing, especially for lossy data compression, because it has a strong "energy compaction" property: most of the signal information tends to be concentrated in a few low-frequency components of the DCT, approaching the optimal Karhunen-Loève transform for signals based on certain limits of Markov processes.
For example, the DCT is used in JPEG image compression, MJPEG video compression, and MPEG video compression. There, the two-dimensional DCT-II of 8x8 blocks is computed and the results are filtered to discard small (difficult-to-see) components. That is, n is 8 and the DCT-II formula is applied to each row and column of the block. The result is an array in which the top left corner is the DC (zero-frequency) component and lower and rightmore entries represent larger vertical and horizontal spatial frequencies. For the chrominance components, n is 16 but the frequency components beyond the first 8 are discarded.
A related transform, the modified discrete cosine transform, or MDCT, is used in AAC, Vorbis, and MP3MP3 (or, more precisely, MPEG-1/2 Audio Layer 3 is an audio compression algorithm capable of greatly reducing the amount of data required to reproduce audio, while sounding like a faithful reproduction of the original uncompressed audio to the listener. audio compression.
DCTs are also widely employed in solving partial differential equationIn mathematics, and in particular calculus, a partial differential equation PDE is an equation involving partial derivatives of an unknown function. The idea is to describe a function indirectly by a relation between itself and its partial derivatives, ras by spectral methods, where the different variants of the DCT correspond to slightly different even/odd boundary conditions at the two ends of the array.
Formally, the discrete cosine transform is a linearThe word linear comes from the latin word linearis which means created by lines''. In mathematics, a linear function f ''x is one which satisfies the following two properties (but see below for a slightly different usage of the term): Additivity: f ''x +, invertible functionIn mathematics, a function is a relation such that each element of a set (the domain is associated with a unique element of another (possibly the same) set (the codomain not to be confused with the range . The concept of a function is fundamental to virtu F : Rn -> Rn (where R denotes the set of real numbers), or equivalently an n × n square matrix. There are several variants of the DCT with slightly modified definitions. The n real numbers x0, ..., xn-1 are transformed into the n real numbers f0, ..., fn-1 according to one of the formulas: