Bayes Theorem : There are three identical boxes, each containing two numbered cards. The numbers in the
Question:
Bayes’ Theorem: There are three identical boxes, each containing two numbered cards. The numbers in the first box are 20 and 23. The numbers in the second box are 20 and 21, and the numbers in the third box are 20 and 22. A robot first randomly picks a box (each box has a equal chance for being chosen). Then it randomly picks a card from the chosen box (each card in the box has a equal chance for being chosen). If you are told that the number chosen is NOT 21, what is the probability that the robot chose the 3rd box?
Hasse diagram.: Let S = {2, 4, 6, 14, 28, 36}. Define a partial ordering on S as follows: a ⪯ b if a divides b (i.e. b is a multiple of a). Draw the Hasse diagram for the poset (S, ⪯).
lexicographical order.: we introduced the lexicographical order ⪯ on Z × Z: (a, b) ⪯ (c, d) if either a < c, or a = c and b ≤ d. Suppose we are interested in a sorting algorithm, but with respect to the lexicographical order on Z 2 this time. A machine compares (a, b) with (c, d) in the following way: it starts by comparing the first entries; if a < c or c < a, it concludes; if a = c, it further compares b and d and then concludes. So to sort out (1, 2) and (1, 3), the machine needs to do two operations, while to sort out (1, 2) and (3, 3), it only needs to do one operation. If three distinct pairs of integers are given, the machine starts by randomly picking one of them and compare it against the other two. If it cannot conclude, it further compares the other two pairs. What is the largest number of operations needed to sort out 3 distinct pairs of integers? (Let me remind again that comparing pairs such as (1, 2) and (1, 3) takes TWO operations.)