本周问题:骰子和卡牌
在每轮游戏中,我们掷三个标准的六面骰子(每个面上的数字为1到6),然后将掷出的数字相加。在长时间的游戏中,总和的平均值(即期望值)是多少?
现在假设我们不是掷骰子,而是从一个编号为1到6的六张卡牌组成的牌堆中抽取三张牌。抽完一张牌后将其放回牌堆并重新洗牌,再抽下一张牌。这种情况下,总和的期望值会发生变化吗?
如果我们改为抽三张牌且不放回(因此概率不再是独立的),那么总和的平均值是多少?
(来源:New Scientist,BrainTwister #44)
原文:
On each turn of a game, we roll three standard dice with faces numbered 1 to 6 and add up the numbers shown. What is the average (mean) value of that total over a long game?
Now suppose instead of rolling dice, we draw three cards from a six-card deck where the cards are numbered 1 to 6. If we put each card back after drawing it and shuffle before drawing another card, does this change the expected value?
If we instead draw three cards without replacement (so the probabilities are no longer independent), what is the average value of the sum?
上期问题:连续和
连续数是指按顺序依次排列的数字,比如2、3、4和5。我们可以通过连续数的总和来得到某些数字,例如1 + 2 + 3 = 6 或 14 + 15 = 29。
问题1:你能将14写成两个或更多连续正数的和吗?
问题2:小于20的哪些数字无法写成这种形式?有没有规律?
答案:
我们可以写出:14 = 2 + 3 + 4 + 5。
任何奇数都可以表示为两个连续整数的和:2n + 1 = n + (n + 1)。
对于有奇数因子(如3、5、7等)的偶数,可以将其表示为对应数量连续数字的和。例如,12是4 × 3,可以写成以4为中心的三个数字的和:3 + 4 + 5。对于14,我们可以用以2为中心的七个数字来表示,但由于这七个数字中的前三个是 -1、0 和 1,它们相互抵消,最终就得到上述的和。
唯一无法用这种方式表示的数字是没有奇数因子(除了1)的数字,也就是2的幂:1、2、4、8、16等。
原文:
We can write 14 = 2 + 3 + 4 + 5.
Any odd number can be written as the sum of two consecutive numbers: 2n + 1 = n + (n + 1).
Even numbers that have an odd factor like 3, 5, 7 etc, can be written as a sum of that many terms: e.g. 12, which is 4 × 3, can be written as three numbers centred on 4: 3 + 4 + 5. In the case of 14, we use seven numbers centred on 2, but since the first three of these are -1, 0 and 1, they cancel out, leaving us with the sum above.
The only numbers that can’t be expressed this way are those without an odd factor (other than 1) – exactly the powers of 2: 1, 2, 4, 8, 16 and so on.