Re: Coins , dice, cards and random numbers
- From: "\"Luis A. Afonso\"" <licas_@xxxxxxxxxxx>
- Date: Fri, 26 Aug 2005 11:38:38 EDT
Two dice, A and B, are throwing. What is the probability that the total score be at most 5 if B scored 2, 3 or 4?
_________(1)__(2)__(3)__(4)__(5)__(6)
_(1)_______2___3___4___5___6____7
*****
_(2)_______3*__4*__5*__6___7____8
_(3)_______4*__5*__6___7___8____9
_(4)_______5*__6___7___8___9___10
*****
_(5)_______6___7___8___9__10___11
_(6)_______7___8___9__10__11___12
__die A scores line 1, die B left column.
Explanation: among the 36 (6 times 6) outcomes they are only considered those to which B scores 2, 3 or 4. They are 3*6=18 cases equally likely. Among these there are (stared) 5 that are favorable. Then the probability is 3/18 = 1/3 = 0.33333…
It can be seen that CONDITIONAL probability assumes that the UNIVERSE (the set of equally likely outcomes) is reduced by the IF CONDITION. (That can be said IN THE CASE THAT, or KNOWING THAT, or other equivalent expression ;;;).
Note carefully that the scores are INDEPENDENT, the dependence arrives because we do not care the outputs others than B scores 2, 3, or 4.
However if the problem was drawing two cards successively WITHOUT replacement, the probability to draw the second card IS NOT independent of the first outcome.
_*__What is the probability p to have a Spade card after a Kung?
First card
_____p(first) = 13/52 = 1/4
Second one: two mutually exclusive cases:
_______a)_______King of spades
________p(2nd , a)) = 12/51
_______b)_______no spades (i.e. no King of spades)
________p(2nd, b)) = 13 /51
Then p= 13/52 * (12/51 + 13/51) = 0.1225.
________Simulation
__REM “IF”
__CLS
__RANDOMIZE TIMER
__all= 400000
__FOR k=1 to all
__LOCATE 10,10
__PRINT USING “#######”; all-k
__f=k/10000 : ff=INT(f)
__IF f=ff THEN RANDOMIZE TIMER
10__x= INT (RND*6) +1
____y= INT (RND*6) +1
__IF y=1 OR y=5 OR y=6 THEN GOTO 10
__valid = valid + 1
__s= x + y
__IF s<= 5 THEN ok = ok + 1
__PRINT USONG “#.####”; ok / valid
__NEXT k
__END
We run this program TWO TIMES (400000 hands each, see program above).
The first one gave 0.3322 . We must ask: Is this result acceptable?. Calculating Z = -1.521, we cannot state that this frequency is statistically different from 1/3.
The second simulation, the frequency obtained 0.3342.
___________licas
.
- References:
- Coins , dice, cards and random numbers
- From: \"Luis A. Afonso\"
- Coins , dice, cards and random numbers
- Prev by Date: Re: Software suggestions
- Next by Date: Re: We can make stats say whatever we want
- Previous by thread: Re: Coins , dice, cards and random numbers
- Next by thread: Number clustering (ranges)
- Index(es):
Relevant Pages
|