I'm making a computer program that should play as a bot against other student's bots as ICT project at school. The game is Perudo.
In this part of the program I want to know what's the probability of my call ending up as a success if the next player doubts (Dudo) my call.
If you don't know the rules, you can follow the link above, but there's no need to, you just need to know that, for my call - say X Y - to be considered legitimate (or, for my call to make me not lose a dice, which is not good at all), the dices on the table should, altogether (call N the total number of dices), contain at least X dices with Y as the face facing upwards. Also, you should know that, I only know my dices (say they are n ) I don't know the dices of my opponents, so, when processing, there are N-n unknown dices.
The total number of possibilities for the unknown dices to be is $ 6^{N-n} $. this number then reduces to $ {C'}_{6;N-n} = (^{6+(N-n)-1} _{N-n}) $ because we don't consider the order (6,4,6,3 is the same as 3,6,6,4).
What is the number of possibilities (or events) that make my call legitimate (so they can be divided by $ {C'}_{6;N-n} $ ) to find the probability of this call? Ultimately, it should be the sum of all the events that put exactly (call $Z$ the number of 'Y' dices between my dices) $ X - Z $ 'Y' dices or more on the table, something like: $P(call X Y) = P(X-Z)+P(X-Z+1)+P(X-Z+2)+...+P(N-(n-Z))$
Please ask about any missing information you need, thank you in advance.
Say -WLOG- that $Y=1$ (face ones). Suppose that I have $k$ ones among my $n$ dice. To have at least $X>k$ ones among all $N$ dices, is the same as having at least $u=X-k$ among the unknown $m=N-n$ dices.
The probability of having at least $u$ ones in $m$ dices is (it's easier to count with order)
$$ P(E_{X} | k) =\frac{{m \choose u} 5^{m-u} +{m \choose u+1} 5^{m-u-1} + \cdots +1 }{6^m}$$