DSPRelated.com
Forums

Aliasing in MDCT

Started by Unknown January 15, 2009
Why exactly does MDCT introduce time-domain aliasing? From the 2M
samples, the MDCT transforms to M samples, before the IMDCT transform
back to 2M samples. From my understanding going from the frequency
domain to the time domain using IMDCT, the original 2M samples are now
only represented by M samples.
But where exactly does the time-domain aliasing occur in the
reconstructed signal, and why?
> But where exactly does the time-domain aliasing occur in the > reconstructed signal, and why?
In most applications, such as audio compression, the aliasing is directly from the transform. You can go to the frequency domain and back without any aliasing, using the DFT, DCT, etc. If you modify the data in the frequency domain, as the compression algorithms do, when you convert back to the time domain you will get aliasing. This is true with most transforms, hence the different methods such as fast convolution (overlap and add), different TDAC methods, etc. Hope that helps.
casper.ptrsn@gmail.com wrote:
> Why exactly does MDCT introduce time-domain aliasing? From the 2M > samples, the MDCT transforms to M samples, before the IMDCT transform > back to 2M samples. From my understanding going from the frequency > domain to the time domain using IMDCT, the original 2M samples are now > only represented by M samples. > But where exactly does the time-domain aliasing occur in the > reconstructed signal, and why?
As I understand it: Let's say M is 1K and the sample rate is 8K/sec. Your double-block is 2K samples or 1/4 sec. Somewhere in that block, a "tick" happens. It contains all frequencies and shows up in all bins. When you do the inverse, the frequencies show up across the whole time interval, not lined up in a distinct "tick". The symmetries of the transform in conjunction with partial overlap of adjacent blocks are supposed to cancel this out. I have never tested this myself, but it sounds very good when I listen to it.
Thank you both for your response.


Iif you consider just taking IMDCT(MDCT(x)) where x is 2M samples, and
nothing else (no altering in the frequencydomain, just the inverse
transform immediately applied to the forward transform), why exactly
does that give me time-domain aliasing? I cant really wrap my head
around it.
casper.ptrsn@gmail.com wrote:
> Thank you both for your response. > > > Iif you consider just taking IMDCT(MDCT(x)) where x is 2M samples, and > nothing else (no altering in the frequencydomain, just the inverse > transform immediately applied to the forward transform), why exactly > does that give me time-domain aliasing? I cant really wrap my head > around it.
Again, any particular waveform feature (such as a pulse) gets spread across the whole inverse transform. Unlike in a IFFT where all the fiddly little phase numbers add up to make the wave shape just right, the MDCT only has frequency numbers and they may or may not add up to the right wave shape. The overlap-add business is supposed to cancel that out & make the wave shape correct. As I understand it.
That actually makes sense to me. At least more than what I had. Just
two more things: When you say phase numbers, and frequency numbers,
what exactly do you mean?
On 2009-01-15 13:33:20 -0400, casper.ptrsn@gmail.com said:

> Thank you both for your response. > > > Iif you consider just taking IMDCT(MDCT(x)) where x is 2M samples, and > nothing else (no altering in the frequencydomain, just the inverse > transform immediately applied to the forward transform), why exactly > does that give me time-domain aliasing? I cant really wrap my head > around it.
Assuming the DCT means Discrete Cosine Transform and M is something like Midpoint the 2M inputs while be assumed to have a symmetry so that there are only M independent values. The transform will not need the symmetry (it is built into the definition) so only has M values. The inverse will give back a sequence of length 2M with symmetry. DCTs are typically used in circumstances where edge effects are not welcome and these can often be lowered by the use of symmetry. Citing a full name for an acronym and perhaps even a standard source for some definitions will lower the confusion about what you are discussing and even show that your question is more that just confusion on not knowing what the definitions are. When you do not understand some derivation it helps to cite the source of the derivation.
The MDCT is the Modified Discrete Cosine Transform. And yes as you say
the (M)DCT indeed has an symmetric assumption about the signal or
block of a signal. So if I'm reading what you're saying correctly, the
IMDCT will return 2M samples that are symmetric even though the
original samples that was transformed with MDCT are not, and that this
is the cause of the aliasing?
On 2009-01-15 16:25:46 -0400, casper.ptrsn@gmail.com said:

> The MDCT is the Modified Discrete Cosine Transform. And yes as you say > the (M)DCT indeed has an symmetric assumption about the signal or > block of a signal. So if I'm reading what you're saying correctly, the > IMDCT will return 2M samples that are symmetric even though the > original samples that was transformed with MDCT are not, and that this > is the cause of the aliasing?
M for Modified can mean many diferent things so has little information. There are at least four common DCTs! The DCT will be determined by that portion of its input that satisifies the symmetry condition. You can add as much non-symmetric input with a zero symmetric portion as you like and it will not change the output, assumming that your Modified is something rasonable. That is a basic property of symmetry conditions. Perhaps what you are calling aliasing is really rejection of the non-symmetric portion.
On 15 Jan., 22:10, Gordon Sande <g.sa...@worldnet.att.net> wrote:
> M for Modified can mean many diferent things so has little information. > There are at least four common DCTs! > > The DCT will be determined by that portion of its input that > satisifies the symmetry condition. You can add as much non-symmetric > input with a zero symmetric portion as you like and it will not change > the output, assumming that your Modified is something rasonable. That > is a basic property of symmetry conditions. > > Perhaps what you are calling aliasing is really rejection of the > non-symmetric portion.
So what you're saying with the symmetry condition is that if I input X samples, the symmetry condition applies only to the X/2 samples, and thereby the X/2 + 1 ... X samples can be either symmetric or asymmetric or zero or... whatever? If that's correct, giving the alternating even and odd boundary conditions used in DCT Type-IV, then I should be able to see: a) The other half of the input exactly mirrored / exactly symmetric to the first half ? and, b) The other half of the input exactly mirrored BUT with its sign changed (i.e. if X is my inputvector then X(1) could be 4, and X/2 + 1 would be -4) ? I hope that made more sense.