Lecture 14: 02/15/2012

Now that we’ve wrapped up the FFT and polynomial multiplication, we can focus on applying it to the 3SUM problem.

A slight modification of the 3SUM problem, which we can call the average, asks if there is a length 3 arithmetic progression in an array. Alternatively, we can ask if there are three evenly spaced “1” bits in a binary number.

We model a number Z written in binary as a polynomial A(x) = b_0 + b_1 x + b_2 x^2 + … + b_{k-1} x^{k-1} where k = log Z and b_i = 1 if the ith bit of Z is a “1” and b_i = 0 otherwise.

Now, let’s look at the convolution of A with itself, i.e., [A(x)]^2 = \sum_{i=0}^{2k-2} c_i x^i where c_i = \sum_{j=0}^{i} b_j b_{i-j} = \sum_{j+l=i} b_j b_l.

To examine three evenly spaced bits, we can look at the endpoints of the of the sequence, or the middle of the sequence. Hence, if the mth bit of Z is a 1, we can look at c_{2m} and check if its bigger than 1. It will be at least 1, since the x_m term in A is multiplied by itself. If it is bigger than 1, then there is a pair of indices that denote the endpoints of an evenly spaced sequence of 1’s with the mth bit as the middle.

At the end, we wrapped up by discussing the FFT in regards to the primitive root of unity and how feasible it is to find it for a certain field.

Don’t forget that the midterm is next week on Wednesday, so study hard!

On friday, Professor Blum will wrap up the last part of the Union-Find analysis and start on Splay trees. Please make sure to read these relevant sections in Kozen before the next lecture.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s