 So you recall that a Euclidean domain is an integral domain which has a Euclidean function, a Euclidean norm, which that Euclidean norm allows you to have some type of division algorithm that given any two elements, there exists a unique quotient and remainder between those elements so that that remainder has some type of minimality condition attached to it. Integral domains are very important types of, excuse me, Euclidean domains are very important types of integral domains. We also talked about before that if you take the polynomial ring over a field or a skew field, that itself doesn't make it a field or a skew field, but what you do get is if you have a polynomial ring over a coefficient field, you do get a Euclidean domain and that's what I want to prove in this video. That is for polynomial rings with the right situation, you actually do get the division algorithm becomes Euclidean domain. Let's be explicit about this. Suppose we have some field f, then if we have two polynomials f and g inside of the polynomial ring f and joint x and assuming that g is a non-zero polynomial, then in fact there exists unique polynomials q and r such that f of x equals q of x times g of x plus r of x where r of x is either the zero polynomial or its degree is strictly smaller than g. Now let me remind you that for the, because f is a field, it's in fact an integral domain. Every field is a domain of integral domain and therefore as we saw previously f of x is going to be a domain as well. On this domain you have the degree function which is in fact going to be an additive norm on this function. With that stated, we can actually tell you that this norm is going to be a Euclidean norm so that there's these unique polynomials q and r so that r is either zero or it has smaller norm than g because the norm is the degree function. In particular, if f is a field, then f of joint x is going to be a Euclidean domain. That's the main result we want here and this is going to have a big, big effect on factorizations of polynomials. So first of all, let's suppose that f was a constant polynomial. So it's just a number that belongs to, it just belongs to the field, the coefficient field there and so then you could write f of x as zero times g of x plus r. r is a constant polynomial and so I mean if f and g are both constants then they're both units and so then divisibility is sort of a trivial statement there. So assuming that f is a constant polynomial and g is not, then its degree would be larger than one so we get exactly this situation. So if f is a constant, this division algorithm is satisfied in a trivial manner. So suppose then that f of x is a non-constant polynomial so its degree is something positive, its degree is not equal to zero. Suppose that the degree of g is equal to m and so therefore we can write our polynomials f of x is the linear combination of things of the form ai times xi as you go up to n and then g of x will be the sum of the bj times xj as you go up to its degree m and so then in that situation we honestly could assume that with really no consequence whatsoever, we could assume the polynomial f was monic because we could divide by its coefficient. It's not a big deal but without having to worry about that, that's the nice thing about a polynomial ring whose coefficients come from a field. Non-zero coefficients can be divided so we can assume without the loss of generality that f is a monic polynomial but nonetheless consider the following polynomial h of x which is going to equal f of x minus an over bm times x to the n minus m times g of x. So I want you to notice what's happening right here. Now I should mention that in this statement we're using the assumption that the degree of g is actually less than or equal to m because if that wasn't the case, this could actually be a negative exponent which wouldn't be a polynomial in that situation but if the degree of g was actually greater than the degree of f, basically this same statement would then apply that you're going to have f of x equals g zero times g of x plus f of x where f of x has smaller degree. So when we divide by g we might as well assume it has a smaller degree otherwise again it's a trivial division statement. So yeah without the loss of generality we can assume that g of x has less than or equal to the degree of f there. Therefore this is a monomial that lives inside of our ring so when you take x to the n minus m and times it by the leading coefficient x to the m, you'll get x to the n and then if you take a over b here the b's would cancel and so notice that when you look at this polynomial right here its leading term is in fact a to the n times x to the n which hey isn't that the leading term of f of x? They are. So when you subtract these two polynomials you're going to cancel off the leading term so the degree of this thing, the degree of h is strictly smaller than the degree of f which was in in that situation. Now if we play on induction of the degree of the polynomial f since we have a degree that's now smaller than n we can use our induction hypothesis where notice of course the constant polynomials the degree is equal to zero and that situation that was our base case. So by induction that is using our inductive hypothesis since h has degrees smaller than f we can assume there exists unique polynomials p of x and r of x so that h of x equals p of x times g of x plus r of x where r of x we can assume is either the zero polynomial or it has a degree that is strictly smaller than m in this situation and so then if we set q equal to be p of x plus a let me write it over here just so we can see it on one line an over bm times x to the n minus m like so I'll just erase this so you can see it right here so q if q of x is equal to this polynomial right here then note if we take this q of x and times it by g of x and then add on the remainder r of x well q of x by our construction is this polynomial right here you're going to times it by g so we distribute g onto these so you're going to get p of x times g of x then you're likewise going to get this monomial times g of x I just scooted it over here moving the r in front why did I do that well of course p of x times g of x plus r of x that was equal to h of x that we saw earlier and then this polynomial right here remember this is will be subtracted from f to construct h so therefore h plus this polynomial gives back f all right and so I do want to emphasize that the reason why it being a field is important that we can divide by our non-zero coefficients and so notice what we've now done here is shown that f of x equals q of x times g of x plus r of x and r of x then satisfies these conditions that it needs to all right so we have the division algorithm wait oh there's a uniqueness statement built into that we have to take care of that too so what if we had two different quotients and remainders so q1 times g plus r1 is equal to q2 times g plus r2 these are two distinct divisions here well since they're equal to each other this is an equation we can manipulate things that is we could move the q2g over here we could move the r1 over here to get this equation that you see on the screen like so factoring out the g of x of course now if these two divisions are in fact distinct from each other that means that these this is non-zero over here these things don't equal to zero because otherwise that would force zero ever wealth in particular if the remainders are distinct then that means this is non-zero and if the right hand side's non-zero since g is non-zero this product would only be zero if these two things were the same so if we have a distinct fact we have a distinct as vision these two different divisions then it's non-zero but then we play around with that well the degree of the degree of g it's going to be less than equal to degree of g plus some degree of a non-zero polynomial all right because that would only make it get bigger or stay the same I suppose but as it's an additive function the degree function this becomes the degree of g times q1 minus q2 which by the above equation this is equal to degree of r1 minus r2 right which remember that r1 r1 has a degree smaller than g r2 has a degree smaller than than g so when we add them together their degree is worst case scenario the size of their larger degrees both of which are smaller than g so this I mean but it could even be much smaller right maybe they cancel each other out because they're the same degree so this this has to be smaller than the degree of g which of course is a contradiction that shows us that these two these two divisions are not distinct they actually have to be one and the same thing because we were assuming they were distinct to get that contradiction and therefore we've proven that in a in a polynomial ring with field coefficients you have the division algorithm aka it is a Euclidean domain now I should mention that on the other hand if you look at the polynomial ring with two variables this is in fact not this is not a Euclidean domain it's not a Euclidean domain and basically to see that you can consider the following situation if you take f a joint x y and you mod out by the ideal generated by x and y like so this you can very easily show using this first isomorphism theorem for rings that this is isomorphic to the coefficient field f now since the which of course is not the same thing as this ring right here so this is a proper ideal and since the quotient is in fact a field this shows that the the ideal generated by x and y this is maximal this is a maximal ideal because the quotient is in fact a field okay so this is a maximal ideal but it's also true that x does not divide y and we also have that y does not divide x all right and this can be made by degree considerations right x and y are both to consider degree one polynomials so they can't divide each other because of how the because of how the degree function behaves right it's out of nature there and so this then gives us that the gcd between x and y is going to equal one if this was a Euclidean domain then it would have to be a principal ideal domain and therefore the ideal generated by x and y would have to equal the principal the ideal generated by x and y have to equal the principal ideal generated by their gcd which would be one but the since one is a unit the ideal generated by one is the whole ring but like i said before this is a proper ideal and therefore you're getting a contradiction so in particular in the ring f joined x y gcds are not necessarily linear combinations and therefore it's not a principal ideal domain and since every Euclidean domain is principal ideal since it's not a principal ideal domain it's not even a Euclidean domain so there are some limitations there so we saw that if the coefficient field was a if the coefficient ring was a field then the polynomial ring would be a Euclidean domain but when we try to do induction on this thing so yeah f is a field so therefore f of joint x is a is going to be a Euclidean domain but then if we throw in one more variable here this is not a field this is only Euclidean domain so when we start looking at this ring right here we can't use induction to get that this is also Euclidean domain it's not even a it's not even a pid we can in fact show that it's a domain that that we already know we've proven that but what we can do is actually show that this is going to be unique factorization domain so even though it's the coefficient field the coefficient ring is a field we if we start adding multiple variables we don't necessarily have Euclidean domain anymore but we can produce unique factorization domains and that's something we'll prove in a future lecture