 So, warm welcome to the fifth session of the third module of signals and systems. We had begun to look at a sine wave being sampled in the previous session and we saw that if you sampled a sine wave uniformly that means at points which are spaced with an equal spacing between subsequent point between adjacent points then the following question needs to be answered namely what are all the sine waves which would have those samples at those points and we had answered that question graphically. In fact, we had answered it graphically for a specific instance, but the general principle becomes obvious from that instance. Let us take a couple of seconds to recapitulate what we had come up with as an answer. The answer was that between two subsequent samples you could be losing one cycle or two cycles or three cycles or any positive integer multiple of cycles and again for each of these possibilities of losing you could either lose the whole cycle or you could just fall short of losing that cycle which means that you could arrive at the next point either on the correct edge or on the wrong edge. So for each positive integer possibility of losing a cycle there are two additional possibilities as far as the sine wave that can contribute those samples are concerned. One where you come back on the same edge and one where you come back on the wrong edge. Now what we said is that we need to write this down mathematically. Let us do that. So let us write down just one sine wave here. Just that one sine wave that we are sampling A naught cos omega naught t plus phi naught and of course we agree that omega naught is 2 pi by t naught. t naught is the time period. Now where does the non-uniqueness come from? Of course the non-uniqueness first comes from sampling. So effectively what is the process of sampling doing? The process of sampling is creating many other frequencies let us write that down. What is the process of sampling doing? Sampling creates many ghost or monster frequencies you might call them which have the same samples at the same points. So in other words what we are saying is that you have many other frequencies let us call them omega k you know essentially A naught cos omega kj t plus phi kj such that of course you know you remember we had said that j corresponds to the two possibilities of correct and wrong edge and k is all the positive integers essentially belongs to script z plus the positive integers. Now what are these omega kj's and what are the corresponding phases? We need to write that down. So where will these omega kj's come from? Well they come from the fact that x of t which is A naught cos omega naught t plus phi naught when sampled at t equal to ns nts gives you x let us use square brackets nts and the non-uniqueness comes from being able to add a phase to this. So if you add plus or minus 2 pi kn here to the phase k over all the integers and n also over all the integers n is essentially the sampling instant k over all the positive integers you know you only need positive integers because you have taken plus and minus and k has a significance now k essentially denotes the number of cycles that you have either completely or almost lost. So if you do that you get A naught cos omega naught nts plus minus 2 pi kn plus phi naught and we can take all this common. You could write A naught cos well let us take n common anyway nts common actually and you have omega naught here and then you have plus minus 2 pi by ts times k and a plus phi naught there. Now of course you recognize that omega naught is 2 pi by t naught t naught is the period. So we can rewrite this we can rewrite this is A naught cos now we will take 2 pi also common A naught cos 2 pi nts in brackets 1 by t naught plus minus k by ts where k has all the positive integer values plus phi naught. Now you will recognize that this expression here is representative of the cycles per second frequencies which are all contributing these samples at these points all possible cycles per second or Hertz frequencies. Now let us look at the situation you see you will agree with me one thing is very clear we of course need to have more than one sample in a cycle. In fact let us take an extreme case suppose I just took one sample in a cycle and I took the sample at the same location in a cycle. I would get the same sample in every cycle there would be no way to distinguish between this and a constant I would not know if the sine wave is of 0 frequency or the sine wave is of a frequency higher than 0 whether there is a sinusoid at all or it is just dc. Now if I took less than one sample in a cycle you are actually considering a possibility that you are almost losing a cycle. So if we have agreed that we have not almost lost the cycle you see we have to some a priori information needs to be there. So if you wish to agree that you are not losing or almost losing a cycle and that is the sine wave that you want to reconstruct then the only choice before you is at least take two samples in a cycle and we will definitely therefore agree that the time interval between samples must be less than the cycle time. So going back to the expression here let us identify the frequencies here the Hertz frequencies are essentially 1 by t0 plus minus k by ts, k equal to 1, 2 and so on and of course ts is strictly less than t0 so if you take the possibility let us say for example the possibility k equal to 1. Now 1 by t0 minus 1 by ts would be negative because 1 by ts is greater than 1 by t0. Now we do not want a negative frequency so what correction can we make? So back to the original expression a0 cos 2 pi n ts 1 by t0 plus minus k by ts plus phi 0 this is the expression but then remember cos alpha is always equal to minus cos of minus alpha. So cos alpha is always equal to cos of minus alpha so you could do a plus minus on the whole bracket here and that means if you did a plus it is as it is if you did a minus let us in fact let us write that down here. So if we take plus we get the same expression on the other hand if we take minus we get the expression so you know it would be minus so in that case see here there is a plus minus and here there would be a minus plus this is important the phase is reversed. Now you know let us take again more specifically for just k equal to 1 and let us use both minus and plus when it is convenient. So let us take plus for 1 by plus 1 by ts plus 1 by t0 which tells you the expression is a0 cos 2 pi n ts into 1 by t0 plus 1 by ts plus phi 0 and take minus for the case where we had a negative frequency so as not to confuse ourselves with a negative frequency. And when we do that we recognize the phase is reversed essentially it is these two frequencies that occur at the loss of one cycle. So when you are losing a cycle and then coming back on the correct edge or losing a cycle almost losing a cycle and coming back on the wrong edge. The same argument could be used for losing two cycles three cycles and so on. But now let us take also to get a full understanding of what is happening here. Let us take the specific instance of the sinusoid that we talked about here where you had a pi by 2 phase gap. So what was the situation here let me write it down in our example in our graphical example in this discussion ts was equal to t0 by 4. So essentially you would see 1 by t0 plus 1 by ts is 5 by t0 and 1 by ts which is 4 by t0 minus 1 by t0 is 3 by t0. Now in fact that will make it very clear if you look at the graphical situation too. So let us draw it again just that part you had a sample here and a sample here there was a spacing of pi by 2 initially this is the true sine wave. Now the false one losing a whole cycle is where this went down went through a whole cycle but came down again on the correct edge. So what is the situation here you have 2 pi plus pi by 2 which means 4 times pi by 2 plus pi by 2 5 pi by 2 spacing and this is the situation of frequency 1 by t0 plus 1 by ts this is actually 5 by t0 as we saw and let me now draw the last one where you had not quite a whole cycle lost but you came on the wrong edge. What is the situation there the situation there would be in fact I leave it to you as an exercise here draw the figure for this case verify the spacing to be 3 pi by 2 instead of pi by 2 which means the frequency becomes 1 by ts minus 1 by t0 which is 3 by t0 I leave this to you as an exercise to verify the whole idea both in terms of frequency and the phase change. We will see more about sampling sine waves in the next session. Thank you.