To elaborate on the problem, given
- deck size 'N'
- hand size / sample draw size 'n'
- success/es in deck 'S'
- card/s 'M' designating a 'Mulligan' card, that when drawn allows you to shuffle your entire hand, except the card itself, back into the deck and redraw ('n' - 1) cards from the deck.
- we keep redrawing as long as we don't have any 'S' in our hand and do have any number of 'M' in our hand (assuming we have a card we can shuffle back into the deck)
Edit: What I want to end up knowing, is the total probability of drawing 'S', given these conditions. This is a curiosity question, so I am happy with less-rigurous answers.
To give a text example, given the hands:
['F', 'F', 'M'] we would shuffle and redraw ['?', '?'] ('?' denoting any card)
if the above redraw were ['M', 'F'] we would shuffle and redraw ['?']
['M', 'S'...] we would not shuffle, as we have drawn 'S'
['M'] we cannot redraw due to not having another card to shuffle
['F', 'F', 'F'] no mulligan in hand, no redraw
Write $F(N, n, S, M)$ for the probability of success in a deck with $N$ cards, of which $S$ are success cards and $M$ are mulligan cards, you have an easy recursion as follows: $$ F(N, 0, S, M) = 0 $$ and $$ F(N, n, S, M) = \underbrace{1 - \frac{\binom{N-S}{n}}{\binom{N}{n}}}_{\text{Prob. of $S$ card}} + \underbrace{\frac{\binom{N-S}{n}}{\binom{N}{n}}\left(1-\frac{\binom{N-S-M}{n}}{\binom{N-S}{n}}\right)}_{\text{Prob. of getting an $M$ but no $S$}}\underbrace{F(N-1, n-1, S, M-1)}_{\text{Prob. of success after mulligan}}. $$
For reasonable numbers (i.e. for a realistic deck of cards), this should make it easy to compute (by computer).