A university's faculties have 30 cars of exactly 3 types: BMW, Toyota and Mazda. University has build a new parking lot which has 30 parking slots. Each faculty member randomly arrives to the parking lot till 11:00 AM and parks his car in any available slot. What is the probability that at 11:00 AM each parking slot has different type of car next to it?(That is no BMW is next to a BMW and no Toyota is next to a Toyota and no Mazda is next to a Mazda) My attempt to solve this:
number of elements in Sample Space
= number of arrangements of 30 cars in 30 slots
= 30(Permutation)30
= 265252859812191058636308480000000
I just was not able to count my events i.e., each parking slot has different type of car next to it. What should I do?
We first count the number $N$ of admissible strings containing $10$ each of $B$, $M$, $T$. One third of these strings begins with a $B$. Such strings have one of the two forms $${\rm (a)}\quad Bw_1Bw_2\ldots Bw_{10},\qquad{\rm(b)}\quad Bw_1Bw_2\ldots Bw_{9}B\ ,$$ whereby the subwords $w_i$ are nonempty and consist of alternating $M$'s and $T$'s.
(a) Assume that $r$ subwords $w_i$ contain at least one letter $M$ (these $w_i$ can be chosen in ${10\choose r}$ ways), while the remaining $w_i$ consist of a single $T$. There are $10-r$ letters $M$ left to distribute among the $r$ chosen $w_i$, and this can be done in ${10-r+r-1\choose r-1}={9\choose r-1}$ ways. Each of these thrown in $M$'s has to be preceded by a $T$ in order to separate it from the foregoing $M$. Furthermore we need $10-r$ more letters $T$ for the remaining $w_i$. In all we now have used all the $B$'s and $M$'s, and $(10-r)+(10-r )=20-2r$ of the $T$'s, so that $2r-10$ letters $T$ remain to be distributed (this of course enforces $r\geq5$). These $T$'s can be placed at the head or the tail of a $w_i$ already containing $M$'s, hence there are $2r$ slots for these $T$. It follows that we can place the remaining $T$'s in ${2r\choose2r-10}$ ways. The total number $N_a$ of strings of type (a) is therefore given by $$N_a=\sum_{r=5}^{10}{10\choose r}{9\choose r-1}{2r\choose 2r-10}=28\,964\,128\ .$$ (b) Assume that $r$ subwords $w_i$ contain at least one letter $M$ (these $w_i$ can be chosen in ${9\choose r}$ ways), while the remaining $w_i$ consist of a single $T$. There are $10-r$ letters $M$ left to distribute among the $r$ chosen $w_i$, and this can be done in ${10-r+r-1\choose r-1}={9\choose r-1}$ ways. Each of these thrown in $M$'s has to be preceded by a $T$ in order to separate it from the foregoing $M$. Furthermore we need $9-r$ more letters $T$ for the remaining $w_i$. In all we now have used all the $B$'s and $M$'s, and $(10-r)+(9-r )=19-2r$ of the $T$'s, so that $2r-9$ letters $T$ remain to be distributed (this of course enforces $r\geq5$). These $T$'s can be placed at the head or the tail of a $w_i$ already containing $M$'s, hence there are $2r$ slots for these $T$'s. It follows that we can place the remaining $T$'s in ${2r\choose 2r-9}$ ways. The total number $N_b$ of strings of type (b) is therefore given by $$N_b=\sum_{r=5}^{9}{9\choose r}{9\choose r-1}{2r\choose 2r-9}=12\,685\,428\ .$$ In this way we obtain $$N=3(N_a+N_b)=124\,948\,668\ .$$ The probability $p$ in question therefore computes to $$p={N (10!)^3\over 30!}={800\,953\over35\,583\,312\,765}\doteq0.0000225092 \ .$$ Counting 250 workdays per year this means that we could expect one such event every 177.7 years.