 So, as promised let us look at the problem of counting prime numbers and this is the main topic of this course anyway. So, let us see where we go from here and we will slowly bring in zeta function and start studying its properties. So, the motivation for this is simply the following question. So, given an x how many prime numbers are there in the interval 1 to x. This has been around for a long time sort of fascinated a lot of mathematicians who tried to come up with some formula capturing this number of primes and pretty quickly people realize that there does not exist any nice formula for this because the prime numbers seem to be have very randomly and. So, any sort of nice formula expressing exact number of prime numbers in this interval is not likely to exist at all. However, it was again observed and particularly by Goss who did huge amount of calculations about number of prime numbers in an interval that there is definitely some pattern here. In fact, what he observed was that the number of prime numbers are very close to x by log x. They are not exactly equal to x by log x, but are within a small distance away from x by log x and this was pure numerical hand calculation at that time there were no computers. So, he used to in all his spare time it is said he used to compute tables of prime numbers and then he would based on those calculations he made a conjecture that this is conjecture well it was made in some different forms by others also, but very specifically highlighted by Goss. So, if we denote by pi x the number of primes in the interval 1 to x then pi x tends towards x by log x as x goes to infinity. So, it is not equal to what tends towards which is another way of saying that limit x goes to infinity pi x over x by log x tends towards 0 not 0 tends towards 1. So, that is the conjecture motivated a lot of interest around that time which was early 19th century and Riemann who was a student of Goss spent quite a bit of time studying these prime numbers or the density of prime numbers as it is called and it was he as name we have been looking thinking seen is that it was he that came up with this connection of the density of primes with this complex analysis and the zeta function and everything else how lot of things other things like he wrote a very small paper about 11 12 pages long on which was on counting prime numbers or on the density of prime number in which he laid out this whole program define the zeta function. It was still around earlier also, but the complex variant of the zeta function he defined and studied the properties of it made the connection with density of primes made the Riemann hypothesis and derived the conclusions of Riemann hypothesis just about everything he did in that small paper and it is there I will I mean at least translation that paper are there on the web it is very interesting read all of you should go and read it. So, let us trace back the thought process of Riemann from we will not follow completely that, but more or less and at many points in this sequence that I am going to tell you a sequence of steps that I am going to tell you. You will realize that several of these steps seems to be like pulling a rabbit out of hat there is no a priori justification as to why are we doing this or how did this idea come about and that was genius of Riemann that he just came up with so many new ideas in that paper that it is very hard it will be very hard for me to give you a intuition or justification why this idea is being used will realize the use of that idea only when we apply it and do the calculation see yes it does work. In fact, that is the nature of all great mathematical ideas they are all very simple and they all seem like pulling a rabbit out of hat. So, and I will try to point out those ideas at least from my perspective things that I do not understand I will try to point out I do not know why this how this came about, but it has come about. So, let us go back and we are interested in this prime counting function which is pi x. So, let us spend some time on this the pi x is all primes in the interval 1 to x let us write it more mathematically and that can be done by writing something like this that n going from 1 to x and let us write here a notation which would mean p sub where p of n is 1 if n is prime. Now, this is a sum going from 1 to x which is a a variable quantity. So, it is a finite sum not even terminating at a fixed point and analyzing this sum is especially given the quantity inside which is also not very nice it sort of seems to be 1 and 0 at if primes are somewhat randomly distributed it is 1 and 0 with some random probability. Then it becomes easier to analyze if we can transform this finite sum to an infinite sum because then at least we do not have to worry about to up to what point we have to sum up we just sum up all the way. So, one problem is taken care of the problem of p n is still there, but at least the sum in problem is taken care of. So, how do we translate this from to a sum from up to x this is sum to up to x how do we translate this to a sum up to infinity. It is a very straight forward idea that I can write it as n equals 1 to infinity p of n times delta of x by n where delta of m equals 1 if m is between 0 and 1 0 simple just take a delta function you have the infinite sum here just to be careful I should be saying that this is between m is between 0 to less than equal to 1 because x can be an integer and I want to sum up to that. So, that is nice that instead of finite sum now I infinite sum both the limits are well known but the penalty I have paid is I have introduced another funny function delta here with a multiplier to p n which was to begin with not so easy function to analyze. But then just recall last lecture this delta we have a nice handle on we can stick in place of delta where are we p n and what can I write for delta x over n if you recall what was that function it was 0 between 0 and 1 and then it would step up to 1 all the way. The delta function that I want it should be 1 between 0 and 1 and then go down to 0. So, that is different slightly different one that I want. So, you just look at here 1 minus or n by x let us change by n by delta hat n by x n by x if x is bigger than n I think there is something wrong here I think we already had it correct delta and the here should be 0 this delta x by n and here if n is less than x then you want it to be 1 as long as n is less than less than equal to x which means as long as x by n is greater than equal to 1 you want it 1 as soon as x n becomes bigger than x you want it to become 0 and therefore, that. So, we already had it correct. So, now let us invoke that previous theorem and we can write this as now who remembers that integral it was 1 over 2 pi i integral c minus i infinity to c plus i infinity x to now x is now x by n x to the s by n to the s and let us know that we are treating with let us write it z because you have been typically writing z for complex numbers and c is greater than 0 yes. So, I have to be careful here. So, at exactly 1 this does not quite fit n and when do when does this take value exactly 1 when x equals n n is always integer. So, as long as I say that x is let us say half plus integer which is fine I can always count number of primes between 1 and x where x is half plus an integer that number if I can do that I know the number of primes everywhere. So, this is just a simple technical point which I can get around by fixing x always to be half plus integer and that is what we will consider now and forever x is half plus integer. Now, as it turns out that this is fine I can use this, but this is not quite what we would like because see why are we trying to do this we had the if I put it in this formulation now I have a complex integral. So, I will try to see I have what is our goal is to estimate the value here. Now, that I have written it in terms of a complex integral I will use all my complex analysis information to evaluate that complex integral and we saw some examples last time and on all of them the way we did was we want to evaluate the integral on some curve or line. We fix a domain whose one of the boundary is this say line then put other lines there and then use this residue calculus formula to see evaluate the integral along that entire boundary of the domain. Then we say that on all the boundary that we are interested in that we leave aside and all other boundaries we say it goes to 0. So, we can ignore that and therefore, we get this integral of the kind we want right. So, that was the strategy and that is the strategy we are going to use here because that seems like a natural one to do, but if I put my line on which I am integrating as going from minus infinity to plus infinity then I do not have any definition of a domain that for defining a domain in a proper way. So, that whose boundary is well defined I need to limit this integral to a finite curve it cannot be an infinite line. So, that is fine instead of this I can write it as we all in fact, we did evaluate this integral c minus i r to c plus i r x to the z divide by n to the z dz and then there was an error term associated with it how much was that x to the c by r log x by n and here also you get x by n. So, replace this by fine now let us continue with our simplification of this the integrant inside is an analytic function. Moreover as if you look at this let me write it down then I will justify this I am writing in this second part is clear I mean there is just a sum is separated take the, but here what I have done is I swap the summation integral and the reason why I can do it is because this sum is uniformly convergent for absolute value of z greater than 1 why is this uniformly first of all if this is uniformly convergent then sure you can swap summation integral we have seen that. So, why is this uniformly convergent what do we need to show that this uniformly convergent even a p n yes p n is always either 0 or 1. So, as you see p n is all 1. So, what you get is there is zeta function this is zeta function and although we have not seen that zeta function is uniformly convergent. So, let us just write this by the way what is the condition for uniform convergence you take a finite any finite sum and subtract it from the infinite sum take the absolute value that the difference between the two is a value which goes towards 0 as the length of the finite sum increases. So, let us say if the length you take n equals 1 to infinity p n by n to the z and subtract it from n equals 1 to m minus 1 p n over n to the z and look at the absolute value this is less than equal to absolute value n going from m to infinity p n over n to the z this is less than equal to summation n equals m to infinity p n is at most once always. So, it is 1 by absolute value of n to the z which is n to the c z in this integral is going from c minus i r to c plus i r. So, we only look at the real because absolute value you only look at the real part if it is in the exponent. So, it is c and that also tells me let us first do this and then we will come back this n to the c is greater than 1 well not we do not know, but if c is greater than 1 then what is this sum yeah this sum you can approximate with the integral m going to infinity 1 over t to the c d t is within some constant factor of this and this is t to the minus c plus 1 by minus c plus 1 m going m to infinity and this is the place where we use the fact that c is greater than 1. So, the second part of this is 0 and the this is therefore, 1 over 1 minus c 1 over m to the c minus 1 this is and now you see that this is absolutely uniformly convergent because as m tends towards infinity the which is there as the approximation of your sum increases this tends towards 0 irrespective of the value of z that you take. So, that settles the fact that this sum is uniformly convergent, but we need c greater than 1 remember original sum for the delta function was valid for any c greater than 0, but this uniform convergence is not true for any c greater than 0 we have to assume c greater than 1. So, from hence forth we will assume that c is greater than otherwise you cannot say otherwise you sorry how does that help is your question that why is how does uniform convergence help in switching is that what you are asking out to switch because you can show that the result without the switch and result after the switch they are both equal and the way to show that is that your question. So, if and the way to show that is I think I briefly mentioned earlier is to look at let us take this specific case. So, that you look at this integral c minus ir to c plus ir and 1 to m. So, this is the finite sum inside this and let us call this sm now what we know is that this surely is equal to n equals 1 to m integral c minus ir c plus ir because this is a finite sum. So, it is a integral of a finite number of terms which by we know by standard integral theory that this is the sum of the integrals. So, this is fine. So, now let us look at the let us look at s infinity minus sm that is equal to and this is less than equal to this by uniform convergence is one by order 1 by m to the c minus 1 we just derived. So, this is order 1 by m to the c minus 1 times this integral c minus ir to c plus ir x to the z by z dz right and this integral is equal to what you know what this integral equals it depends on whether x is less than 1 or greater than 1 depending on that it is either 0 or 1. So, at most 1. So, this is really order 1 by m to the c minus 1 all right. Now, use the fact s in what is s infinity it is the integral inside the sum sorry the other way the sum inside the integral. So, I am not writing this stuff here that is s infinity minus sm was that finite sum inside the integral, but we know that is equal to that sum n going from 1 to m of integral this is equal to order 1 by m to the c minus 1. Now, take the limit as m goes to infinity the right hand side goes to 0 what happens to the left hand side well this is fixed there is no change to this this tends towards this takes it towards that is infinite sum followed by integral and there absolute difference is 0. So, this says that integral of sum is equal to sum of integral. So, the uniform convergence is critical here if we do not have uniform convergence we do not get this. So, is does that convince you the uniform convergence. So, now coming back to this we have this uniformly convergent for c greater than 1 and this is allowing me to swap the integral with sum we get this inside the sum. And now if you look at this this is well not quite zeta function zeta function had p n equals 1 everywhere, but some close cousin of zeta function right. So, this gives you an idea that yes here is a integral complex integral with something like zeta function sitting inside times x to the z by z which is was the integrand of for the delta function. And you integrate this on this line minus i r plus i r at c greater than 1 this integral is equal to the number of zeros from 1 to n up to this error. So, now we have two jobs well more than two jobs because, but immediate two immediate jobs are first to see what cousin of zeta function this is right because I want to get some handle because this p n being sometimes 0 sometimes 1 I do not even know exactly where it is 0 where it is 1 that is not very good function to analyze cannot really if I start us you know querying about the properties of this we will probably get stuck. We want some nicer function here that is one very important requirement. The second important requirement is to estimate this error term because if this error term is too big then again we will not be able to say much. Now as it turns out so by the way here already is this beautiful idea of translating this finite sum to the infinite sum with the delta function multiplying and which is written as this complex integral. So, this connection between the complex integral and the prime count is established right here and this is a beautiful idea and which is not at all of this incredible insight which led to this connection. Now as it turns out that this particular sum p n over n to the z is not amenable to expression in expression as a nice enough function. So, although the goals were very laudable we started pi x and did manage to establish this connection we cannot really make too much progress from this point. So, we have to restart restart it does not work. So, what the problem is that pi x is messy very messy function to handle. So, what and then we are trying to connect pi x to some cousin of zeta function which is does not seem feasible. So, we do the next best thing we start with a cousin of pi x and try to connect it with some cousin of zeta function. So, at least two levels of indirection and then it works. So, here is a cousin of pi x it is called psi x it is sum of 1 n going from 1 to x of lambda x sorry not lambda x lambda n where lambda n equals log p if n is p to the k. Now pi x had p of n which was 1 precisely when n is prime otherwise it was 0 this is slightly more not general it is it is a function which is non-zero at more points at every prime power it is non-zero and it is non-zero with value log p where p is the prime of which we have a power 0 also. So, I can see this is a close cousin of and as it turns out these two are very very tightly related. In fact, there is a theorem which I am going to prove not today because today the task is to connect this with complex integrals but this theorem is interesting in its own right and it was proven by Riemann's paper as well that the psi x is pi x times log x which is sort of you expect because at every prime instead of 1 there is a log prime that way in fact every prime power there is. So, this kind of relationship one can suspect that psi x would be roughly pi x times log x but what is somewhat unexpected is that the error in that relationship is very very small this error is at most order square root of x this point is clear. So, which this tells us that if I can get a good estimate on psi x we got a good estimate on pi x whatever is the estimate for psi x divided by log x that gives a very very good estimate of pi x as well. So, we restart the whole thing with psi x in place of pi x. So, now psi x is summation n going 1 to x lambda x lambda n sorry this is same as summation going from 1 to infinity lambda n delta x y n this is summation n going infinity right I think this expression is right and again I can interchange this is for c greater than 1 just to make thing work right from the beginning. And let us not worry about error term for the moment let us look at the mean term after exchanging the integral with some we get this and now this the cousin or the assumed cousin of zeta function is this the only difference of course is that instead of p n we have lambda n here. So, how does this get related to zeta function this is how what is zeta function zeta of z and we know that we can write this as product over all prime p we did this long time and 1 over 1 minus 1 over p to the power z is that right yeah that is right because this expresses it as a geometric series and then we can get it. But now that we are started worrying about convergence is we have to see that this is also convergent this product and well requires a bit of an argument what you can see not too difficult that as long as the absolute value zeta is greater than 1 this converges nicely this equality holds. So, let us take this condition the absolute value of z is greater than 1. So, that is the zeta function now if you took back at this lambda n the way is defined it is 0 whenever n is not a prime power. So, this sum is actually only a sum over prime powers and in fact, same was the case with summation n p n over n together that was only a sum over primes whereas, in zeta function this is sum over all n. So, to convert zeta function as a sum over primes this gives a clue zeta is a product over all primes. So, how do you convert a product into a sum standard way you take log but now this sum as all these funny creatures logarithms you want to get rid of them how do you get rid of them again standard take derivatives differentiate left hand side what do you get zeta prime z over zeta z differentiate this side what do you get what a derivative of this 1 minus 1 over p to the z. So, this is well 1 is of course, goes away then there is a minus here and then differentiating 1 over p to the z that is e to the minus z log p you differentiate that you get minus log p out. So, minus log p and the rest stays the same p to the minus z divide by 1 minus 1 by p to the z any problem what is it you do not follow how do you get this let us go step by step differentiate log you get 1 minus 1 by p to the z now you will differentiate the insides the insides while 1 goes away. So, you get minus and then you will differentiate 1 by p to the z that e to the z log p by e to the minus z log p actually. So, when you take derivative of that with respect to z you get minus log p popping out and e to the minus z log p remains e to the minus z log p which is same as p to the z. So, that for you get some minus some I am taking minus outside some over prime p's and then you get log p at the top because that minus minus becomes plus and here you get p to the z here. So, you get I write it as p to the z 1 minus 1 by p. Now, I express 1 minus 1 by p to the z as a geometric series log p times by p to the z of course, and then this geometric series which is j going from 1 to infinity 1 by p to the j z or is it 1 or this goes from 0 to infinity. And there is a p to the z sticking outside you take it inside all that happens is that j starts going from 1 to infinity you get this. Now, what is this sum? Look at this is running over all primes p running over all j going from 1 to infinity and the number inside that you look at is p to the j. So, this is essentially running over all prime powers sum over all prime powers and the inside is log p divide by that prime power raise to power z. Therefore, this is precisely correct. So, that is precisely the cousin of pi x that we define. This is also an inspired idea to consider psi x instead of pi x and this fits in perfectly. So, let us go back to this and write therefore, psi x is 1 over 2 pi i c minus i r c plus i r and inside the integral the integrant is this we know exactly what this is. This is zeta prime over zeta is minus of this. So, minus zeta prime over zeta then x to the z by z d z plus this error term. So, this looks very good. This is now in a very nice shape the complex integral. If you can handle the error term and get a nice bound on the error term then we are right on track to estimating psi x because that all we need to do is to estimate this integral and we know tools to estimate this integral. This is on a line we will choose an appropriate domain integrate over the boundary of domain use Cauchy's theorems to get the integral value and then try to make the other boundaries of domain go to 0 or become very small if not 0 because we are willing to tolerate some error in the estimation anyway. There is already some error here in this part there is already some error. So, there is already some error here in this part. So, even if there is an error estimating the integral that is fine clear to everyone. So, we have established this that is enough for today and next time our first task will be to get a handle on this error term exactly how large this is naturally it will be a function of r and we want to get it to make it as small as possible. Any questions and once of course we get a handle on this then we get down to integrating this function