Hello all, This is my first post in this forum and glad to be here. I am currently studying about Fourier transforms in discrete time domain and bumped into the following doubt. As per book, what I understand is that for discrete time aperiodic signals the frequency components ranges from -pi to +pi continuously. Now say I take two sinusoid component of some signal, Cos(2pi(n/4.5)) and Cos(2pi(n/9). These components have a fundamental frequency of 4pi/9 and 2pi/9 respectively. But when I plot them, I notice both seem to have the same fundamental period as 9 samples/oscillation. I have uploaded my plot above. the blue plot indicates Cos(2pi(n/4.5)) and the red on is Cos(2pi(n/9)). If they both the same fundamental period, they also should have the same fundamental frequency. But as per their equations the frequencies vary. Please let me know if I have missed some detail.
It looks to me like the blue has twice the frequency, half the period of the red. Why do you think they have the same period?
What makes you think they have the same fundamental frequency? Plot the values of both functions at increments of dn = 0.1 or even finer and I think you will start to see what is going on.
Thanks for the reply. If both were analog symbol, then obviously the blue plot is twice the frequency of the red plot. But, I read somewhere that fundamental period of a discrete signal is defined as p which satisfies the equation Cos(2pi*f*n + p) = Cos(2pi*f*n). My understanding of this expression is that the sine wave should exactly repeat itself after the fundamental period, which the blue plot fails to do if its time period is half of red plot. Again, in case of discrete domain, if I am forced to take p and n as integers, then the least value of p would be 9 for the above example. And, the above signal equations I guess are independent of sampling frequency, since how much high I increase the sampling frequency, I can bring a similar plot with some higher frequency sine wave.
It's confusing when your text describes sinusoidal signals, cos(2 pi n/value) but your picture shows angular, line segmented, squared-off non-sinusoids. Yes, if you are defining your blue signal exactly as in the picture then it has only two cycles. But those are not pictures of pure cosine signals.
I guess the picture has failed to express my point. The plot was done by self in matlab for illustrative purposes. The expressions I used for the plot are, n = 0:18; y = cos(2*pi*(n/4.5)); //blue line z = cos(2*pi*(n/9)); // red line So, now I have two sampled cosinusoidal signals, sampled at some frequency(please ignore the plot if it makes a confusion). Here expression y is has an angular frequency of 2pi radians per 4.5 samples and z has an angular frequency of 2pi radians per 9 samples. If I had not done sampling and looked at the continuous version, then y is twice the frequency of z. But because of the generic expression for periodicity, Cos(2pi*f*n + p) = Cos(2pi*f*n) where p is the time period, the time period for both the signal appears to be 9 samples. Also, kindly note only after the 9th sample the signal repeat itself in both the cases hence the time period is 9 in both cases(shown in the plot). I wanted to know, how 2 signals of different frequencies appear to have same time period. Is it because, of any limitations in the above test for periodicity or does it generally happen in sampling a signal.
I guess the picture has failed to express my point. The plot was done by self in matlab for illustrative purposes. The expressions I used for the plot are, n = 0:18; y = cos(2*pi*(n/4.5)); //blue line z = cos(2*pi*(n/9)); // red line So, now I have two sampled cosinusoidal signals, sampled at some frequency(please ignore the plot if it makes a confusion). Here expression y has an angular frequency of 2pi radians per 4.5 samples and z has an angular frequency of 2pi radians per 9 samples. If I had not done sampling and looked at the continuous version, then y is twice the frequency of z. But because of the generic expression for periodicity, Cos(2pi*f*n + p) = Cos(2pi*f*n) where p is the time period, the time period for both the signal appears to be 9 samples. Also, kindly note only after the 9th sample the signal repeat itself in both the cases hence the time period is 9 in both cases(shown in the plot). I wanted to know, how 2 signals of different frequencies appear to have same time period. Is it because, of any limitations in the above test for periodicity or does it generally happen in sampling a signal.
The discrete time plots should actually be drawn as stem plots, not connect-the-dot plots which indicate a continuous-time function. A discrete time function is only defined at discrete values of time.
They don't have the same period. The period, T, of a continuous-time periodic signal is the amount of time it takes to complete one cycle. So T has units of seconds/cycle. The period, N, of a discrete-time periodic signal is the number of samples it takes to complete one cycle. So N has units of samples/cycle. In both cases, 1 cycle is 2pi radians. The frequency, w, of a continuous-time periodic signal is how many radians elapse per unit time, or radians/second. The frequency, Ω, of a discrete-time periodic signal is how many radians elapse per sample, or radians/sample. So, as you've stated, y has an angular frequency of Ω_y = (4pi/9) radians/sample and Ω_z = (2pi/9) radians/sample. Consider that your initial post indicated that this section of your text was dealing with aperiodic signals. What if y used 4.312 instead of 4.5? There is nothing that says that the period of a signal is going to be an integer number of samples. In fact, this will seldom be the case.
You don't see the sine shape because your step size is too large. n = 0:18; gives you an array from 0 to 18 with a step size of 1 Try this instead: n = 0:0.1:18; This will give you a step size of 0.1
This is what I recommended, but it may or may not be able to clear up the confusion since, in a discrete-time system, the value of the function at a non-integer sample value is technically undefined. What the OP needs to get their mind around is that the discrete-time function, in this case, is a sampling of a continuous-time function and plotting the continuous-time function as such (e.g., a connect-the-dot plot) and plotting the discrete-time function as such (e.g., a stem-plot) may help clear things up.
So, the time period could be any rational number rather than being a restricted to an integer. This clears things up. Thanks for the feedback. But I have one more doubt from the discussion above. There were discussion regarding using plot and stem command. I am advised to use stem for discrete signals by my faculty too. But I invariably use the continuous plot for discrete signals since I can see the signal trend clearly by joining the points rather then having them scattered. I don't see the advantage of a discontinuous signal begin looked in a stem plot. I would like to know your take on this particularly what advantage does stem plot provide over continuous plot?
It doesn't have to be a rational number. The period could be some multiple of, say, sqrt(2). There are two problems with using a continuous plot for a discrete signal. First, it implies that the function has values at places where it doesn't and therefore leads you to believe things that aren't necessarily true. You say that you can see the signal trend clearly, but consider the higher frequency signal between n=4 and n=5. The "trend" you see is that it is flat there, but the actual underlying signal that is being sampled is anything but flat. You should do a stem plot for the actual signal and then, if you want, also connect them with a dashed line (or possibly a very light solid line) so that you can infer some information about the underlying continuous-time signal. But always keep in mind that it is just that, an inference.