CDF and PDF of absolute difference of two exponential random variables.
up vote
0
down vote
favorite
I'm studying probability theory and came across an exercise problem that I would like to request some help with. Here's the problem:
Let $X$ and $Y$ be i.i.d. random variables with Expo($1$), and let $Z = | X - Y |$. Find the CDF and PDF of $Z$.
My attempt
begin{align}
F_Z(z) & = P(Z le z)\
& = P(|X - Y| le z) \
& = P(-z le X - Y le z) \
& = P(X - Y le z) - P(X - Y le -z) \
& = P(X le Y + z) - P(X le Y - z) \
& = F_X(Y + z) - F_X(Y - z) \
& = (1 - e^{-(Y + z)}) - (1 - e^{-(Y - z)}) \
& = e^{-(Y - z)} - e^{-(Y + z)} \
end{align}
begin{align}
f_Z(z) & = frac{d}{dz}F_Z(z) \
& = frac{d}{dz}(e^{-(Y-z)} - e^{-(Y + z)}) \
& = e^{-(Y - z)} + e^{-(Y + z)} \
end{align}
The problems/questions that I have are
I'm not sure if this approach is even correct. I'm sure that I have to find the CDF first then differentiate it, but is this the correct way?
How do I handle the $Y$ in the final equations?
Thank you.
probability exponential-distribution
add a comment |
up vote
0
down vote
favorite
I'm studying probability theory and came across an exercise problem that I would like to request some help with. Here's the problem:
Let $X$ and $Y$ be i.i.d. random variables with Expo($1$), and let $Z = | X - Y |$. Find the CDF and PDF of $Z$.
My attempt
begin{align}
F_Z(z) & = P(Z le z)\
& = P(|X - Y| le z) \
& = P(-z le X - Y le z) \
& = P(X - Y le z) - P(X - Y le -z) \
& = P(X le Y + z) - P(X le Y - z) \
& = F_X(Y + z) - F_X(Y - z) \
& = (1 - e^{-(Y + z)}) - (1 - e^{-(Y - z)}) \
& = e^{-(Y - z)} - e^{-(Y + z)} \
end{align}
begin{align}
f_Z(z) & = frac{d}{dz}F_Z(z) \
& = frac{d}{dz}(e^{-(Y-z)} - e^{-(Y + z)}) \
& = e^{-(Y - z)} + e^{-(Y + z)} \
end{align}
The problems/questions that I have are
I'm not sure if this approach is even correct. I'm sure that I have to find the CDF first then differentiate it, but is this the correct way?
How do I handle the $Y$ in the final equations?
Thank you.
probability exponential-distribution
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I'm studying probability theory and came across an exercise problem that I would like to request some help with. Here's the problem:
Let $X$ and $Y$ be i.i.d. random variables with Expo($1$), and let $Z = | X - Y |$. Find the CDF and PDF of $Z$.
My attempt
begin{align}
F_Z(z) & = P(Z le z)\
& = P(|X - Y| le z) \
& = P(-z le X - Y le z) \
& = P(X - Y le z) - P(X - Y le -z) \
& = P(X le Y + z) - P(X le Y - z) \
& = F_X(Y + z) - F_X(Y - z) \
& = (1 - e^{-(Y + z)}) - (1 - e^{-(Y - z)}) \
& = e^{-(Y - z)} - e^{-(Y + z)} \
end{align}
begin{align}
f_Z(z) & = frac{d}{dz}F_Z(z) \
& = frac{d}{dz}(e^{-(Y-z)} - e^{-(Y + z)}) \
& = e^{-(Y - z)} + e^{-(Y + z)} \
end{align}
The problems/questions that I have are
I'm not sure if this approach is even correct. I'm sure that I have to find the CDF first then differentiate it, but is this the correct way?
How do I handle the $Y$ in the final equations?
Thank you.
probability exponential-distribution
I'm studying probability theory and came across an exercise problem that I would like to request some help with. Here's the problem:
Let $X$ and $Y$ be i.i.d. random variables with Expo($1$), and let $Z = | X - Y |$. Find the CDF and PDF of $Z$.
My attempt
begin{align}
F_Z(z) & = P(Z le z)\
& = P(|X - Y| le z) \
& = P(-z le X - Y le z) \
& = P(X - Y le z) - P(X - Y le -z) \
& = P(X le Y + z) - P(X le Y - z) \
& = F_X(Y + z) - F_X(Y - z) \
& = (1 - e^{-(Y + z)}) - (1 - e^{-(Y - z)}) \
& = e^{-(Y - z)} - e^{-(Y + z)} \
end{align}
begin{align}
f_Z(z) & = frac{d}{dz}F_Z(z) \
& = frac{d}{dz}(e^{-(Y-z)} - e^{-(Y + z)}) \
& = e^{-(Y - z)} + e^{-(Y + z)} \
end{align}
The problems/questions that I have are
I'm not sure if this approach is even correct. I'm sure that I have to find the CDF first then differentiate it, but is this the correct way?
How do I handle the $Y$ in the final equations?
Thank you.
probability exponential-distribution
probability exponential-distribution
edited 11 hours ago
asked 11 hours ago
Sean
20410
20410
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
up vote
1
down vote
Sadly, your answer cannot be correct because the random variable $Y$ remains in your CDF and PDF. The CDF of $Z$ should be only a function of $z$ and the parameters.
Your initial approach is sound, however. Let's see how to complete it.
$$Pr[Z le z] = Pr[X le Y + z] - Pr[X le Y - z]$$ is correct. Now, let's see how to attack each term on the right. We have
$$Pr[X le Y + z] = int_{y=0}^infty Pr[X le y + z] f_Y(y) , dy,$$ by the law of total probability. This in turn yields $$Pr[X le Y + z] = int_{y=0}^infty (1 - e^{-(y+z)}) e^{-y} , dy = 1 - e^{-z}/2.$$ Similarly, $$Pr[X le Y - z] = int_{y=0}^infty Pr[X le y - z]f_Y(y) , dy.$$ However, you must be careful here. Whereas in the first case we had no issues with $y + z < 0$, since $y$ and $z$ must both be nonnegative, in this situation we could have $0 le y < z$, in which case $Pr[X le y-z] = 0$, because $X$ cannot be negative. Consequently, we can write this as $$Pr[X le Y - z] = int_{y=z}^infty Pr[X le y-z] f_Y(y) , dy,$$ noting that the lower limit of integration can begin at $y = z$, since on the interval $y in [0,z)$, the integrand is zero.
I have left the remaining calculations as an exercise. What is your result? Is it surprising? If so, how might you go about verifying it?
add a comment |
up vote
0
down vote
Since $Z > 0$ a.s. we can assume that $z > 0$ in $P(Z leq z)$. Then you get $P(X leq Y +z) - P(X leq Y -z)$. Since $X$ and $Y$ are exponentialy distributed they are a.s. positive, so $Y + z > 0$ therefore part $P(X leq Y+z)$ is fine. On the other hand we must be careful with $P(X leq Y-z)$. Since total probability rule
begin{align}
P(X leq Y-z) & = P(X leq Y-z |Y leq z)P(Yleq z) + P(X leq Y-z |Y> z)P(Y>z) \
& = P(Xleq Y-z|Y > z)P(Y>z)
end{align}
But what is $P(X leq Y-z)$? It is some number between 0 an 1 dependent only on parameter $z$. But it involves two random variables, so just as in one dimensional case where you integrate density over subcpace of real line to get $P(X leq z)$, here we must integrate joint densities of both random variables over some subspace of plane (since $X$ and $Y$ are independent we can take product of their densities instead). So
begin{align}
P(X leq Y -z) & = int_z^{infty} int_0^{y-z} e^{-y}e^{-x}dx dy \
& = -left(frac{e^{-z}}{2}-e^{-z}right)
end{align}
In same way, only that we integrate over different region, we get $P(X leq Y+z) = -left(frac{1}{2}e^{-z}-1right)$. Then when you take in account that $P(Y > z ) = e^{-z}$ everything else is just elementary computation.
To get PDF you must of course differentiate CDF of $Z$ (in fact $Z$ must be absolutely continuous but in this, as in most cases, it is). But again CDF and PDF respectively must be functions of only $z$.
add a comment |
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
Sadly, your answer cannot be correct because the random variable $Y$ remains in your CDF and PDF. The CDF of $Z$ should be only a function of $z$ and the parameters.
Your initial approach is sound, however. Let's see how to complete it.
$$Pr[Z le z] = Pr[X le Y + z] - Pr[X le Y - z]$$ is correct. Now, let's see how to attack each term on the right. We have
$$Pr[X le Y + z] = int_{y=0}^infty Pr[X le y + z] f_Y(y) , dy,$$ by the law of total probability. This in turn yields $$Pr[X le Y + z] = int_{y=0}^infty (1 - e^{-(y+z)}) e^{-y} , dy = 1 - e^{-z}/2.$$ Similarly, $$Pr[X le Y - z] = int_{y=0}^infty Pr[X le y - z]f_Y(y) , dy.$$ However, you must be careful here. Whereas in the first case we had no issues with $y + z < 0$, since $y$ and $z$ must both be nonnegative, in this situation we could have $0 le y < z$, in which case $Pr[X le y-z] = 0$, because $X$ cannot be negative. Consequently, we can write this as $$Pr[X le Y - z] = int_{y=z}^infty Pr[X le y-z] f_Y(y) , dy,$$ noting that the lower limit of integration can begin at $y = z$, since on the interval $y in [0,z)$, the integrand is zero.
I have left the remaining calculations as an exercise. What is your result? Is it surprising? If so, how might you go about verifying it?
add a comment |
up vote
1
down vote
Sadly, your answer cannot be correct because the random variable $Y$ remains in your CDF and PDF. The CDF of $Z$ should be only a function of $z$ and the parameters.
Your initial approach is sound, however. Let's see how to complete it.
$$Pr[Z le z] = Pr[X le Y + z] - Pr[X le Y - z]$$ is correct. Now, let's see how to attack each term on the right. We have
$$Pr[X le Y + z] = int_{y=0}^infty Pr[X le y + z] f_Y(y) , dy,$$ by the law of total probability. This in turn yields $$Pr[X le Y + z] = int_{y=0}^infty (1 - e^{-(y+z)}) e^{-y} , dy = 1 - e^{-z}/2.$$ Similarly, $$Pr[X le Y - z] = int_{y=0}^infty Pr[X le y - z]f_Y(y) , dy.$$ However, you must be careful here. Whereas in the first case we had no issues with $y + z < 0$, since $y$ and $z$ must both be nonnegative, in this situation we could have $0 le y < z$, in which case $Pr[X le y-z] = 0$, because $X$ cannot be negative. Consequently, we can write this as $$Pr[X le Y - z] = int_{y=z}^infty Pr[X le y-z] f_Y(y) , dy,$$ noting that the lower limit of integration can begin at $y = z$, since on the interval $y in [0,z)$, the integrand is zero.
I have left the remaining calculations as an exercise. What is your result? Is it surprising? If so, how might you go about verifying it?
add a comment |
up vote
1
down vote
up vote
1
down vote
Sadly, your answer cannot be correct because the random variable $Y$ remains in your CDF and PDF. The CDF of $Z$ should be only a function of $z$ and the parameters.
Your initial approach is sound, however. Let's see how to complete it.
$$Pr[Z le z] = Pr[X le Y + z] - Pr[X le Y - z]$$ is correct. Now, let's see how to attack each term on the right. We have
$$Pr[X le Y + z] = int_{y=0}^infty Pr[X le y + z] f_Y(y) , dy,$$ by the law of total probability. This in turn yields $$Pr[X le Y + z] = int_{y=0}^infty (1 - e^{-(y+z)}) e^{-y} , dy = 1 - e^{-z}/2.$$ Similarly, $$Pr[X le Y - z] = int_{y=0}^infty Pr[X le y - z]f_Y(y) , dy.$$ However, you must be careful here. Whereas in the first case we had no issues with $y + z < 0$, since $y$ and $z$ must both be nonnegative, in this situation we could have $0 le y < z$, in which case $Pr[X le y-z] = 0$, because $X$ cannot be negative. Consequently, we can write this as $$Pr[X le Y - z] = int_{y=z}^infty Pr[X le y-z] f_Y(y) , dy,$$ noting that the lower limit of integration can begin at $y = z$, since on the interval $y in [0,z)$, the integrand is zero.
I have left the remaining calculations as an exercise. What is your result? Is it surprising? If so, how might you go about verifying it?
Sadly, your answer cannot be correct because the random variable $Y$ remains in your CDF and PDF. The CDF of $Z$ should be only a function of $z$ and the parameters.
Your initial approach is sound, however. Let's see how to complete it.
$$Pr[Z le z] = Pr[X le Y + z] - Pr[X le Y - z]$$ is correct. Now, let's see how to attack each term on the right. We have
$$Pr[X le Y + z] = int_{y=0}^infty Pr[X le y + z] f_Y(y) , dy,$$ by the law of total probability. This in turn yields $$Pr[X le Y + z] = int_{y=0}^infty (1 - e^{-(y+z)}) e^{-y} , dy = 1 - e^{-z}/2.$$ Similarly, $$Pr[X le Y - z] = int_{y=0}^infty Pr[X le y - z]f_Y(y) , dy.$$ However, you must be careful here. Whereas in the first case we had no issues with $y + z < 0$, since $y$ and $z$ must both be nonnegative, in this situation we could have $0 le y < z$, in which case $Pr[X le y-z] = 0$, because $X$ cannot be negative. Consequently, we can write this as $$Pr[X le Y - z] = int_{y=z}^infty Pr[X le y-z] f_Y(y) , dy,$$ noting that the lower limit of integration can begin at $y = z$, since on the interval $y in [0,z)$, the integrand is zero.
I have left the remaining calculations as an exercise. What is your result? Is it surprising? If so, how might you go about verifying it?
answered 9 hours ago
heropup
61.8k65997
61.8k65997
add a comment |
add a comment |
up vote
0
down vote
Since $Z > 0$ a.s. we can assume that $z > 0$ in $P(Z leq z)$. Then you get $P(X leq Y +z) - P(X leq Y -z)$. Since $X$ and $Y$ are exponentialy distributed they are a.s. positive, so $Y + z > 0$ therefore part $P(X leq Y+z)$ is fine. On the other hand we must be careful with $P(X leq Y-z)$. Since total probability rule
begin{align}
P(X leq Y-z) & = P(X leq Y-z |Y leq z)P(Yleq z) + P(X leq Y-z |Y> z)P(Y>z) \
& = P(Xleq Y-z|Y > z)P(Y>z)
end{align}
But what is $P(X leq Y-z)$? It is some number between 0 an 1 dependent only on parameter $z$. But it involves two random variables, so just as in one dimensional case where you integrate density over subcpace of real line to get $P(X leq z)$, here we must integrate joint densities of both random variables over some subspace of plane (since $X$ and $Y$ are independent we can take product of their densities instead). So
begin{align}
P(X leq Y -z) & = int_z^{infty} int_0^{y-z} e^{-y}e^{-x}dx dy \
& = -left(frac{e^{-z}}{2}-e^{-z}right)
end{align}
In same way, only that we integrate over different region, we get $P(X leq Y+z) = -left(frac{1}{2}e^{-z}-1right)$. Then when you take in account that $P(Y > z ) = e^{-z}$ everything else is just elementary computation.
To get PDF you must of course differentiate CDF of $Z$ (in fact $Z$ must be absolutely continuous but in this, as in most cases, it is). But again CDF and PDF respectively must be functions of only $z$.
add a comment |
up vote
0
down vote
Since $Z > 0$ a.s. we can assume that $z > 0$ in $P(Z leq z)$. Then you get $P(X leq Y +z) - P(X leq Y -z)$. Since $X$ and $Y$ are exponentialy distributed they are a.s. positive, so $Y + z > 0$ therefore part $P(X leq Y+z)$ is fine. On the other hand we must be careful with $P(X leq Y-z)$. Since total probability rule
begin{align}
P(X leq Y-z) & = P(X leq Y-z |Y leq z)P(Yleq z) + P(X leq Y-z |Y> z)P(Y>z) \
& = P(Xleq Y-z|Y > z)P(Y>z)
end{align}
But what is $P(X leq Y-z)$? It is some number between 0 an 1 dependent only on parameter $z$. But it involves two random variables, so just as in one dimensional case where you integrate density over subcpace of real line to get $P(X leq z)$, here we must integrate joint densities of both random variables over some subspace of plane (since $X$ and $Y$ are independent we can take product of their densities instead). So
begin{align}
P(X leq Y -z) & = int_z^{infty} int_0^{y-z} e^{-y}e^{-x}dx dy \
& = -left(frac{e^{-z}}{2}-e^{-z}right)
end{align}
In same way, only that we integrate over different region, we get $P(X leq Y+z) = -left(frac{1}{2}e^{-z}-1right)$. Then when you take in account that $P(Y > z ) = e^{-z}$ everything else is just elementary computation.
To get PDF you must of course differentiate CDF of $Z$ (in fact $Z$ must be absolutely continuous but in this, as in most cases, it is). But again CDF and PDF respectively must be functions of only $z$.
add a comment |
up vote
0
down vote
up vote
0
down vote
Since $Z > 0$ a.s. we can assume that $z > 0$ in $P(Z leq z)$. Then you get $P(X leq Y +z) - P(X leq Y -z)$. Since $X$ and $Y$ are exponentialy distributed they are a.s. positive, so $Y + z > 0$ therefore part $P(X leq Y+z)$ is fine. On the other hand we must be careful with $P(X leq Y-z)$. Since total probability rule
begin{align}
P(X leq Y-z) & = P(X leq Y-z |Y leq z)P(Yleq z) + P(X leq Y-z |Y> z)P(Y>z) \
& = P(Xleq Y-z|Y > z)P(Y>z)
end{align}
But what is $P(X leq Y-z)$? It is some number between 0 an 1 dependent only on parameter $z$. But it involves two random variables, so just as in one dimensional case where you integrate density over subcpace of real line to get $P(X leq z)$, here we must integrate joint densities of both random variables over some subspace of plane (since $X$ and $Y$ are independent we can take product of their densities instead). So
begin{align}
P(X leq Y -z) & = int_z^{infty} int_0^{y-z} e^{-y}e^{-x}dx dy \
& = -left(frac{e^{-z}}{2}-e^{-z}right)
end{align}
In same way, only that we integrate over different region, we get $P(X leq Y+z) = -left(frac{1}{2}e^{-z}-1right)$. Then when you take in account that $P(Y > z ) = e^{-z}$ everything else is just elementary computation.
To get PDF you must of course differentiate CDF of $Z$ (in fact $Z$ must be absolutely continuous but in this, as in most cases, it is). But again CDF and PDF respectively must be functions of only $z$.
Since $Z > 0$ a.s. we can assume that $z > 0$ in $P(Z leq z)$. Then you get $P(X leq Y +z) - P(X leq Y -z)$. Since $X$ and $Y$ are exponentialy distributed they are a.s. positive, so $Y + z > 0$ therefore part $P(X leq Y+z)$ is fine. On the other hand we must be careful with $P(X leq Y-z)$. Since total probability rule
begin{align}
P(X leq Y-z) & = P(X leq Y-z |Y leq z)P(Yleq z) + P(X leq Y-z |Y> z)P(Y>z) \
& = P(Xleq Y-z|Y > z)P(Y>z)
end{align}
But what is $P(X leq Y-z)$? It is some number between 0 an 1 dependent only on parameter $z$. But it involves two random variables, so just as in one dimensional case where you integrate density over subcpace of real line to get $P(X leq z)$, here we must integrate joint densities of both random variables over some subspace of plane (since $X$ and $Y$ are independent we can take product of their densities instead). So
begin{align}
P(X leq Y -z) & = int_z^{infty} int_0^{y-z} e^{-y}e^{-x}dx dy \
& = -left(frac{e^{-z}}{2}-e^{-z}right)
end{align}
In same way, only that we integrate over different region, we get $P(X leq Y+z) = -left(frac{1}{2}e^{-z}-1right)$. Then when you take in account that $P(Y > z ) = e^{-z}$ everything else is just elementary computation.
To get PDF you must of course differentiate CDF of $Z$ (in fact $Z$ must be absolutely continuous but in this, as in most cases, it is). But again CDF and PDF respectively must be functions of only $z$.
edited 8 hours ago
answered 9 hours ago
Jan Rems
163
163
add a comment |
add a comment |
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3000818%2fcdf-and-pdf-of-absolute-difference-of-two-exponential-random-variables%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown