 This lecture is part of an online commutative algebra course, and will be about flatness of completions. So to motivate this, we first of all recall that if we've got a ring R and a prime ideal P, we can construct the localization R sub P, where you sort of invert everything that's not in P. And we showed that R P is a flat R module. And we proved this in two steps. First of all, if we've got a module, we can also localize it, and the operation taking M to M P preserves exactness. The second thing we showed is that the localization of M at P is naturally isomorphic to M tensored with R P. And these two facts combined show that tensoring with the localization R P preserves exactness, so R P is flat. Well, we can not only localize at an ideal, we can also take the completion of R at an ideal. So you recall this is the completion is the inverse limit of R over I to the N, where I is some ideal. And completion is in some ways a sort of stronger version of localization. And what we want to do, this lecture is to show that R hat is a flat R module if R is notarian. And we're going to try and copy the proof for localization. However, there are some slight complications because the completion of a module isn't always obtained by taking the module and tensioning with the completion of a ring. And completing a ring doesn't always preserve exactness. So although we're going to try and sort of imitate this proof, there will be some extra complications. So the first step is to show that if A0 goes to A, goes to B, goes to C, goes to naught is exact. So these are all R modules. Then naught goes to A hat, goes to B hat, goes to C hat, goes to naught is exact. If A, B and C are finitely generated. So this is the analog of the corresponding result for localization. So if we're localizing at a prime ideal, then we know that naught goes to A, P goes to B, P goes to C, P goes to 0 is also exact. Before giving the proof of this, let's just show that it does actually fail if A, B and C are not finitely generated. For example, you could take the sequence of modules over the integers where this is just the rational numbers. And if we now complete at the prime 2, then this becomes the two added integers. So if we complete the rationales at the prime 2, we just get 0. And if we complete this at prime 2, we just get 0. So this map here is not injective. So completion doesn't always preserve exactness. So we want to show that it does at least preserve exactness if A, B and C are finitely generated modules. So let's assume that this is exact. And then we notice that the sequence naught goes to A over I to the N, B intersection A goes to B over I to the N, B goes to C over I to the N, C goes to naught is exact. And this looks a bit funny because you think this ought to be A over I to the N, A. But if we put A over I to the N, A there, then this sequence isn't necessarily exact. It's quite easy to find examples of this. For instance, if we look at the sequence, naught goes to Z goes to Z goes to Z over 2 Z goes to naught. And this is multiplication by 2. And we take the ideal I to be 2. Then if we try quotienting out by this ideal, we get Z over 2 Z goes to Z over 2 Z goes to Z over 2 Z goes to 0. And this map here is not injective. So we really do have to use this funny expression here instead of I to the N, A. Anyway, what we want to do is to take the inverse limit of these sequences and show the inverse limit is exact. And you remember that's not always true that there's a sort of funny Mithag-Leffler condition. Well, in this case, the Mithag-Leffler condition automatically holds because A over I to the N, B intersection A is the image of A over I to the N plus 1, B intersection A. So this map is onto, and that's the sort of easy version of the Mithag-Leffler condition. So this means the inverse limit of A over I to the N, B intersection A. Mapping to the inverse limit of B over I to the N, B mapping to the inverse limit C over I to the N, C goes to naught is exact. And this thing here is the completion of B and this thing here is the completion of C. And this thing here, well, it's not entirely obvious whether or not it's the completion of A. So we've got another problem we have to deal with is the limit of A over I to the N, B intersection A equal to the inverse limit of A over I to the N, A. So let's put a question mark there. So this is certainly equal to the completion of A and we want to know if these two are equal. Well, that's true because we now have the art in re-slammer, which shows us that the filtration I to the N, B intersection A is stable, which means eventually each term is I times the previous term. And this term implies that the inverse limit of A over I to the N, B intersection A is equal to the inverse limit of A over I to the N, A. So this inverse limit really is the completion of A. You notice the art in re-slammer needs A, B and C to be finitely generated modules and fails in general if they're not. For example, if nought goes to Z, goes to Q, goes to Q over Z, goes to nought as exact. Then we notice that the sequence 2 to the N times Q intersection Z is not stable. So the stability result really does require finite, finite generation. Anyway, the conclusion of this is that nought goes to A hat, goes to B hat, goes to C hat, goes to nought is exact. So that's the first lemma. This is the analog of saying that nought goes to A P, goes to B P, goes to C P, goes to nought is exact. So this actually holds for all modules. This only holds for finitely generated modules over a notarian ring. So the second thing we want to prove is following lemma, which says that if M is finitely generated over a notarian ring, then the map from M tensor over R hat to M hat is not exact, is an isomorphism. Here we're taking completion with respect to some ideal I. Let's first of all notice that this is false if M is not finitely generated. In fact, if M is not finitely generated, this map here doesn't need to be injective and it doesn't need to be surjective. If we take M to be the rationals over the integers and we take the ideal to be 2, then we see that the completion of M is just 0, which is not equal to M tensor over Z hat, which would be the two added numbers. So this map here need not be surjective. On the other hand, it need not be injected, because if you take M to be the sum of an infinite number of copies of Z, then we see that M tensor over Z with Z hat is just the sum of an infinite number of copies of Z hat. However, you can see that the completion of this is actually bigger than this, if you stop and think about it, because it is elements that have non-zero components in each of these places. So the conclusion of this is that taking completion is really rather badly behaved operation for modules that are not finitely generated. Anyway, we now want to get to the proof that M tensor over R with R hat is isomorphic to M hat for M finitely generated. And if M is finitely generated, then we can write nought goes to N, goes to F, goes to M, goes to 0, where this is a finitely generated free module and this is a finitely generated module because we're working over in a notarian ring. And now let's look at the following sequence. We tense our hat with this sequence and this is exact because our hat tensed with anything is right exact. I mean, we're trying to show it's left exact, but in the meantime, we at least know it's right exact. And now we compare this with the following sequence. We map this to N hat, we map this to F hat, we map this to M hat and we map that to 0. And now we know this sequence is exact because we just proved that in the previous lemma. And this map here is an isomorphism. So this is an iso as F is free and finitely generated. So finitely generated free modules. It's very easy to check that this is an isomorphism. Next, we show that this map here is onto. So let's mark this as this is step one. So step two, this map here is now onto. And that follows easily from the fact that this is an isomorphism and this map here is onto. So if we've got anything here, we can just lift it to there, lift it to there and then it's the image of something there. So what we've shown is that if M is a finitely generated module, then our hat tensor M goes to M hat is onto. Well, now we can apply this to N which is a finitely generated module. So step three, we know that this map is now onto. Well, now step four, we can apply the five lemma. Well, we're going to apply the five lemma by extending this a bit. So we're going to apply the five lemma to this sequence of five modules and this sequence of five modules. And the five lemma says that if that's an isomorphism and that's an isomorphism, this is onto and this is into then this is an isomorphism. So this implies our hat tensor M goes to M hat is an isomorphism. So that's the end of the proof of the lemma. It shows that for finitely generated modules, this holds. Now we want to show that our hat is flat. Well, you remember this is the same as showing that tour one of our hat with M is equal to zero for all M. And now we notice that this is enough to show for M finitely generated. That's because tour one commutes with direct limits. And also any module is a direct limit of its finitely generated submodules. I should say it commutes with maybe filtered. Yeah, direct limits will do. But for finitely generated modules, we know that our hat tensor over R with M is isomorphic to M hat. And we know that for finitely generated modules, M goes to M hat preserves exactness. So tour one of our hat M is equal to zero for M finitely generated. So for all M, so our hat is flat. So that shows that over a notarian ring, any completion is a flat module. Well, how do you use this? Well, we quite often want to move modules from a ring R to its completion. And how do we do this? Well, there are two obvious ways to do this. There's a bad way to do it, which is take M to M hat. And there's a good way to do this, which is to take M to M tensor over R with R hat. Now these are actually the same for M finitely generated as we showed earlier. But in general, this one tends to give us the wrong answer. So let's just see a simple example where it gives the wrong answer. Suppose we've got the sequence over the integer z goes to Q goes to Q over z goes to zero. And we want to turn this into a sequence of modules over z hat. Let's take the ideal to be, say, just the two added numbers. Then if we take completions, we get nought goes to z2 goes to nought goes to nought goes to nought, which is definitely not what we want. I mean, this isn't exact and these modules become zero and it's really rather a mess. On the other hand, if we tensor with z hat, so this is just the two added integers, then we get nought goes to z2 goes to two added numbers goes to Q2 over z2 goes to nought. And this is a this is a much nicer sequence and is the correct analog of this sequence here over the two added integers. So to summarize, completion is just badly behaved for modules that aren't finitely generated. And instead of taking the completion for these modules, you should just tensor with the completion of your ring. And this behaves a lot better. OK, that's enough about completions. The next few lectures will be about the dimension of rings.