# Combining exponential distributions

#### gnome

Suppose I have several exponentially distributed random variables, each of them representing the probability that some particular event occurs within some amount of time. I can't seem to come up with any intuition as to how to combine those density functions (or distribution functions) to express probabilities about ANY of the events occurring.

To give a concrete example, say the A-train and the B-train arrive on separate tracks and their inter-arrival times are independent of each other, and let $$X$$ be the continuous rv representing the amount of time until a train arrives. Say the density functions and distribution functions for the two train lines are given by:
$$f_a(x) = \frac{1}{4} e^{-\frac{x}{4}} \qquad F_a(x) = 1 - e^{-\frac{x}{4}} \qquad \mbox{ for } x>0 \mbox{, and 0 otherwise}$$
$$f_b(x) = \frac{1}{5} e^{-\frac{x}{5}} \qquad F_b(x) = 1 - e^{-\frac{x}{5}} \qquad \mbox{ for } x>0 \mbox{, and 0 otherwise}$$

so the expected time until an A-train arrives $$E_a[x] = 4\mbox{ min.}$$
and the expected time until a B-train arrives $$E_b[x] = 5\mbox{ min.}$$
and it is easy to determine the probability for an A-train to arrive within any specific amount of time, and similarly for a B-train.

But how can those functions be combined into a single distribution to express the expected time $$E_{a|b}[x]$$ until ANY train arrives, or the probability that ANY train will arrive within, say 2 minutes?

Related Set Theory, Logic, Probability, Statistics News on Phys.org

#### John Creighto

If two random variables are independent then:

P(a,b)=P(a)P(b)

Thus just multiply the distribution functions. You can also easily derive expressions for correlated random variables because you can use linear algebra to diagonalize the random variables and find a linear transformation between the correlated random variables and a new set of independent random variables.

#### gnome

Running helps to clear the cobwebs.

If two random variables are independent then:

P(a,b)=P(a)P(b)
It's not the joint probability I'm looking for; that would be the probability that both an A-train and a B-train arrive by time x. I guess the probability I want may be called $$P_{a \cup \, b}(x)$$. But here's what occurred to me. The probability that any train will arrive by time x is 1 minus the joint probability that (neither an A-train nor a B-train arrives by time x) so

\begin{align*} F(x) = P_{a \cup \, b}(x) &= 1 - e^{-\frac{x}{4}}e^{-\frac{x}{5}} \\ &= 1 - e^{-\frac{9x}{20}} \end{align*}
and therefore just taking the derivative of that gives me
$$f(x) = \frac{9}{20} e^{-\frac{9x}{20}}$$
which is an exponential distribution with an expectation of 20/9, i.e. the expected arrival time of some train, on either track, is about 2.22 minutes.

That seems plausible. Is it correct?

#### John Creighto

Running helps to clear the cobwebs.

It's not the joint probability I'm looking for; that would be the probability that both an A-train and a B-train arrive by time x. I guess the probability I want may be called $$P_{a \cup \, b}(x)$$. But here's what occurred to me. The probability that any train will arrive by time x is 1 minus the joint probability that (neither an A-train nor a B-train arrives by time x) so

\begin{align*} F(x) = P_{a \cup \, b}(x) &= 1 - e^{-\frac{x}{4}}e^{-\frac{x}{5}} \\ &= 1 - e^{-\frac{9x}{20}} \end{align*}
and therefore just taking the derivative of that gives me
$$f(x) = \frac{9}{20} e^{-\frac{9x}{20}}$$
which is an exponential distribution with an expectation of 20/9, i.e. the expected arrival time of some train, on either track, is about 2.22 minutes.

That seems plausible. Is it correct?
I don't think your right. Sorry for misreading it earlier. Here is what I think you want:

$$P(a \cup b)=P(a-ab)+P(ab)+P(b-ab)$$

and I think (let met think about it though):

$$P(a-ab)=P(a)(1-P(b))$$
$$P(b-ab)=P(b)(1-P(a))$$

edit: This seems to simplify to, P(a)+P(b)-2P(ab)

#### gnome

I don't know what you mean by $$P(a), P(b), P(ab)$$, etc. I'm talking about the probability that an event a will occur within a specified amount of time x, the probability that event b will occur within that amount of time, and the probability that either event (don't care which) will occur within that amount of time. I may be wrong, but you appear to be thinking about whether a, b, or either event occurs at all, which is a completely different thing. (Where is the element of time in what you are suggesting?)

You seem to be trying to get to the general expression for probability of the union of two events, which is actually
$$P(A \cup \, B) = P(A) + P(B) - P(AB)$$
but I don't see how that applies here.

#### John Creighto

I don't know what you mean by $$P(a), P(b), P(ab)$$, etc. I'm talking about the probability that an event a will occur within a specified amount of time x, the probability that event b will occur within that amount of time, and the probability that either event (don't care which) will occur within that amount of time. I may be wrong, but you appear to be thinking about whether a, b, or either event occurs at all, which is a completely different thing. (Where is the element of time in what you are suggesting?)

You seem to be trying to get to the general expression for probability of the union of two events, which is actually
$$P(A \cup \, B) = P(A) + P(B) - P(AB)$$
but I don't see how that applies here.
Thanks for the correction.

I'm going to clarify what I was thinking but I guess it turns out you were correct in your previous post. I didn't have much time to think about the problem in my past posts so I ended up not reading clearly and thinking it through enough.

Let $$X_a$$ be the random variable that gives the time train A will arrive and $$X_b$$ be the random variable that gives the time train B will be arrive. We want to know if either train A or train B or both arived in a time less then t. Therefore we want

$$P(X_a<t \cup X_a<t)$$

We should agree from the general expression for probability of the union that:

$$P(X_a<t \cup X_a<t)=P(X_a<t)+P(X_b<t) - P(X_b<t \cap X_a<t)$$

Given the distributions are independent we can write:

$$F_{a \cup b}(t)=F_a(t)+F_b(t)-F_a(t)F_b(t)$$
$$=( 1 - e^{-\frac{x}{4}})+(1 - e^{-\frac{x}{5}})-( 1 - e^{-\frac{x}{4}})(1 - e^{-\frac{x}{5}})$$
$$=1-e^{-\frac{9x}{20}}$$

Which is of course what you gave as the answer in your previous post. What I didn't realize is how you arrived at the answer since a few steps were left out.

### Physics Forums Values

We Value Quality
• Topics based on mainstream science
• Proper English grammar and spelling
We Value Civility
• Positive and compassionate attitudes
• Patience while debating
We Value Productivity
• Disciplined to remain on-topic
• Recognition of own weaknesses
• Solo and co-op problem solving