Distribution of a Function of a Random Variable

In summary: Yes, your understanding of the area under a graph is correct. And your PDF for Y is also correct. Good job!
  • #1
izelkay
115
3

Homework Statement


If X is uniformly distributed over (0,1), find the PDF of Y = |X| and Z = e^X

Focusing on the |X| one

Homework Equations


Derivative of CDF is the PDF

The Attempt at a Solution


So I start by writing down the CDF of X, Fx(x):

0 for x <0
x for 0 ≤ x ≤ 1
1 for x ≥ 1

And I also know the range of Y = |X| is [0,1]
Finding the CDF of Y:

FY(y) = P(Y≤y)
=
P(|X|≤y)
=
P(-y ≤ X ≤ y)
=
Fx(y) - Fx(-y)

So
FY(y) = Fx(y) - Fx(-y)

But the range of Y is [0,1] so I can get rid of the Fx(-y) and have

FY(y) = Fx(y) = y

So the CDF of Y is then

0 for y < 0
y for 0 ≤ y ≤ 1
1 for y≥1

To find the PDF, I can just take the derivative and have

1 for 0 ≤ y ≤ 1
0 otherwise

Is this correct?
 
Physics news on Phys.org
  • #2
izelkay said:

Homework Statement


If X is uniformly distributed over (0,1), find the PDF of Y = |X| and Z = e^X

Focusing on the |X| one

Homework Equations


Derivative of CDF is the PDF

The Attempt at a Solution


So I start by writing down the CDF of X, Fx(x):

0 for x <0
x for 0 ≤ x ≤ 1
1 for x ≥ 1

And I also know the range of Y = |X| is [0,1]
Finding the CDF of Y:

FY(y) = P(Y≤y)
=
P(|X|≤y)
=
P(-y ≤ X ≤ y)
=
Fx(y) - Fx(-y)

So
FY(y) = Fx(y) - Fx(-y)

But the range of Y is [0,1] so I can get rid of the Fx(-y) and have

FY(y) = Fx(y) = y

So the CDF of Y is then

0 for y < 0
y for 0 ≤ y ≤ 1
1 for y≥1

To find the PDF, I can just take the derivative and have

1 for 0 ≤ y ≤ 1
0 otherwise

Is this correct?

You can simplify the argument by noting that, for X ~ Unif(0,1), we have |X| = X for all nonzero values of X; this just eliminates any need to look at the zero-probability values X < 0 or X > 1. (However, to a certain extent, the way you should do it depends on how your textbook or course notes do it.)
 
  • #3
Is the way I approached it correct though?
Like for example, if I changed the problem statement so that X is uniformly distributed over (-5,5) and I want to find the PDF of Y= |X|, then the range of Y would be [0,5].

The CDF of X is

0 for x < 0
x for -5 ≤ x ≤ 5
1 for x > 5

Repeating the process I did before, the CDF of Y would be

0 for y < 0
y for 0 ≤ y ≤ 5
1 for y > 5

Then the PDF would be
1 for 0 < y < 5
0 otherwise
 
  • #4
izelkay said:
Is the way I approached it correct though?
Like for example, if I changed the problem statement so that X is uniformly distributed over (-5,5) and I want to find the PDF of Y= |X|, then the range of Y would be [0,5].

The CDF of X is

0 for x < 0
x for -5 ≤ x ≤ 5
1 for x > 5

Repeating the process I did before, the CDF of Y would be

0 for y < 0
y for 0 ≤ y ≤ 5
1 for y > 5

Then the PDF would be
1 for 0 < y < 5
0 otherwise

That is obviously wrong because the area under its graph is 5, not 1. You have the wrong distribution at the beginning for a uniform distribution on (-5,5).
 
  • #5
LCKurtz said:
That is obviously wrong because the area under its graph is 5, not 1. You have the wrong distribution at the beginning for a uniform distribution on (-5,5).
Oh oops, I meant to write:

The CDF of X is

0 for x < -5
x for -5 ≤ x ≤ 5
1 for x > 5

Is that correct?

And then I'm not quite sure I understand what you mean by "the area under its graph is 5, not 1".
How would I find the PDF of Y?

If I find the CDF first:
FY(y) = P(Y≤y)
=
P(|X|≤y)
=
P(-y ≤ X ≤ y)
=
Fx(y) - Fx(-y)

So
FY(y) = Fx(y) - Fx(-y)

But the range of Y is [0,5], so

FY(y) = Fx(y)

Then the pdf is (taking the derivative)

fY(y) = fx(y)

Which isn't 1 I guess; I'm stuck here.
 
  • #6
izelkay said:
Oh oops, I meant to write:

The CDF of X is

0 for x < -5
x for -5 ≤ x ≤ 5
1 for x > 5

Is that correct?

Check it for yourself. Do you have F(-5) = 0? Do you have F(5) = 1?

And then I'm not quite sure I understand what you mean by "the area under its graph is 5, not 1".

Do you know what is meant by the area under a graph? Do you know how to compute it?How would I find the PDF of Y?

If I find the CDF first:
FY(y) = P(Y≤y)
=
P(|X|≤y)
=
P(-y ≤ X ≤ y)
=
Fx(y) - Fx(-y)

So
FY(y) = Fx(y) - Fx(-y)

But the range of Y is [0,5], so

FY(y) = Fx(y)

Then the pdf is (taking the derivative)

fY(y) = fx(y)

Which isn't 1 I guess; I'm stuck here.
 
  • #7
Ok so I drew a picture of X:
j1dZEcY.png

Looking at this chart:
XRRRXWC.png

The pdf of X for mine must be 1/10 for -5 ≤ x ≤ 5 and 0 otherwise right?
And the CDF of X is
0 for x < -5
(x+5)/10 for -5 ≤ x < 5
1 for x ≥5
 
  • #8
"Do you know what is meant by the area under a graph? Do you know how to compute it?"

If the range of Y is [0,5]

Then the area under the PDF from [0,5] needs to be 1 correct? If I drew a picture similar to the one I drew for X, that would mean the height of the rectangle is 1/5. So is the PDF of Y

1/5 for 0 ≤ y ≤ 5
0 otherwise
?
 

1. What is the distribution of a function of a random variable?

The distribution of a function of a random variable refers to the probability distribution of the resulting values of a function when applied to a random variable. It shows the likelihood of each possible outcome of the function.

2. How is the distribution of a function of a random variable calculated?

The distribution of a function of a random variable can be calculated by first determining the distribution of the original random variable and then applying the function to each possible value. The resulting values are then used to create a new probability distribution.

3. What is the relationship between the distribution of a random variable and its function?

The distribution of a function of a random variable is dependent on the distribution of the original random variable. This means that the function can affect the shape and values of the distribution.

4. Can the distribution of a function of a random variable be predicted?

The distribution of a function of a random variable cannot be predicted with certainty. However, it can be estimated using mathematical techniques such as Monte Carlo simulation or through empirical methods using data.

5. Why is understanding the distribution of a function of a random variable important?

Understanding the distribution of a function of a random variable is important in many fields of science, such as statistics, economics, and engineering. It allows for the prediction of outcomes and the evaluation of the impact of a particular function on the overall distribution. Additionally, it can help in decision making and risk assessment.

Similar threads

  • Calculus and Beyond Homework Help
Replies
10
Views
381
  • Calculus and Beyond Homework Help
Replies
10
Views
831
  • Calculus and Beyond Homework Help
Replies
8
Views
477
  • Calculus and Beyond Homework Help
Replies
23
Views
1K
  • Calculus and Beyond Homework Help
Replies
18
Views
1K
  • Computing and Technology
Replies
9
Views
453
  • Calculus and Beyond Homework Help
Replies
1
Views
1K
Replies
23
Views
1K
  • Calculus and Beyond Homework Help
Replies
1
Views
736
  • Calculus and Beyond Homework Help
Replies
2
Views
285
Back
Top