Day 47: Functions of One Random Variable Example Part 3
Bad news readers, I’m feeling a bit under the weather. Today we’re going to go over a quick example. It’s not the one I had in mind, but it’s fairly straightforward and should help make some more sense of everything we are covering. When I start feeling better we can get into some of the newer concepts.*
For those of you just joining us, if you’re looking for the intro to our functions of one random variable section, you would want to start about here. If you’re ready to jump into an example, this is going to be a quick one, but it should help you see how to solve these types of problems.
Let’s say that X is a continuous random variable. We know that the pdf of X is
this just means that our function f(x) lives in the range where x can be anything from -∞ to +∞ (all real numbers). Now since we are doing functions of random variables we want to solve for a Y function where
and let’s find the CDF of Y given everything above. Now let’s use our by parts method that we looked at in example 1. To do that the first step is to find the range for our Y function in terms of x, notice that our new function is the square of our output of X, meaning that no matter what X is, our Y will never be negative, so we can say
With this information we can solve for Y using integration (since we want the CDF) like so
So our first step is to substitute our function in for Y. Then we can rewrite the probability in terms of our X function. To do that we take the square root, now because X can be either positive or negative we have a lower limit (remember the square root of a variable like this is plus OR minus the square root, giving us this new lower limit.
Here’s where things get a little more complicated. We want to take the integral of our pdf to find our CDF. To do that we plug in our f(x) as you can see in step 4. We also set the limits of our integration to the new limits that we found in step 3.
Step 5 is a little hard to see, at least to me and since no one explains anything showing steps like this, I had to figure it out on my own. What we did was get rid of the abs(x), we did this by redefining our limits. Why can we do this? Well we can redefine our limits because the absolute of any negative number is a positive number. However, now we are getting rid of the negative portion of our integral ( remember this is the area under the curve) so we have to account for that half (even though it ends up being positive by taking the absolute value), since it is symmetric around 0 we can just multiply by 2.
This gets rid of the fraction and now we are left with a fairly straightforward integration problem. Integrating and plugging in our limits of integration, we get our last step. In the end we find that:
Well that was fun, because this is an important concept to understand, I think we will go through some more examples, but then we can get to the multiple variables and functions of multiple variables part. We are getting close to catching up to my class and that is good for me since this whole project is a sort of notebook for me (and all of you really). Hopefully I’ll be feeling better soon and we can do some real work.
Until next time, don’t stop learning!
*My dear readers, please remember that I make no claim to the accuracy of this information; some of it might be wrong. I’m learning, which is why I’m writing these posts and if you’re reading this then I am assuming you are trying to learn too. My plea to you is this, if you see something that is not correct, or if you want to expand on something, do it. Let’s learn together!!
This entry was posted on October 5, 2019 by FullMetal. It was filed under 365 Days of Academia and was tagged with cumulative distribution function, education, expected value, Function of random variables, math, mathematics, Moment Generating Functions, moments, probability, probability density function, random variables, statistics.
This site uses Akismet to reduce spam. Learn how your comment data is processed.