# stop that bus!

Show 40 post(s) from this thread on one page
Page 1 of 2 12 Last
• Jul 11th 2008, 01:33 AM
alv
stop that bus!
A bus moves with k travelers, and it can stop in n stations according to every traveler's request. The probability of getting down for every traveler is the same and independent of other travelers' getting out. The bus stops given that at least one traveler request to get down. What is the mathematical expectation for the number of stops?
• Jul 11th 2008, 02:32 PM
Jhevon
Quote:

Originally Posted by alv
A bus moves with k travelers, and it can stop in n stations according to every traveler's request. The probability of getting down for every traveler is the same and independent of other travelers' getting out. The bus stops given that at least one traveler request to get down. What is the mathematical expectation for the number of stops?

as a noob when it comes to probability, i shall take a stab at this one.

we have independent events here, and we have two outcomes which are the same for each passenger involved (the bus stops for you or not). we can deem the bus stopping as a "success" and the bus not stopping as a "failure" and use the binomial distribution.

recall that the probability of $k$ successes in $n$ independent trials is given by:

$P(k) = {n \choose k} p^kq^{n - k}$

where $p$ is the probability of success, and $q = 1 - p$ is the probability of failure

Now, you want $P(X \le k)$, where $X$ is a discrete random variable for the number of stops the bus will make. so you add all the probabilities from 1 up to k inclusive.

Now recall that for a random variable $X$, with probability mass function given by $p(x)$ (here, that is given by the formula for the binomial distribution), has expected value:

$E(X) = \sum_i x_i p(x_i)$

now replace $p(x)$ with the formula for the binomial distribution, and sum from $i$ goes from $1$ up to $n$, where $1 \le n \le k$.
• Jul 11th 2008, 02:59 PM
meymathis
Sadly, I don't think you can use the binomial distribution. That gives you the number of True's or successes given n trials, given a probability of true for 1 trial being p. What would be a trial? If it's the person getting off, then it would be possible for them to get off more than once since you repeat the trial n times. I don't see how we can fit this into that distribution. But maybe I'm missing something obvious.(Worried)
• Jul 11th 2008, 03:17 PM
awkward
Quote:

Originally Posted by alv
A bus moves with k travelers, and it can stop in n stations according to every traveler's request. The probability of getting down for every traveler is the same and independent of other travelers' getting out. The bus stops given that at least one traveler request to get down. What is the mathematical expectation for the number of stops?

Let $X_i = 1$ if at least one passenger gets off at stop $i$, $0$ otherwise.

The probability that any given passenger gets off at stop $i \text{ is } 1/n$, so

$Pr(X_i=0) = (1-1/n)^k \text{ for } i = 1,2, \dots ,n$

hence $E(X_i) = Pr(X_i = 1) = 1 - (1-1/n)^k$

Then
$E(\sum_{i=1}^n X_i) = \sum_{i=1}^n E(X_i) = \sum_{i=1}^n [1- (1-1/n)^k] = n [1 - (1-1/n)^k]$
• Jul 11th 2008, 03:24 PM
meymathis
The $X_i$ measures how many people got off at a stop i.

Shouldn't
$
\sum_{i=1}^n X_i = k$

There are only k people and they all have to get off.
• Jul 11th 2008, 04:25 PM
mr fantastic
Quote:

Originally Posted by meymathis
The $X_i$ measures how many people got off at a stop i.

Shouldn't
$
\sum_{i=1}^n X_i = k$

There are only k people and they all have to get off.

No.

Quote:

$X_i$ measures how many people got off at a stop i
is an incorrect interpretation of the random variable $X_i$.

Eg. If all passengers get off at stop 1 then $X_1 = 1$ and all other $X_i$ are equal to zero. Hence $\sum_{i=1}^n X_i = 1$ in this case.
• Jul 11th 2008, 04:43 PM
meymathis
Quote:

Originally Posted by awkward
Let $X_i = 1$ if at least one passenger gets off at stop $i$, $0$ otherwise.

The probability that any given passenger gets off at stop $i \text{ is } 1/n$, so

$Pr(X_i=0) = (1-1/n)^k \text{ for } i = 1,2, \dots ,n$

hence $E(X_i) = Pr(X_i = 1) = 1 - (1-1/n)^k$

Then
$E(\sum_{i=1}^n X_i) = \sum_{i=1}^n E(X_i) = \sum_{i=1}^n [1- (1-1/n)^k] = n [1 - (1-1/n)^k]$

My bad. I misread how $X_i$ was defined. However, I just don't see how any of this ensures that k people get off of the bus. If you treat each stop completely seperately without taking into account how people there were and how many got off the bus, I don't see how you can do the problem.

For example, based on the above $\mathbf{P}(\sum_{x=1}^{n}X_i>k)>0$ which is impossible.
• Jul 11th 2008, 04:50 PM
mr fantastic
Quote:

Originally Posted by meymathis
My bad. I misread how $X_i$ was defined. However, I just don't see how any of this ensures that k people get off of the bus. If you treat each stop completely seperately without taking into account how people there were and how many got off the bus, I don't see how you can do the problem.

For example, based on the above $\mathbf{P}(\sum_{x=1}^{n}X_i>k)>0$ which is impossible.

$\mathbf{P}(\sum_{x=1}^{n}X_i > k){\color{red}=}0$ which is exactly as things should be.

It follows from the definition that $1 \leq \sum_{x=1}^{n}X_i \leq k$.
• Jul 11th 2008, 06:02 PM
awkward
Quote:

Originally Posted by awkward
Let $X_i = 1$ if at least one passenger gets off at stop $i$, $0$ otherwise.

The probability that any given passenger gets off at stop $i \text{ is } 1/n$, so

$Pr(X_i=0) = (1-1/n)^k \text{ for } i = 1,2, \dots ,n$

hence $E(X_i) = Pr(X_i = 1) = 1 - (1-1/n)^k$

Then
$E(\sum_{i=1}^n X_i) = \sum_{i=1}^n E(X_i) = \sum_{i=1}^n [1- (1-1/n)^k] = n [1 - (1-1/n)^k]$

Mr. Fantastic's remarks above are exactly right. However, I can see that I should have provided a little more explanation. Maybe two observations will help clarify matters:

1. The $X_i$ variables are not independent. (But then, no one ever said they were.)

2. The key to the solution method is the simple yet powerful theorem, applied in the last line above, stating that $E(X+Y) = E(X) + E(Y)$. Independence of $X \text{ and } Y$ is not required for this result (a fact which always seems surprising to me).
• Jul 11th 2008, 06:58 PM
meymathis
Quote:

Originally Posted by mr fantastic
$\mathbf{P}(\sum_{x=1}^{n}X_i > k){\color{red}=}0$ which is exactly as things should be.

It follows from the definition that $1 \leq \sum_{x=1}^{n}X_i \leq k$.

With all due respect, no, it follows from the definition that $1 \leq \sum_{x=1}^{n}X_i \leq n$ The emphesis on the n.

Think about it. How can a binomial distribution represent this experiment? By definition, a binomial distribution describes an experiment in which you have n independent trials. But this is not the case for the above problem. If k-1 people get off at the first stop, the probability that 1 or more people get off at the next stop is different then it was at the first stop. That violates the assumptions.
• Jul 11th 2008, 08:32 PM
mr fantastic
Quote:

Originally Posted by meymathis
With all due respect, no, it follows from the definition that $1 \leq \sum_{x=1}^{n}X_i \leq n$ The emphesis on the n.

Think about it. How can a binomial distribution represent this experiment? By definition, a binomial distribution describes an experiment in which you have n independent trials. But this is not the case for the above problem. If k-1 people get off at the first stop, the probability that 1 or more people get off at the next stop is different then it was at the first stop. That violates the assumptions.

Where have a mentioned the binomial distribution? In fact, I thanked your reply (#2) as being useful for saying that that the binomial distribution is not applicable to this question!

You still do not understand what the random variable $X_i$ represents.

The maximum value of $\sum_{x=1}^{n}X_i$ IS equal to k and occurs when each of the k passengers gets off at a different bus stop. But even when that happens, some of the $X_i$'s will equal zero (assuming n > k).

How can the sum possibly be greater than k, the number of passengers? For the sum to be greater than k you need:

1. More than k passengers.

2. Each of those passengers to get off at a diferent bus stop.

Condition 1 is never satisfied.

If you're still unconvinced, please provide a concrete example, with specific values for each of the $X_i$'s, that supports your argument.
• Jul 12th 2008, 01:01 AM
alv
thanks
thanks all! :)
• Jul 12th 2008, 05:21 AM
meymathis
Quote:

Originally Posted by awkward
Let $X_i = 1$ if at least one passenger gets off at stop $i$, $0$ otherwise.

The probability that any given passenger gets off at stop $i \text{ is } 1/n$, so

$Pr(X_i=0) = (1-1/n)^k \text{ for } i = 1,2, \dots ,n$

hence $E(X_i) = Pr(X_i = 1) = 1 - (1-1/n)^k$

Then
$E(\sum_{i=1}^n X_i) = \sum_{i=1}^n E(X_i) = \sum_{i=1}^n [1- (1-1/n)^k] = n [1 - (1-1/n)^k]$

My apologies for some of the confusion (I'm new at the forums and didn't see your "thanks"). I thought people were arguing for the binomial distribution. Looking more carefully (which I should have done before) at awkward's example, the main thrust of my argument still holds, I think. Probably the most succinct way of saying it is this:
$Pr(X_i=0) = (1-1/n)^k \text{ for } i = 1,2, \dots ,n$
doesn't work because the number of people on the bus is not constantly $k$.

$\mathbf{P}(X_2=0|X_1=1)\neq$
$\mathbf{P}(X_2=0|X_1=0)$ because there are no longer k people on the bus, then
$Pr(X_2=0|X_1=1) = (1-1/n)^{k-l}$
where $l$ are the number of people that got off at the first stop.

Again, sorry for not being clearer before.
• Jul 12th 2008, 05:37 AM
meymathis
I guess why I said binomial distribution is that $\sum X_i$ is binomially distributed based on awkward's definition. There is some experiment with probability of success p that is repeated n times
• Jul 12th 2008, 11:28 AM
awkward
Quote:

Originally Posted by meymathis
With all due respect, no, it follows from the definition that $1 \leq \sum_{x=1}^{n}X_i \leq n$ The emphesis on the n.

Think about it. How can a binomial distribution represent this experiment? By definition, a binomial distribution describes an experiment in which you have n independent trials. But this is not the case for the above problem. If k-1 people get off at the first stop, the probability that 1 or more people get off at the next stop is different then it was at the first stop. That violates the assumptions.

It is true that $\sum_{x=1}^{n}X_i \leq n$-- you can't have the bus stop more times than there are stops. It is also true that $\sum_{x=1}^{n}X_i \leq k$-- you can't have the bus stop more times than there are passengers. By definition of the $X_i$, $\sum_{x=1}^{n}X_i$ is the total number of times the bus stops.

I agree with you that the Binomial distribution is not appropriate here. But then, I never said it was-- that was a post by someone else.

[I missed some of the posts above while I was composing this.]
Show 40 post(s) from this thread on one page
Page 1 of 2 12 Last