Two ships must arrive at the same berth. The arrival times…
Two ships must arrive at the same berth. The arrival times of both ships are independent and equally likely at any moment of the day (24 hours). Find the probability that one of the ships will have to wait for the berth to become free, if the first ship stays at the berth for one hour and the second for two hours.
Explanation of Method
Let $x$ and $y$ be the arrival times (in hours) of the first and second ship; $(x,y)$ is uniform in the square $[0,24]^2$. If the first ship arrives first, the second must wait when it arrives less than $1$ hour later; if the second arrives first, the first must wait when it arrives less than $2$ hours later. The waiting region is a band around the diagonal, of different widths on the two sides. We subtract the two corner triangles where nobody waits.
Step 1: The model
Arrival times $x$ (first ship) and $y$ (second ship) are independent and uniform on $[0,24]$: $(x,y)$ is uniform in a square of area $24^2=576$.
Step 2: When does a ship wait?
- First ship arrives first ($x\le y$): it occupies the berth until $x+1$. The second waits if $y\lt x+1$, i.e. $0\le y-x\lt1$.
- Second ship arrives first ($y\le x$): it occupies the berth until $y+2$. The first waits if $x\lt y+2$, i.e. $0\le x-y\lt2$.
Waiting region: $-2\lt y-x\lt1$.
- one ship waits: $-2\lt y-x\lt1$
Step 3: Nobody waits
$y-x\ge1$: a triangle with legs $24-1=23$, area $\frac12\cdot23^2 = 264.5$.
$x-y\ge2$: a triangle with legs $24-2=22$, area $\frac12\cdot22^2 = 242$.
Step 4: The probability
\[ \boxed{P(\text{waiting}) = 1-\frac{\frac12(23^2+22^2)}{24^2} = 1-\frac{1013}{1152} = \frac{139}{1152}\approx0.121.} \]
Step 5: General formula
For a period of length $T$ and berth times $t_1$ (first ship) and $t_2$ (second ship):
\[ P = 1-\frac{(T-t_1)^2+(T-t_2)^2}{2T^2}. \]
With $t_1=t_2=t$ this becomes $1-(1-\frac tT)^2$, the meeting formula of Problem 87.
Result
| Answer | |
|---|---|
| Waiting region | $-2\lt y-x\lt1$ in $[0,24]^2$ |
| Probability | $P=139/1152\approx0.121$ |