 Welcome back to our lecture series, Math 3120, Transition to Advanced Mathematics for students at Southern Utah University. As usual, I'll be your professor today, Dr. Andrew Misseldine. In lecture four, we're gonna introduce some operations we can do with sets and logic. Remember in our lecture series, in our first video, do talk about something related to set theory, our second one about logic. And when possible, try to make these things related to each other. In which case for lecture four, there is no better connection than what we're gonna see right now. In this first video, we're gonna introduce the notions of union and intersections. And then in the second video, we're gonna see the discussion of conjunctions and disjunctions and see how these are actually quite related to each other. Basically, this idea of and and or is gonna show up in both places, serving that rule. So with the set theory side of things, let's introduce what it means to have an intersection or a union. Suppose we have two sets, A and B, and these can be arbitrary sets, finite, infinite, don't care. We define the intersection of the two sets, A and B. And it's commonly denoted by this. So you see A and then there's this symbol right here, which kind of looks like an upside down capital U. In latex, this is actually referred to as the cap right here. We'll talk about the other one in a second. We're gonna talk about unions. So you see this A cap B and this right here is our intersection symbol. So you would pronounce this as A intersect B. Whenever in mathematics you see this colon equal sign, this actually means that we're defining a mathematical notation. And so the intersection of A and B is exactly the following. We take elements X such that X belongs to A and this is the key word here and X belongs to B. So the intersection is the set of all elements that belong to both A and B. Now, conversely, the union of A and B, which we denote as a union B, this time our symbol actually looks like a capital U, but it's not actually a U because U's have little tails, right? No, it kind of looks like a U, but like in latex, this is actually called the cup symbol. So this is cap, this is cup down here. But be aware that the two symbols are identical except one, the bowl shape goes down and on the other, the bowl shape goes up. And so you have cups and caps, intersections and unions. This is something you'll have to get used to. It might be tricky at first if you haven't seen these before. But anyways, the union A, union B is defined to be the set of all elements X such that X belongs to A or X belongs to B and the key word this time is or. And I've underlined it here on the screen because this will be very important as we get to our second video here. Intersection means and, union means or. And so I do have to distinguish between these words a little bit. If an element is in A and in B, that means X is inside the set A and I mean, how do you say and here, and it's in B. Now with or I do have to be a little bit more careful here. So if X is in A or in B, there is the possibility of both. So if X is in A and in B that actually means you're in X is in A or in B. So oftentimes in the English language, when you use the word or we use it in an exclusive sense. So we might say something like, all right, let's say you're a parent talking to your child, trying to encourage them to get better grades. You might be like, okay, if you get a good grade on your math test today, we'll go to the store and we'll get ice cream or we'll get cookies, okay? And oftentimes when you say that, it's a one or the other, but not both. You're not gonna double reward the kid there. But in mathematics, the term or, it means one or the other or both. So you could get ice cream and cookies and that would be an acceptable use of the word or. And this will be apparent in the lecture video we have right now, but we'll kind of discuss this more in our next video when we talk about the logical meanings of and or, which we've already begun doing so right now. So with or it has to be in one or the other, but it could be both. We say that two sets are disjoint if their intersection is the empty set, which does happen on occasion. All right, so let's just play around with some examples here. So I have three sets illustrated here. There's the set A, which is one, three, five, eight. There is the set B, three, five, seven. And then there's the set C, two, four, six, eight. And so let's do some of these calculations here. So what does it mean to take the intersection of A and B? We'd be looking for those elements which belong to both A and B. So first look at the number one, for example. One belongs to A, but it's not in B anywhere. So it turns out one does not belong to the intersection because it's only in A. When you look at three though, three belongs to both A and B. So that'll be in the intersection. And so we can start writing that down here. Three is in there. When you look at five, five is in both A and B. So we'll put that in the intersection. Eight belongs to A, but not B. So we actually won't include it. And then what's left over? Honestly, I don't need to check what's in the other set because if it wasn't in A, it won't be in the intersection. But nonetheless, if you check for seven, seven was in B, but not in A. So it's not gonna be part of the intersection there. So the intersection between A and B, that is those elements would show up in both A and B is only the numbers three and five. So that's how we can calculate this intersection. Let's try now the union of A and B. They're not necessarily the same thing. Typically we expect them to be different. The union of A and B means we want the things in A or in B. And so we look at them. So honestly, when it comes to this, you can just start listing all of the elements of A right there. So you're gonna get a one, you get a three, you get a five, and you get an eight. So that's part of the union, but we take anything that's in A or in B. So when you look at B, you get, there's a three, there's a five, and there's a seven. Now, admittedly, three and five remembers the intersection. That means this element shows up twice. If you just write down the two elements united together. Now, with sets, we don't really write the repetition. So it's typically good form to just omit any repeats. The repeats will exactly be those elements in the intersection. So we're just gonna get one, three, five, eight, and seven, three and five are in there in both sets. So we don't need to write it twice. Now, if you have any concern that the set isn't written in ascending order, remember for a set, it doesn't really matter, but if it makes you feel better, we can write it in ascending order, one, three, five, seven, eight. It doesn't make a difference of who the set is, but be aware that you can write that way if it makes you feel good. All right, so then let's look at another example here. Let's take the intersection of B with the union of A and C here. Now, one has to be very cautious that we've introduced two operations on sets. And this might make us think about like algebraic operations we do on numbers. Like if we did something like 2x plus one, this is a algebraic expression with some variable x in play here. And when we work with addition, subtraction, multiplication, division, and other arithmetic operations on the real numbers, there is this order of operation that comes into play here. Please excuse my dear Aunt Sally, that type of stuff, for which multiplication takes precedence over addition. So if I told you something like x equals five, the first thing you do is you take two times five to get 10, and then you add one to it to get 11. So that's what this would equal in that situation. As opposed to like if you change the order of operations where addition has priority, you take five plus one, which is six then times it by two and get 12, that would be something very different. Has to do with order of operations. We put multiplication at a higher priority than addition. Now, if you need to change the order of operations, parentheses can be used there. So if you want the quantity to be 12 when x equals five, then sure, you put parentheses around there and then whatever's in parenthesis takes precedent there. When it comes to set operations, we're not gonna specify a order of operations. Unions will not take priority over intersections and intersections will not take priorities over unions. And as such, it's imperative that when we use set, when we write set operations that involve unions and intersections, parentheses have to be used so that we know the order of which to do these calculations. Because if I compute the union first, then the intersection, which the parentheses tell me that's how I'm supposed to proceed, I'll actually get something different than if you do the intersection first and then the union, okay? So by parentheses, we should do the union first. So we have to compute B intersect with the union of A and C. So the union of A and C means everything that's in A or in C. So one is in A, so it's in the union. Two is in C, so it's in the union. Three is in A, so it's in the union. Four is in C, so it's in the union. Five is in A, so it's in the union. Six is in C, so it's in the union. Eight is in both A and C, so it'll be in the union. So the union of A and C is exactly this, one, two, three, four, five, six and eight. Seven feels really left out right now, but oh well. Next, now that we've computed the union of A and C, we're then going to compute the intersection of B and A union C, which is this set right here. So we look for those things which are in both sets. Now, B only contains three elements. A union C contains more. So when it comes to an intersection, it might be best to look at the smaller set because if you're not in the smaller set, you're not in the intersection. So when you look here, B has a three, so does A union C. B has a five, so does A union C. Like I already joked about, A union C doesn't have a seven. So it turns out the intersection of B with A union C is gonna be three and five, which is actually was the same as we got earlier, but it turns out that different sets, their intersections can form the same. That's a reasonable possibility here. Let's look at another example before we end this video. This time we won't play with numbers, but we'll play with colors. So let A be the set, red, green, blue, and B is the set, red, yellow, orange. Okay, for whatever reason, these are our sets. So if we take the union of these things, well, the union means you put the two sets together. And so we're gonna have red is in A, so is green. Now, I should mention that red was in both A and B, but to be in the union, you just have to be at least one of them. Blue is in A. Now, if you look at B, we already took care of red, but we don't have yellow, so we put yellow in there, and then we need an orange as well. So the union just put the two sets together. Now, for intersections, for intersections, we're looking for those things that are in both sets. And we've actually already hinted towards this. Red is in both sets, green is not in B, blue is not in B. So that's actually gonna be the intersection. And so the intersection's just the single 10 red, like so. And that is how one computes a intersection or union of sets.