Extended Monty Hall Problem This is not a duplicate of Extended Monty Hall Problem.
Let the Extended Monty Hall problem. i.e., it is a game where there is $n$ doors and a car behind one, and only one, door. After the player chooses one door, $k$ doors are revealed (excluding the winning and the player's chosen door), where $0 \leq k \leq n-2$ (the host must leave at least one door).
I am trying to get a very formal argument to find that the probability of switching doors after $k$ doors are open is
$$P(win | switch) = \frac{n-1}{n} \cdot \frac{1}{n-k-1}$$
For this, I'm doing the following:
Define the events $E_i = $ the car is behind door $i$, $i = 1, \ldots, n$.
We can suppose w.l.o.g. that the player initially chooses door $1$, the opened doors are $2, \ldots, k+1$ and, if the player chooses, it chooses to switch, they switch to door $k+2$.
So, the probability of winning given that the player switched doors and that we know the car is not behind doors $2, \ldots k$ is:
$$P(E_{k+2} | E_1^c \cap E_2^c \cap \ldots \cap E_{k+1}^c).$$
Using the definition of conditional probability:
$$P(E_{k+2} | E_1^c \cap E_2^c \cap \ldots \cap E_{k+1}^c) = \frac{P(E_{k+2} \cap E_1^c \cap E_2^c \cap \ldots \cap E_{k+1}^c)}{P(E_1^c \cap E_2^c \cap \ldots \cap E_{k+1}^c)} $$
Since $E_{k+2} \subset E_i^c$ if $i \neq k+2$, we then have
$$\frac{P(E_{k+2} \cap E_1^c \cap E_2^c \cap \ldots E_{k+1}^c)}{{P(E_1^c \cap E_2^c \cap \ldots \cap E_{k+1}^c)}} = \frac{P(E_{k+2})}{P\left(\left(E_1 \cup E_2 \cup \ldots \cup E_{k+1}\right)^c\right)} = \frac{P(E_{k+2})}{1 - P\left(E_1 \cup E_2 \cup \ldots \cup E_{k+1}\right)} = \frac{1/n}{1-k/n} = \frac{n - k}{n}.$$
And this is clearly wrong. What am I missing?
 A: Note that
$$ \frac{1/n}{1-k/n} = \frac{1}{n-k} \neq \frac{n - k}{n}. $$
The reason the calculation comes out to $1/(n - k)$ is that you have used only the information that the car is not behind any of the $k$ opened doors,
not the information that the contestant originally chose door $1$
or the fact that Monty is forbidden to open either the contestant's chosen door or the door with the car.
So basically you have changed the problem into one where you walk into the room when the $k$ doors are already open, and you know only that there is a car behind a door, not what happened before you walked in.
There are $n - k$ closed doors and you have no reason to think the car is more likely to be behind one than the other.
A: For one thing, $P(E_1 \cup E_2 \cup \cdots \cup E_{k+1}) = \frac{k+1}{n}$, not $\frac{k}{n}$.
But more importantly, you've made one of the same types of errors that comes up in the classic Monty Hall problem. We can't assume w.l.o.g. that Monty opens doors $2, \ldots, k+1$ because which doors Monty opens depends on the player's choice.
We can say without loss of generality that the player initially chooses door $1$, since before that point there's really no difference between the doors. For a subset $D \subset \{2, \ldots n\}$, define the event $M_D$ that Monty opens the doors with numbers in $D$, and no other doors. Assume that Monty chooses uniformly among the possible subsets $D$ with size $|D|=k$, and not containing the player's first choice, and not containing the door with the car. (If Monty's selection is not uniform, the player might have a better strategy knowing how Monty does choose which doors to open.) Then for any such subset $D$ with $|D|=k$
$$ P(M_D|E_1) = \frac{1}{n-1 \choose k} $$
and for any $j \in \{2,\ldots,n\} \setminus D$,
$$ P(M_D|E_j) = \frac{1}{n-2 \choose k} $$
$$ P(E_j \cap M_D) = P(E_j) P(M_D|E_j) = \frac{1}{n {n-2 \choose k}} $$
Or if $j \in D$, then $P(E_j \cap M_D) = 0$. Since $E_1^c = E_2 \cup E_3 \cup \cdots \cup E_n$,
$$ P(E_1^c \cap M_D) = \sum_{j=2}^n P(E_j \cap M_D) = \frac{n-k-1}{n {n-2 \choose k}} $$
$$ \begin{align*}
P(M_D|E_1^c) &= \frac{P(E_1^c \cap M_D)}{P(E_1^c)} = \frac{\frac{n-k-1}{n {n-2 \choose k}}}{\frac{n-1}{n}} = \frac{n-k-1}{(n-1){n-2 \choose k}} \\
P(M_D|E_1^c) &= \frac{(n-k-1)(k!)(n-k-2)!}{(n-1)(n-2)!} = \frac{k!(n-k-1)!}{(n-1)!} \\
P(M_D|E_1^c) &= \frac{1}{n-1 \choose k}
\end{align*} $$
This was done extra carefully, but the result $P(M_D|E_1) = P(M_D|E_1^c)$ makes sense: Which doors Monty opens depends on which door hides the prize, but when we combine the results over all possible $E_j$ with $j>1$, any of the combinations of $k$ doors are equally likely, just as in the case where door $1$ hides the prize.
The total probability Monty opens doors $D$ is also the same:
$$ \begin{align*}
P(M_D) &= P(E_1 \cap M_D) + P(E_1^c \cap M_D) \\
P(M_D) &= P(E_1) P(M_D|E_1) + P(E_1^c) P(M_D|E_1^c) \\
P(M_D) &= (P(E_1)+P(E_1^c)) \frac{1}{n-1 \choose k} \\
P(M_D) &= \frac{1}{n-1 \choose k}
\end{align*} $$
Finally, if Monty has opened doors $D$ and the player switches from door $1$ to any other door $j$ which is not in $D$, the probability of a win is
$$ \begin{align*}
P(E_j|M_D) &= \frac{P(E_j \cap M_D)}{P(M_D)} = \frac{\frac{1}{n {n-2 \choose k}}}{\frac{1}{n-1 \choose k}} = \frac{k!(n-2-k)!(n-1)!}{n(n-2)!k!(n-k-1)!} \\
P(E_j|M_D) &= \frac{n-1}{n(n-k-1)}
\end{align*} $$
as you expected.
(Thanks to @DavidK for correction and improvement to this answer.)
