Addition rule for probability | Probability and Statistics | Khan Academy - YouTube

Channel: Khan Academy

[0]
Let's say I have a bag.
[1]
And in that bag-- I'm going to put
[4]
some green cubes in that bag.
[6]
And in particular, I'm going to put eight green cubes.
[11]
I'm also going to put some spheres in that bag.
[15]
Let's say I'm going to put nine spheres.
[18]
And these are the green spheres.
[20]
I'm also going to put some yellow cubes in that bag.
[25]
I'm going to put five of those.
[27]
And I'm also going to put some yellow spheres in this bag.
[32]
And let's say I put seven of those.
[34]
I'm going to stick them all in this bag.
[36]
And then I'm going to shake that bag.
[37]
And I'm going to pour it out.
[38]
And I'm going to look at the first object that
[41]
falls out of that bag.
[43]
And what I want to think about in this video
[45]
is what are the probabilities of getting
[46]
different types of objects?
[48]
So for example, what is the probability
[52]
of getting a cube of any color?
[56]
What is the probability of getting a cube?
[58]
Well, to think about that we should think about what--
[60]
or this is one way to think about it--
[62]
what are all of the equally likely possibilities that
[64]
might pop out of the bag?
[66]
Well, we have 8 plus 9 is 17.
[67]
17 plus 5 is 22.
[70]
22 plus 7 is 29.
[72]
So we have 29 objects.
[74]
There are 29 objects in the bag.
[75]
Did I do that right?
[76]
This is 14, yup 29 objects.
[79]
So let's draw all of the possible objects.
[81]
I'll represent it as this big area right over here.
[87]
So these are all the possible objects.
[89]
There are 29 possible objects.
[92]
So there's 29 equal possibilities
[94]
for the outcome of my experiment of seeing what pops out
[98]
of the bag, assuming that it's equally
[99]
likely for a cube or a sphere to pop out first.
[102]
And how many of them meet our constraint of being a cube?
[105]
Well, I have eight green cubes, and I have five yellow cubes.
[109]
So there are a total of 13 cubes.
[112]
So let me draw that set of cubes.
[114]
So there's 13 cubes.
[116]
We could draw it like this-- there are 13 cubes.
[124]
This right here is the set of cubes, this area.
[126]
And I'm not drawing it exact.
[127]
I'm approximating.
[128]
It represents the set of all the cubes.
[131]
So the probability of getting a cube
[132]
is the number of events that meet our criteria.
[135]
So there's 13 possible cubes that
[137]
have an equally likely chance of popping out,
[140]
over all of the possible equally likely events, which are 29.
[144]
That includes the cubes and the spheres.
[148]
Now let's ask a different question.
[150]
What is the probability of getting a yellow object, either
[155]
a cube or a sphere?
[157]
So once again, how many things meet our conditions here?
[160]
Well, we have 5 plus 7.
[162]
There's 12 yellow objects in the bag.
[166]
So we have 29 equally likely possibilities.
[169]
I'll do it in that same color.
[171]
We have 29 equally likely possibilities.
[173]
And of those, 12 meet our criteria.
[177]
So let me draw 12 right over here.
[182]
I'll do my best attempt.
[184]
So let's say it looks something like-- so
[187]
the set of yellow objects.
[189]
There are 12 objects that are yellow.
[194]
So the 12 that meet our conditions
[196]
are 12, over all the possibilities-- 29.
[198]
So the probability of getting a cube--
[199]
13 29ths, probability of getting a yellow-- 12 29ths.
[205]
Now let's ask something a little bit more interesting.
[207]
What is the probability of getting a yellow cube?
[212]
So I'll put it in yellow.
[213]
So we care about the color, now.
[215]
So this thing is yellow.
[217]
What is the probability of-- or as my son would say, "lello."
[221]
What is the probability of getting a yellow cube?
[225]
Well, there's 29 equally likely possibilities.
[231]
And of those 29 equally likely possibilities, 5 of those
[234]
are yellow cubes, or "lello" cubes, five of them.
[239]
So the probability is 5 29ths.
[241]
And where would we see that on this Venn diagram
[243]
that I've drawn?
[244]
This Venn diagram is just a way to visualize
[246]
the different probabilities.
[247]
And they become interesting when you
[248]
start thinking about where sets overlap,
[251]
or even where they don't overlap.
[253]
So here we are thinking about things
[254]
that are members of the set yellow.
[256]
So they're in this set, and they are cubes.
[260]
So this area right over here-- that's
[262]
the overlap of these two sets.
[265]
So this area right over here-- this
[267]
represents things that are both yellow and cubes,
[270]
because they are inside both circles.
[273]
So this right over here-- let me rewrite it right over here.
[277]
So there's five objects that are both yellow and cubes.
[285]
Now let's ask-- and this is probably the most interesting
[288]
thing to ask-- what is the probability of getting
[294]
something that is yellow or or a cube, a cube of any color?
[304]
The probability of getting something that is yellow
[306]
or a cube of any color-- well, we still
[309]
know that the denominator here is going to be 29.
[311]
These are all of the equally likely possibilities
[313]
that might jump out of the bag.
[315]
But what are the possibilities that meet our conditions?
[318]
Well, one way to think about it is, well, the probability--
[322]
there's 12 things that would meet the yellow condition.
[325]
So that would be this entire circle right over here-- 12
[327]
things that meet the yellow condition.
[330]
So this right over here is 12.
[332]
This is the number of yellow.
[337]
That is 12.
[338]
And then to that, we can't just add the number of cubes,
[341]
because if we add the number of cubes,
[343]
we've already counted these 5.
[344]
These 5 are counted as part of this 12.
[347]
One way to think about it is there
[349]
are 7 yellow objects that are not cubes.
[352]
Those are the spheres.
[353]
There are 5 yellow objects that are cubes.
[356]
And then there are 8 cubes that are not yellow.
[359]
That's one way to think about.
[361]
So when we counted this 12-- the number of yellow--
[363]
we counted all of this.
[365]
So we can't just add the number of cubes
[366]
to it, because then we would count this middle part again.
[369]
So then we have to essentially count
[371]
cubes, the number of cubes, which is 13.
[377]
So the number of cubes, and we'll
[382]
have to subtract out this middle section right over here.
[386]
Let me do this.
[387]
So subtract out the middle section right over here.
[390]
So minus 5.
[392]
So this is the number of yellow cubes.
[399]
It feels weird to write the word yellow in green.
[401]
The number of yellow cubes-- or another way to think about it--
[404]
and you could just do this math right here.
[406]
12 plus 13 minus 5 is 20.
[411]
Did I do that right?
[412]
12 minus, yup, it's 20.
[414]
So that's one way.
[415]
You just get this is equal to 20 over 29.
[417]
But the more interesting thing than even the answer
[419]
of the probability of getting that,
[421]
is expressing this in terms of the other probabilities
[425]
that we figured out earlier in the video.
[428]
So let's think about this a little bit.
[429]
We can rewrite this fraction right over here.
[432]
We can rewrite this as 12 over 29 plus 13 over 29 minus 5
[446]
over 29.
[448]
And this was the number of yellow
[449]
over the total possibilities.
[451]
So this right over here was the probability
[453]
of getting a yellow.
[455]
This right over here was the number
[457]
of cubes over the total possibilities.
[459]
So this is plus the probability of getting a cube.
[466]
And this right over here is the number
[468]
of yellow cubes over the total possibilities.
[471]
So this right over here was minus the probability
[474]
of yellow, and a cube.
[478]
I'm not going to write it that way.
[479]
Minus the probability of yellow-- I'll
[482]
write yellow in yellow-- yellow and a cube.
[492]
And so what we've just done here--
[493]
and you could play with the numbers.
[494]
The numbers I just used as an example right
[496]
here to make things a little bit concrete.
[498]
But you can see this is a generalizable thing.
[501]
If we have the probability of one condition
[504]
or another condition-- so let me rewrite it-- the probability--
[508]
and I'll just write it a little bit more generally here.
[510]
This gives us an interesting idea.
[511]
The probability of getting one condition of an object
[516]
being a member of set a, or a member of set b
[520]
is equal to the probability that it is a member of set a,
[524]
plus the probability that is a member of set b,
[527]
minus the probability that is a member of both.
[536]
And this is a really useful result.
[538]
I think sometimes it's called the addition
[539]
rule of probability.
[540]
But I want to show you that it's a completely common-sense
[542]
thing.
[542]
The reason why you can't just add these two probabilities
[545]
is because they might have some overlap.
[548]
There's a probability of getting both.
[549]
And if you just added both of these,
[551]
you would be double counting that overlap,
[553]
which we've already seen earlier in this video.
[556]
So you have to subtract one version of the overlap
[558]
out so you are not double counting it.
[561]
I'll throw another one other idea out.
[563]
Sometimes, you have possibilities
[565]
that have no overlap.
[566]
So let's say this is the set of all possibilities.
[572]
And let's say this is the set that meets condition a
[577]
and let me do this in a different color.
[580]
And let's say that this is the set that meets condition b.
[583]
So in this situation, there is no overlap.
[585]
There's no way-- nothing is a member of both sets, a and b.
[588]
So in this situation, the probability of a and b is 0.
[592]
There is no overlap.
[594]
And these type of conditions, or these two events,
[598]
are called mutually exclusive.
[605]
So if events are mutually exclusive,
[606]
that means that they both cannot happen at the same time.
[611]
There's no event that meets both of these conditions.
[615]
And if things are mutually exclusive,
[618]
then you can say the probability of a or b
[621]
is the probability of a plus b, because this thing is 0.
[624]
But if things are not mutually exclusive,
[627]
you would have to subtract out the overlap.
[629]
And probably the best way to think
[631]
about it is to just always realize
[633]
that you have to subtract out the overlap.
[635]
And obviously if something is mutually exclusive,
[638]
the probability of getting a and b is going to be 0.