 Welcome back to our lecture series Math 3120, Transition to Advanced Mathematics for students at studying Utah University. As usual, I'll be a professor today, Dr. Andrew Misledine. In lecture five, we want to talk about the notion of a compliment and for sets and their counterpart in terms of logic. Because we're seeing this nice duality between set theory and Boolean logic. It's like a dyad for which is the fundamental of all mathematics here. For example, the notion of or represented in set theory as a union, but represented in logic as a disjunction and did similar between intersections and conjunctions there. We want to now get into the idea of not. What does not mean inside of both set theory and logic? We'll start with set theory verse like we usually do. Now, as a reminder, when working with sets, it's sometimes necessary to discuss the idea of a universal set, which is often referred to as a U. When one is discussing compliments, it's almost a necessity. There's one important exception, which we'll see by the end of this video here. The universal set is then the set for which all the other sets live in. This can change relative to the situation as illustrated by the example we see on the screen here. If we're discussing searching for a book, I want to find a book about such a thing, then it's probably implicit that your universal set is actually the collection of books in some type of library. This could be like a public library, a universe library, your personal library. Maybe this could be like a store you're going to buy a book from or just the Internet itself. You're going to search the worldwide web. There's some ideas like you're not going to search every book. You're going to probably search, oh, I'm going to look at the books that are in the SUU library and need to find one about set theory or something like that. That's been your universe and you search amongst those. Let's say that we're trying to group friends, maybe Facebook friends, and I get how that could be a dated reference for some people watching. It's like Facebook is for millennials or whatever. Replace Facebook with whatever current social medium is exciting for the young folks these days or whatever. But let's say that you're trying to group friends on some Facebook-like apparatus here. Maybe you have a wedding that you want to invite people on. Well, on Facebook, the connections you have are called friends, but are they really friends? Do I really want to invite them to my wedding or whatever? There might be some type of grouping there, like who gets an invitation, who doesn't get an invitation? Well, as you're trying to decide amongst these people who's invited and who's not, the universe will be contacts on Facebook or Instagram or whatever. There is that collection. You're only going to consider those who you already have a connection with. You're not just going to consider, oh, this random person, should I invite them or not? No, that's outside your universe there when it comes to contacts or a more mathematical one here. If we were working with a set of numbers, then that universal set is probably the natural numbers or the integers or the rational numbers or the real numbers or complex numbers. Those important sets of numbers we talked about before are typically the universe of numbers when it comes to specific math problems. It's important that we have a universe in our minds as we consider this problem of complement. If A is a set and then we think of it belonging to the universe there, A is a set, it's complement, and this is complement with an E, not complement with an I. It's not like, oh, A, you're a really great set. You take care of your kids, you're good at your job, you're so beautiful, not that type of complement. A complement would mean like a partner, yin-yang situation here. The complement of A, for which in our lecture series, we'll denote complements with a line over it, an overline there. This is not universal notation. Some people will use like a prime symbol. Some people use a superscript of a C, C for complement. Some people will use things like twiddle A or not A. There's no universal notation for complements. I can give you some reasons why that is a little bit later in this video here, but the complement of A is the set of all elements in the universal set that are not in A. So you want everything that's not in A, and that's why the universe is important here, because if you're asking what's not in A, like what's the limit? Let's take for example, the set A right here, the set one, two, five, seven, nine, that's a set A, what's not in A? What's its complement? Well, the number three is not in A, the number 10 is not in A, the number pi is not in A, the number one plus i is not in A, the number Pikachu is not in A, right? You have to realize that my social security number is not in A, how big is the complement? It depends on the universe. So for this example, our universe is the natural numbers one through nine. And so the complement will be everything that's not in A. So as we go through this, notice one is in A, two is in A, but three isn't. So three belongs to the complement. Four belongs to the complement because it's not in A. Five is in A, so it's not in the complement. Six is not in A, seven is in A, eight is not in A, nine is in A. So the complement of A with regard to this universe is three, four, six, and eight. If we wanted to do the same thing for B, we grab everything in the universe that's not in B. So looking at these elements one by one by one, one is in B, so it's not in the complement. Two is in B, so it's not in the complement. Three is not in B, so it's in the complement. Four is in B, so it's not in the complement. Everything else, because that was the last element in B, then has to be in the complements. We get three, five, six, seven, eight, and nine. And so the complement is everything that is not in the given set. When you think of complements, I want you to think of the word not. Compliment is just the set theoretic notion of not, okay? Now we have to have a universe, but sometimes you can get away with the universe not being explicit. And use this example to help us understand that. Take A to be the set, red, green, blue, and let B be the set, red, orange, yellow, green, blue, purple, okay? These are both sets whose elements consist of colors. So if we didn't specify the universe, but it would be natural to think that the universe would be the set of all colors, right? And so there of course is some ambiguity there, right? Like are we talking about the six colors of the rainbow? Some people try to argue there's a seventh one end to go and that's mostly just to make an acronym work. But nonetheless, I mean, if you're like writing hexadecimal codes for colors, maybe you could have thousands of different colors in mind here. So just think of it as like the universal set as a set of all colors, right? Then we could ask ourselves, what is a compliment? Well, we'd have to know every single color to be very clear about that. So we need more explicit universe in that situation. But what we could do is the following. We could ask, what is B intersect a compliment? Now, be aware without specifying the universe, I can still define this set because what we're gonna be looking for is we're looking for all colors X, such that this intersection means and here. So I need that X is in B and we need that X is in a compliment. So that's what the intersection means here, but the compliment means not. So we're looking for all colors such that X is in B and X is not in A. And so I can look at the things that are in B and I can just remove the things that are in A. So when you look at B, the color red is in B, but it's also in green, it's also in A. So that's not in A intersect a compliment. So we wouldn't include red. What about orange though? Orange is in B, but orange is not in A. So orange belongs to this set. Similar for yellow, yellow is in B, but it's not in A. We could then look at green. Green is in A, so we won't consider that one. Blue is also in A, but purple isn't or violet if you prefer. I guess some people will consider those different colors. I will not get into that argument at this moment. So we get all the colors that are in B, but not in A. So in this case, in this very special case, we're able to introduce a compliment without the universe and we still able to do this calculation. Because of this observation, this warrants a definition and that definition is gonna be what we call a set difference. So notice that in this previous example, B intersect A compliment is a well-defined set of all elements that are from B, but not in A. And we didn't need the universe to define that. And as such, this construction, B intersect A compliment is known as the set difference of the two sets, where it's the set where we take away everything from A, everything that was in A, we take it out of B. And then what's left over is the set difference. No, the most common notation used for a set difference is something like this. You see like a B slash A is downward slash. It goes from the top left to the bottom right. Sometimes people use the symbol B minus A and the minus makes sense given that it looks like a difference. And at this level, at the math 31, 20 level, this is probably the most common usage for set differences or if you're in a class before transitions that talks about set differences, like for example at SUU, there's math 1030 contemporary mathematics. They do a little bit of set theory in that class. It's just like a general education math class for non-STEM majors, but they get exposed to advanced mathematics a little bit in that class as well. They will probably do it this way. And the idea is minus means difference. And I assume the philosophy here is that we use a minus sign because this is a difference like operation. And so we're like, oh, students will think of it as a difference, we do that. But in professional mathematics, this is rarely ever used. I can't say it's never used, but it's rare. This is like used the vast majority of the time. And so as our goal is not to introduce you to new concepts, the goal of this class is to transition you into advanced mathematics, while that usually involves introducing you to new ideas, there's more to it than that. And so I say for our lecture series, it's better that we just start using the more professional notation now instead of the more juvenile notation because we're only gonna use it for a short time before we transition anyways. So I will do it now since that is literally the name of the class. All right, another thing to mention here. So if we consider the previous example about the colors, red, green, blue, et cetera, in that example, I do wanna point out here that the set A was actually a subset of B because B had the six colors of the rainbow and A just had red, green and blue. And when you take the set difference, we were computing B take away A. You could go the other way around though, you could ask what is A take away B? That would be by definition A intersect B complement, which if you calculate that, you would actually get the empty set. Now in this situation, B is bigger than A by three elements. But what you get is you take everything that's in A that's not in B. Now, if A is a subset of B, there is nothing in A that's not in B because B is larger. And so you see this all the time. It turns out that when A is a subset of B, the symmetric difference, not the symmetric difference, sorry, that's something else, the set to difference, usually just call the difference. A take away B is then the empty set. That actually happens in both directions. And I'll let you prove that in the future at some point. So let's play around with this set difference a little bit. But before we do that, let's look at some practice examples for unions and intersections that we've seen before, right? So this time we're gonna take some small animals, I guess, as our universal set. H is cat, dog, rabbit, mouse. F is dog, cow, duck, pig, rabbit. And W is duck, rabbit, deer, frog, mouse. What are these sets considering? Well, these animals, that's all we're gonna say here. So like we talked about unions and intersections before, let's consider that right here. So if I take H intersect F union W, remember the parentheses take priority here. There's no order of operations for set algebra. So you have to follow the parentheses here. H intersect F here. So what that means is we look for all of the things that belong to both H and F. So when you look at these things, cat is an H but not an F. Dog is in H and F. So it's gonna go inside the intersection there. Rabbit is in both H and F. Mouse is in H but not F. And so anything else we didn't get already is in an H, so that's all we have to consider. So the intersection is gonna be dog and rabbit on the screen. And then we take the union of that with W, which the union just means we just put the two sets together. So we're gonna have dog, we're gonna have rabbit because those were in H intersect F. But then we also take everything from W. W has a duck, W has a rabbit. Well, you already have rabbit, we don't need to write it again. W has a deer, W has a frog, ribbit, ribbit. And it has a mouse, squeak, squeak. And so that would be the calculation that said right there, nothing too fancy there. But I do wanna illustrate that if we switch the order of operations here, as in if we move the parentheses, if we take the union first and then the intersection, we do get something very different, right? So if we've now changed the parentheses, we should take the union of F and W first. So we're gonna get dog, because that's an F, you're gonna get cow, that's an F. You're gonna get duck, you're gonna get pig. You're gonna get rabbit. I honestly can't say I know the sound that a rabbit makes. Anyways, with W, you're gonna throw in duck, that's already in there, you're gonna throw in rabbit, that's already in there, you're gonna throw in deer. Don't have that one yet. You're gonna get frog, frog's not in there yet. Or mouse, pretty simple calculation. So that just gives us the union of the sets. So now let's take the intersection between H and that. I can't see H anymore, so it's scooched up a little bit. So the intersection, H has a cat, but that set does not have a cat. We do have a dog, we do have a rabbit, and we do have a mouse. So that's gonna be our intersection there. So the intersection is dog, rabbit, and mouse. So okay, we get a very different set. Notice the difference here, order of operation matters. This also comes into play when we consider compliments. I'm gonna zoom out a little bit so we can see everything on one screen, even though my font is gonna look super huge right now. So consider the set H intersect F, compliment intersect W. I want you to be aware this is the same thing as W, set difference H intersect F, like so. So we're taking the set difference. We want everything in W that's not in H intersect F. Those two sets are, these two sets are measuring the exact same thing here. Again, order of operations. We do what's inside the parentheses first because there is no established order of operations for sets here. So we're gonna take W, take away H intersect F, which we did that earlier, right? H intersect F was right here. It's going to be dog and rabbit. And so for the set difference, we are gonna compute everything that's in W that is not in, that's neither dog or rabbit. So we can see W at the top of the screen. There's a duck that's not dog or rabbit. There's a rabbit that's taken away. Deer and frog and mouse. So our objects can be colors, animals, numbers. It really doesn't matter. It's just about doing these types of calculations. What does union intersection mean? And how does complement affect that? Which in this case, we have this set difference which does the same thing. Now that we've established these very important set operations, what I wanna do now is to actually establish some very important properties, algebraic properties, which we call this like set algebra. You see similar properties like this when it comes to algebra for our real numbers, things like addition is commutative, multiplication is associative, you have added and inverses, et cetera. Set algebra has similar type of properties. So if you have three sets, A, B, and C that all belong to some universal set U, the following statements are true. The first property is known as the idempotency property, which says that if you take A union A, you get back A. So a set union itself doesn't give you anything new. Likewise, A intersect A is likewise A. If you take a set intersect with itself, you don't lose anything. It's still the original set A. The identity property, the union operation has an identity element and it's the empty set. A union, the empty set gives you back A because when you unite with the empty set, you don't gain anything new. So the set did not enlarge. Conversely, if you take A intersect the universe, you just get back A because what this is asking for is you want everything in A and everything, right? It's like, if you got to be in A and you have to be something, right? Then you're gonna be in A. It's intersecting with the universe doesn't restrict anything. So the universe acts like the intersection identity element, all right? So this is things we've seen before like the number zero is the additive identity for real numbers. The number one is the multiplicative identity but this idempotency principle is not something you see too often. With numbers, sure, you have things like zero times zero equals zero, one times one equals one, zero plus zero equals zero. These are idempotent conditions but that's only true for zero and one. This statement says for any set these idempotent properties happen. Also, we have absorption, okay? If you, this is kind of the opposite of the identity. If you take A union the universe you give back the universe, right? And if you take A intersect the empty set you give back the empty set because there's nothing in here. So there's nothing in both. This contains everything. So if you join in things that are already there you give back the whole universe. If you use set differences there A take away nothing gives you back A. So these are absorption properties in that respect. Speaking of set differences there's what we call the complement property. The complement property tells us that if you take A union it's complement you always give back the universe. Cause after all you take things that are in A or not in A. Well that's the only possibility either in A or not A you get everything back. Conversely, if you take A intersect it's complement you give back the empty set. Also, if you take A subtract A you give back nothing cause you want everything that's in A but not in A. There's nothing that can do that. So this is kind of like an inverse axiom but they're not inverses they're compliments cause inverses combine together to give you the identities. Compliments actually combine together to give you absorption dominant elements. It's slightly different but it is kind of related. Now let's get some axioms that you're probably familiar with. I shouldn't say axioms these are properties of set algebra here we can prove these things. There's the commutative property. So A union B is the same thing as B union A the order in which you unite things does not matter. Same thing with intersection A intersect B is equal to B intersect A. The associative properties also hold that is A union the union of B and C is the same thing as the union of A union B with C. Likewise, so you can move the parentheses around. So we're justified in not having parentheses when you have just combinations of unions. Same is also true for intersections. If you take A intersect the intersection of B and C that is the same thing as the intersection of A intersect B with C. You can move the parentheses around there. We also have the distributive properties. Now the distributive property would be like for multiplication in addition would be something like two times three plus one. You can distribute the two so you get two times three plus two times one. And now multiplication distributes over addition. What we have for the set operations is you have union distributes over intersection. So the A union B intersect C is the same thing as A union B intersect A union C like so. So the union distributes there but it also goes the other direction. Intersections distribute over unions. And so A intersect B union C is the same thing as A intersect B union A intersect C. And this is the very reason why we don't have a order of operations for set algebra because with real numbers multiplication distributes over addition and that's where we get the priority. But for set operations the distribution goes in both directions unions and intersections. So either one is just as prioritizes the other. And then the last set algebraic law we're gonna mention here are known as the De Morgan laws and they have to do with compliments. If you have the compliment of the intersection so the compliment of A intersect B this is equal to the union of A compliment and B compliment. So compliments turn intersections to unions. And then likewise, if you take the compliment of A union B this is the same thing as the compliment of A intersect the compliment of B. So De Morgan's laws say that compliments turn intersections to unions and unions to intersections. Now many of these identities that we've saw on the screen a moment ago are fairly straightforward to prove and many will be proven by you in the future. I'm not gonna do them in this video right now is what I'm trying to say here. But to illustrate the basic template for proving that two sets are equal we're gonna prove the distributive laws. That's one of the harder ones on this list given it's near the bottom. Now these are algebraic properties of sets but in the end they are just sets. Okay, meaning that this set is equal to this set. We've talked about this before to prove that two sets are equal we will show that they are subsets of each other. So there's two directions that have to play here. So I'm gonna choose this one right here and we're gonna prove that these two sets are equal to each other by showing their subsets of each other. So to prove the distributive properties we're gonna first show that A union B intersect C is a subset of A union B intersect A union C. Now this is a common thing that people can do improve if you actually tell us what you're going to do because it might not be clear to the reader mostly because there's eight properties involved here and then with each of these properties there's typically two identities. So it might, and then given an identity there's two directions you have to go. So even though it's not mandatory it is good practice to tell the reader what you're gonna do when there might not be it might not be clear what's the next thing to do. So it helps give the reader an expectation what's following. So the first thing we're gonna do is we're gonna prove this. A union B intersect C is a subset of A union B intersect A union C. Now to prove that this set is a subset of the other we're gonna start with an arbitrary element over here and prove that it belongs to this set right here. So we take an arbitrary element of A union B intersect C. Well, a union means that X belongs to one of these two sets. It could be both, but it has to belong to at least one of them. So X belongs to the union either because X belongs to A or X belongs to B intersect C. Now you have two possibilities and I can't say it's one or the other. I don't have enough information because X is an arbitrary element and ABC are arbitrary sets. So I have to actually consider both possibilities. And so there's two cases and I'll just consider the two cases individually starting with the first case if X belongs to A. So that gives us more information about X now because we have this extra assumption that if X belongs to A well consider the set A is a subset because A union B is everything in A or in B. Well, if you're in A, then you're in A and so you're in A or B. So the union only enlarges the set there. That's also true that A is a subset of A union C for the same reasons. Now since X belongs to A and these are two larger sets this tells us that X belongs to A union B because it belongs to A but also X belongs to A union C because it belongs to A. And since X is in both of them it means that X is in the intersection between A union B and A union C. That's the direction we want to go. So if X is in A then it belongs to the set we're trying to get. That was the first possibility. Well, the second possibility is that X belongs to B intersection C. Well, if X belongs to B intersect C intersection is and. So I can actually say definitely if X is in B intersect C then X belongs to B and X belongs to C. Now, since X belongs to B you can enlarge B by looking at A union B and therefore X belongs to A union B. It's also true though that since X belongs to C that you can enlarge C to a bigger set. If X is in the small set then X will have to be in the larger set. So X belongs to A union C. And so since X is in A union C and it's in A union B that means X will belong to the intersection of A union B and A union C. That's the set we're looking for here. And so in the second case we get inside the set. So in either case we get that X belongs to this set. And so that shows us that the original set which X was an arbitrary element of is contained inside the larger set. All right, let's go in the other direction. Now let's show that A union B intersect A union C is a subset of A union B intersect C. It's the same approach as before. We're gonna take an arbitrary element of the first set. We'll call it X. And so X belongs to A union B intersect A union C. Since this is an intersection X belongs to both A union B and A union C. X belongs to A union B and X belongs to A union C. Now when we get to the union so X belongs to A union B. I don't know if X belongs to A or B. So I have to consider the two possibilities. So if X belongs to A, right? Then X will belong to any larger set any super set of A which it will belong to A union B intersect C because this set does contain A. So X is in there as well. So we're done in that situation. Now because, so if X is an A then we know where it's supposed to be. Now if X is not an A because it's gotta be one of those two situations. In logic, this is what you call a disjunctive syllogism. It's about an or statement. X is either an A or it's not an A. If it's an A, we're done. We proved it. So now let's consider the other possibility. X is not an A. Well, since X belongs to A union B if it's not in A, then it has to be in B. But likewise, if since X belongs to A union C if X is not an A, then it has to belong to C. So in this situation, we know that X belongs to B and we know that X belongs to C which means that X belongs to B intersect C. Now, since X belongs to the intersection of B and C it'll belong to any set that contains B union C and particularly the union between A and B intersect C like so. And so since X belongs to that that's the set we're looking for. And so in all possibilities if X belongs to the first set we then get it belongs to the other set and that then shows the set containment. Since we showed containment in both directions that implies the two sets are equal to each other and that then establishes this identity. Also that was kind of a hard one for us at this point. I promise this will feel easier in the future but for right now this might feel overwhelming. Well, it's because we're still very much beginners in proving things but I did illustrate some important points here. In particular, how do you prove that two sets are equal to each other? Show that they're subsets of one another. That is a template that we've already learned. Now seven and eight are definitely the hardest ones on these lists but try proving some of these earlier ones. Like can you prove this identity using the template we have for proving two sets are equal or this one or even this one? One through six are not anywhere as close to difficult as seven and eight. So I would encourage the viewer here to try to prove some of these identities to practice your set proving capacities.