 When one works with probability a continuous probability here like we do in our class math 3700 here at Southern Utah University here So I mean we're talking about how calculus can be used to help you study probability We have a whole class of calculus based statistics and such Just as this is just a kind of preview of why Integration is anything to do with statistics here now often what happens is that we have a probability density function Whose domain is an infinite interval? Maybe the entire real line? It could be that any possible assignment of real numbers could be given to x How does one describe a probability in such a situation? Well, we'll be interested in things like well, what's the probability that x is less than b? Which by a previous remark the the probability that x equals exactly b of course is zero So that's no difference in saying x is strictly less than b or x is greater than or less than or equal to b This is going to turn out to be improper integral If you want to find the probability that x is less than b, it's going to be a probability from that It's going to be integral from negative infinity to b similarly if you want to find the probability that x is greater than a or greater than equal to a This is going to be improper integral from a to infinity of f of x dx If you take the probability that x is going to be greater than negative infinity and less than infinity Notice you're integrating the entire Domain of the density function. Of course, that's going to be a one because it's a density function here Now, but let's take a look at an example why that might be appropriate Suppose that a random variable x is the distance in kilometers from a given point to the nearest bird's nest So if we were to leave our classroom and go look at different trees around our neighborhood or around the campus How how far do we have to go before we find a tree in a bird's nest? Or sorry, that's a weird thing to say a bird's nest inside of a tree And so in a certain biome We can model the distribution of that bird's nest by the function f of x equals 2x e to negative x squared Where the domain is going to be x is greater than equal to zero Negative doesn't really make any sense here because we're talking about a distance But potentially that distance could get arbitrarily large like if we one day woke up and we're on the moon There's going to be a huge amount of distance before we have to go before we find the nearest bird's nest You could imagine from that so this could get arbitrarily large, but of course It's not likely to get very large Let's first convince ourselves that this is a density function to be a density function It has to first be a positive function now notice that e to any power is always going to be positive So in particular if we take the negative x squared power This is always positive And then because of our domain here x has to be greatly equal to zero If you take the product with these two things, it's going to be great equal to zero You throw a two in there. It's going to be great equal to zero that part usually pretty easy To show that it's a density we have to check the domain as we go from zero to infinity Why is it that two x e to negative x squared? Why is that equal to one? Well, we can compute this using a u substitution take u to be negative x squared Hence du it's going to equal negative two x dx So I need a negative sign to correct that fact. I'm missing one there And so if we make the substitution, this is going to be the integral of negative e to the u du Looking at that and also change the bounds right as x goes from Zero to infinity. What happens to you? Well as x approaches zero A negative x squared will also go to zero. That's great. And as x approaches infinity u is going to go towards negative infinity right there And so if we change the bounds, we're going to have zero right there negative infinity right there And so then swap swapping up the order here. You're going to get negative infinity on the top zero right here e to the u du All right. Well, what happens now? Integrating you're going to get e to the u From negative infinity to zero when you plug these things in there you get e to the zero minus e to negative infinity As x approaches zero the x minutes will become one and as x goes to negative infinity you're going to get a zero there So we do get the area under the curve as one. This is a valid probability model We can use this to model the distance to the birds We we'll we'll let the biologists figure out whether this is a good model or not But we as mathematicians can see that this is a legitimate Probability model whether it's a good model or not again We'll let we'll let the biologist and those who study the birds to worry about that So using this probability model, what is the probability that the nearest nest will be within A half a kilometer. So we're asking what's the probability that x will be less than or equal to 0.5 So with respect to the density function we are using We need to calculate the integral From zero to 0.5 because you can't get less than zero So that's the lower bound there and then our function was 2x e to the negative x squared dx Again to calculate this integral we probably want to do a u substitution the exact same u substitution as before So we want a negative sign like that Really only thing that changes are how we change the limits You have an x and a u zero zero and so now when you have a one half When you plug that in there you're going to get negative one fourth Our negative point two five if you prefer And so the calculation this time is going to look like the integral from negative one fourth to zero e to the u du Antideriv we know it is again e to the u as you go from negative one fourth to m one there. So you get one minus uh e to the negative point two five Or if you prefer one minus one over the fourth root of e That's an option, but we we'll just estimate this thing with the calculator We want a percentage and with your calculator you get a point two two one two So there's about a 22 chance that You know a little bit less than a quarter of a chance that if you go half a mile you'll find a bird's nest In in some trees. So we're talking about a one half radius one half kilometer radius around there So these calculations work out pretty nicely and you'll also kind of notice that as you do these these integrals over and over again You're gonna have the same antiderivative oftentimes You want to come up with a formula for this antiderivative And this is actually the main difference between like a calculus based statistics class and a non-calculus based statistics class The thing is which we can see in this example to find the probability is we have to find the antiderivative of the density function Uh, which we can do because we know calculus, but students who don't know calculus can't do that So what instead happens is that the instructor prior to the class Calculates the antiderivative of the most commonly showing up Uh, probability density functions and then they just teach those as the functions to the students and they never have to do the calculus This works in special situations, but it only is going to work for a few standard Probability density functions unlike this example of which they wouldn't stand much of a chance of Uh, we have to be able to calculate we have to be able to calculate these using calculus Um calculate a computer statistics without calculus is kind of like doing physics without calculus. It's just absurd It's like watching, uh, harry potter And the deathly hollows, you know part two without watching any of the previous harry potter films You have no idea what's going on here. I mean you can appreciate the movie, right? It's still fun But you're wondering yourselves like who's harry potter? Why does he have a scar? Who's this voldemort guy? Why doesn't he have a nose? Um, you have these unresolved questions because we don't know what happened beforehand the same thing happens to statistics without Without the use of calculus. It's really unsure to us. Why is this called the central limit theorem? Well, because it's a limit theorem, um, which is coming from calculus here So I digress here, but be it be where it's important to recognize how how connected calculus and probability are with each other You really shouldn't divorce the two. They should be together working in harmony