Jump to content
BrainDen.com - Brain Teasers
  • 0

Bus Schedule


bonanova
 Share

Question

I ran across this paradox in Quora. It resembles BMAD's points on circles problems and may clarify them.

You have been hired to test the timeliness of the your town's bus service. The city transportation authority is claiming that they schedule 4 buses per hour (according to a random process) i.e. about 1 bus every 15 minutes on average.

main-qimg-20a470df91c99788cf6787ac7bad57

To test this claim, you decide to drop by at a random time every day, ask the people at the bus stop how long they have been waiting, and wait till the first bus arrives. You do this for a month and record the total waiting times. Based on your study, you find that buses arrive every 20-30 minutes on average.

How is this possible?

Link to comment
Share on other sites

11 answers to this question

Recommended Posts

  • 0

could it be as simple as... (I couldn't find the spoiler button, so highlight below to see the text)

about 1 bus every 15 minutes on average

x bus : 15 minutes

1 bus: 20 minutes

x = .75 bus which is about 1 bus in a 15 minute period and therefore all parties can be right.

Highlight above.

Link to comment
Share on other sites

  • 0

I've asked site admin about the disappearing spoiler function ...

So anyway, the bus company claims the send a bus out onto the route every 15 minutes. When you check on the average wait time for a bus, you find that it's longer than 15 minutes, as much as 20-30 minutes. How is that possible?

Link to comment
Share on other sites

  • 1

Highlight text below to see my theory

While the average wait time should be 15 minutes, there are longer and shorter wait times during the day. A random placement of a point in time is more likely to land on a longer wait time period. For example, if we look at a 1 hour period that has two 10-minute waiting intervals and two 20-minute waiting intervals, then an average wait time is 15 minutes, but a random point in time selected within that hour is twice more likely to be within the 20-minute interval.

 

Link to comment
Share on other sites

  • 2

planglazed is right.

Spoiler

Assume you show up at time t=0 and there will be four buses arriving at random times between t=0 and t=60 minutes. What are the odds that you will be waiting at least x minutes for any given value of x? Arbitrarily number the buses #1, #2, #3, and #4 (the numbering does not necessarily correspond to the order in which they arrive). The probability that bus #1 doesn't arrive within x minutes is (60-x)/60. And the probability that all four buses arrive later than x minutes is [(60-x)/60]4. The probability that any one of the four buses will arrive before x minutes is one minus that, so 1 – [(60-x)/60]4.

"The probability that a bus will arrive within x minutes" is equivalent to "the integral of the probability density function of the next bus arriving at a specific time, integrated over the range from 0 to x minutes". So the probability density function is that thing's derivative, which is

d/dx 1 - [(60-x)/60]4

define u = 60-x, du/dx = -1

du/dx * d/du 1 - u4/604

4 u3 / 604

4 (60-x)3 / 604

To find your average wait time (ignoring all the other people waiting at the bus stop and their wait times for now), take the integral of (the wait time) times (the probability that you will be waiting for that period of time) over the range from x=0 to x=60.

56759074ae0b9_buswait.jpg.2a115e7e15ee34

Your average wait time is twelve minutes, but now how about all of those people that you met at the bus stop and asked how long they've been waiting? Since you will arrive at the bus stop at a time that can practically be considered as random, you can consider yourself to be a fifth bus, and ask how long people will be waiting until one bus out of five would arrive. Without going through all that math again (I'm, uh, intentionally leaving it as an exercise for the reader (and not eager to deal with the math involved in accounting for the fact that the wait time of everyone else waiting for a bus when you arrive will affect the probability that a bus will arrive for you within a following period of time)) it's probably somewhere in the ballpark of 10 minutes, so the average total wait time of everyone you interview would probably end up being around 20-24 minutes.

 

Link to comment
Share on other sites

  • 1

After further consideration

Spoiler

Consider a person waiting at the bus stop, and define the time that they arrive at the bus stop and start waiting for a bus as time 0. The odds that any given bus will arrive at the bus stop at any given time x between 0 and 60 minutes is uniform. The odds that you will arrive at the bus stop before time x (and therefore be able to ask the person how long they've been waiting) is x/60, and the odds that all three of the other buses will come after time x (therefore meaning the person will get on a bus at time x and not get on an earlier bus) is [(60-x)/60]3. So the odds of all of those happening is proportional to x(60-x)3 / 604.

To turn that into a probability density function, scale it so the integral from 0 to 60 minutes is 1.

56759d4952fe9_busformula2.jpg.6cd4b9a21d

So to scale it to make the integral be 1 you should multiply it by 1/3 and you have the probability density function

P(x) = x(60-x)3 / 3*604

To find the average wait time, integrate x*P(x) dx

56759d5006e09_busformula3.jpg.2670f7299f

 

 

Link to comment
Share on other sites

  • 0

plainglazed noted that the investigator measures the entire time interval between buses; k-man was first to hit on the crux of the correct analysis (getting the mark); and plasmid beautifully and comprehensively reminded me again that I used to know how to evaluate integrals. Uh, rephrase. Has reminded me that I no longer recall how to evaluate integrals ... without looking them up. Kudos to all. The idea is that

Spoiler

we only sample some of the wait times, and we're more likely to encounter the longer ones. Even if the city releases buses at regular intervals to start their daily runs, they are not likely to retain their constant spacing as they pick up and discharge passengers and encounter random pockets of congestion.

Here's the quick analysis provided by the Quora article I mentioned at the top:

Spoiler

The key in realizing this is that they are measuring different things. The municipality is measuring how often they release the bus from the first bus station, which is indeed every 15 minutes on average. However, what you are in fact measuring is not that. You are sampling the time intervals between bus arrivals.

Let's look at some numbers below, assume each vertical line is an arrival, and we are looking at one hour total.

------10 mins-----|----------------------35 mins------------------|-----10 mins-----|---5 mins--|

As you can see, if you average these numbers you will get 1 bus per 15 mins on average.

But what happens if you try to measure an interval time from this, as you arrive at a random time within the hour?  You are actually much more likely to arrive in the longer interval (35 mins) than in the shortest one (5 mins). If you average the interval size this way you will get ~25 mins. I.e. it is 7 times more likely that you sample the 35 minute interval than the 5 minute one.

The idea is similar to BMAD's puzzles about random arcs on a circle enclosing a particular point.
The arcs correspond to interval times and the point corresponds to the sampling process.
E[T]=ttp(t)=10260+35260+10260+526025

  • Upvote 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...