 Hello everyone, I am Prasanthes Malge, Assistant Professor, Department of Electronics Engineering Walchen Institute of Technology, Swalapur. Today we will see divide and conquer approach for computation of discrete Fourier transform the learning outcome. At the end of the session student will be able to explain the divide and conquer approach for computing DFT. Now, let us see the calculation of endpoint DFT by using divide and conquer approach. Now, DFT of size n can be factored as a product of two integers n is equal to L into m. So, now to understand this let us first represent the signal in a two dimensional array. Now, consider this is a sequence x in half length n. Now, in a two dimensional array we represent it as x l m, where l is the row index and m is the column index. So, now these are the rows from 0 to L minus 1 L number of rows you have and 0 to m minus 1 total m number of rows sorry columns you have. Now, this is x of 0 0, this element is x of 0 1 and so on. So, the total number of elements will be l number of rows and m column. So, l m number of elements which is total equal to n. Now, depending on the relation between n m and l there are two types of mapping possible. Now, if I consider n is equal to this capital M into l plus m, this particular mapping leads to row wise mapping of the signal. It means that the signal is now represented in row wise that is first m number of elements of the signal will be in first row next m number of elements in will be in the second row and so on. Say for example, if you have l and m 0 0, so this 0 0 n will be 0. If I take 0 1 element, so l 0 m 1 means n equal to 1 means x of 1 will come in the first row as a second element. So, this particular mapping n equal to ml plus m leads to row wise mapping. Similarly, if instead of that if you take n equal to l plus ml, this will give you column wise mapping. So, it means here first l elements of x of n will be in the first column, next l elements will be in the next column and so on. Since again here you have l number of rows and m number of columns, so the total number of elements will be l m which is equal to n. So, for discussing this divide and conquer approach, we are considering the two dimensional representation of the signal x n and similar arrangement will consider for the DFT values that is x k as x k is also n point sequence. So, x k 0 to n minus 1 is one dimensional r index by k, now can be represented as x p q. So, now we will use the variables p q for representing it as a 2D array where p will be 0 to l minus 1 and q will be 0 to m minus 1. So, l number of rows and m number of columns as a 2 dimensional array index by p and q. Once again if I use k equal to m p plus q, the mapping will be row wise and if you use k equal to p plus q l, the mapping will be column wise ok. So, now before proceeding further, just try to recall what is the twiddle factor and what are its properties, pause the video for a minute and think on this ok. So, what is twiddle factor? So, twiddle factor is also known as a phase factor which is given by this W n, where W n is equal to e raise to minus j 2 pi by n. Now the properties of twiddle factors are there are two one is symmetry property and another is a periodicity property. So, symmetry property says W n k plus n by 2 will be equal to minus of W k n. So, this is what is approved for that. Similarly, the periodicity property says W n k plus n will be equal to W n k. So, this is how we can show that this relation holds true right. So, basically in this divide and conquer approach we are making use of these properties to reduce the number of computations right ok. Now, let us discuss this. Now, for our approach let us consider the column wise mapping for input x n and row wise mapping for DFT sequence x k. So, with that our x k which is a summation n equal to 0 to n minus 1 x n W n k n can be written as x p q now that two I mean summations m equal to 0 to m minus 1 l equal to 0 to m minus 1 x l m W n k is now m p plus q because it is a row wise mapping and n is equal to l plus m l. So, it is a column wise mapping. So, that DFT equation can be written in terms of a 2D array right. So, now if we expand this if we expand this that is W n m p plus q into l plus m l we get W n m p l W n m l m p second term next is W n l q q l rather next is W n q m l right. So, W n m p l into W n m l m p into W n q l into W n q m l right. So, now from this these terms can be written as now let us take this W n m l m p now we know that m l is nothing, but l into m which is capital N. So, this comes out to be W n n m p now as we know this is actually W n is e raise to minus j 2 pi by n that raise to n m p comes out to be e raise to minus j 2 pi m p and e raise to minus j 2 pi into any integer comes out to be 1 therefore, this factor will be equal to 1 right. So, next term if you take W n q m l this term q m l. So, will be can be written as once again by expanding e raise to minus j 2 pi by n this can be written as W q m n upon l and as n upon l is equal to m. So, this will be W q m m and on same lines the first term is W n m p l this W n m p l can be written as W p l n by m that is W p l l. So, instead of these factors will now use. So, one of the factor is 1 and rest others will be placed by these and now we will write this x p q in terms of this as x p q equal to 1 just now I have interchanged the summations l equal to 0 to l minus 1 W n l q see one of the term W n l q. Now, summation m equal to 0 to m minus 1 x l m now second term is may be W m q m this is W m q m and this whole multiplied by W p l l W p l l. So, the same expression so by simplifying these we have written this. Now, from this now let us understand how to calculate this. So, this equation is same as a previous one. Now, the computation of this can be done in terms of l pointed DFTs and m pointed DFTs. Now remember our signal x l m is the 2 D array it basically has l number of rows and m number of columns right ok. So, in a first step let us calculate this internal bracket that is summation m equal to 0 to m minus 1 x l m W m m q m. We calculate this now if you see for any l these are m number of elements right for any l these are m number of elements means 1 row right first row when l equal to 0 it will be first row when l equal to 1 it will be second row and so on. So, it means what in this step we are calculating the m pointed DFT of each row and store it as f l q for q equal to 0 to m minus 1 right. So, in the first step we will calculate these total how many DFTs l number of DFTs right because we are calculating it for each row l equal to l minus 1. So, there are l number of m point DFTs we are calculating in this step right ok. In a second step now for if you see this bracket we multiply this bracket by W n l q right W n l q. So, g we will represent it as g l q which is equal to W n l q into f l q right for 0 to l minus 1. So, basically this in second step we are multiplying each of these values by this constant W n l q right ok. And in the third step now this is once again a 2 D array of l number of rows and m number of columns and if we represent this as g l q. So, it will be l equal to 0 to l minus 1 g l q W l p l right. So, here we will compute l point DFT of each column ok l equal to 0 to l minus 1 means 1 column for each q right q equal to 0 it will be first column q equal to 1 it will be second column and so on. So, we will calculate l point DFT of each column and store it as x p q right. So, here we will get finally, the DFT right the total size of the DFT will be l into m. So, it will be equal to n point DFT and then we have to collect it row wise which gives us the n point DFT right. So, now we will compare this with the direct computation method right. Now, let us discuss the computations required for this. Remember in step one we are computing l number of m point DFTs and for each m point DFT we have m square multiplications. So, total number of multiplications will be l m square. In second we have l number of rows and m number of columns. So, there will be l m multiplications. Third we are computing m number of l point DFTs. So, for 1 point 1 l point DFT l square multiplications. So, for m number of DFTs m l square multiplications. So, which gives us the total sum of this as n into m plus l plus 1. So, this number if you compare it with corresponding direct computation that is n square which is approximately half right. So, with this approach the number of complex multiplications reduced and same way if you count the number of additions for l number of m point DFTs for 1 m point DFT we need m into m minus 1. So, for l you need l into m into m minus 1. In second step there is no addition in third step once again for computing m number of l point DFT. So, m l into l minus 1. So, which gives us the total once again n into m plus l minus 2. So, in case of direct computation it is actually n into n minus 1 and now that n minus 1 comes out to be m plus 1 minus 2. So, which is once again nearly half of that right. So, this is how this divide and conquer approach is useful it needs lesser number of computations as compared to direct computation. So, the reference is digital signal processing by Rokies. Thank you.