0%

Problem 610


Problem 610


Roman Numerals II

A random generator produces a sequence of symbols drawn from the set {I, V, X, L, C, D, M, #}. Each item in the sequence is determined by selecting one of these symbols at random, independently of the other items in the sequence. At each step, the seven letters are equally likely to be selected, with probability 14% each, but the # symbol only has a 2% chance of selection.

We write down the sequence of letters from left to right as they are generated, and we stop at the first occurrence of the # symbol (without writing it). However, we stipulate that what we have written down must always (when non-empty) be a valid Roman numeral representation in minimal form. If appending the next letter would contravene this then we simply skip it and try again with the next symbol generated.

Please take careful note of About… Roman Numerals for the definitive rules for this problem on what constitutes a “valid Roman numeral representation” and “minimal form”. For example, the (only) sequence that represents 49 is XLIX. The subtractive combination IL is invalid because of rule (ii), while XXXXIX is valid but not minimal. The rules do not place any restriction on the number of occurrences of M, so all integers have a valid representation. These are the same rules as were used in Problem 89, and members are invited to solve that problem first.

Find the expected value of the number represented by what we have written down when we stop. (If nothing is written down then count that as zero.) Give your answer rounded to 8 places after the decimal point.


罗马数字II

一个随机生成器从集合{I, V, X, L, C, D, M, #}中生成一个符号序列。序列中的每个符号都是独立于其它符号随机选出的,在每一步中,七个字母都以14%的等概率被选中,而#号则只有2%的概率被选中。

我们将生成的符号从左到右地写成序列,直到我们首次碰到#号出现(但并不写下)。此外,我们还要求写下的字母序列构成一个合法的最简形式罗马数字表示(除非是空序列)。如果写下下一个字母将会违反规则,我们就跳过它,并尝试下一个生成的符号。

请仔细阅读关于罗马数字以了解本题中所提及的“合法罗马数字表示”和“最简形式”。例如,表示49的(唯一)合法序列是XLIX。减法组合IL是不合法的,因为它违反了规则(ii),而XXXXIX是合法的但不是最简形式。规则中并未限制字母M的出现次数,所以所有整数都有一个合法的表示。这些规则同样被用在第89题中,欢迎各位先去解决那道更早的问题。

找出当我们停止时所表示的数的期望值。(当什么都没写下时视为0。)将答案四舍五入至小数点后8位。