📚 Mathematical Expectation in IB Mathematics: Definition and Calculation | IB数学:数学期望的定义与计算
Mathematical expectation, also known as the expected value, is one of the most fundamental concepts in probability theory and statistics. In the IB Mathematics curriculum—whether you are studying Analysis and Approaches (AA) or Applications and Interpretation (AI)—understanding expected value is essential for solving problems involving games of chance, decision-making models, and statistical inference. This article provides a comprehensive yet accessible guide to the definition and calculation of mathematical expectation, complete with worked examples and common pitfalls to avoid.
数学期望,又称期望值,是概率论与统计学中最基本的概念之一。在IB数学课程中——无论你学习的是分析与方法(AA)还是应用与解释(AI)——理解期望值对于解决涉及机会游戏、决策模型和统计推断的问题都至关重要。本文将提供关于数学期望定义与计算的全面且易于理解的指南,包括完整的例题和需要避免的常见陷阱。
1. What Is Mathematical Expectation? | 什么是数学期望?
Mathematical expectation is a measure of the “center” of a random variable’s distribution. It represents the long-run average value of a random experiment if it were repeated an infinite number of times. In simpler terms, it answers the question: “If I perform this experiment many times, what is the average outcome I should expect?”
数学期望是对随机变量分布“中心”的一种度量。它表示如果一个随机实验被无限次重复,所得到的长期平均值。简单来说,它回答了这样一个问题:“如果我多次进行这个实验,我应该预期的平均结果是什么?”
For a discrete random variable X with possible values x₁, x₂, …, xₙ and corresponding probabilities p₁, p₂, …, pₙ, the expected value is defined as:
对于具有可能取值 x₁, x₂, …, xₙ 及对应概率 p₁, p₂, …, pₙ 的离散随机变量 X,期望值的定义为:
E(X) = x₁p₁ + x₂p₂ + … + xₙpₙ = Σ xᵢpᵢ
This formula is a weighted average: each value xᵢ is weighted by its probability pᵢ. Note that the sum of all probabilities must equal 1 (Σpᵢ = 1), which ensures that the expected value is a meaningful average.
这个公式是一个加权平均值:每个值 xᵢ 以其概率 pᵢ 为权重。请注意,所有概率之和必须等于1(Σpᵢ = 1),这确保了期望值是一个有意义的平均值。
2. Intuitive Understanding: A Simple Game | 直观理解:一个简单的游戏
Consider a simple game: you roll a fair six-sided die. If it lands on 1, you win $10; if it lands on any other number, you win nothing. What is your expected winnings? The random variable X takes value 10 with probability 1/6 and value 0 with probability 5/6. Therefore:
考虑一个简单游戏:你掷一枚公平的六面骰子。如果掷出1,你赢得10美元;如果掷出任何其他数字,你什么也得不到。你的期望赢钱数是多少?随机变量X取值10的概率为1/6,取值0的概率为5/6。因此:
E(X) = 10 × (1/6) + 0 × (5/6) = 10/6 = 5/3 ≈ $1.67
This means that if you played this game many times, you would average about $1.67 per game. It does not mean you will win $1.67 on any single play—you either win $10 or nothing—but over many repetitions, the average converges to this value.
这意味着如果你多次玩这个游戏,每局平均能赢得约1.67美元。这并不意味着你在单次游戏中会赢1.67美元——你要么赢10美元,要么一无所获——但在多次重复后,平均值会收敛到这个数值。
3. Calculating Expectation from a Probability Table | 从概率表计算期望
In IB Mathematics, you will frequently be given a probability distribution table and asked to calculate the expected value. The process is straightforward: multiply each value by its corresponding probability, then sum the results.
在IB数学中,你经常会看到给定一个概率分布表并要求计算期望值的题目。过程很直接:将每个值乘以对应的概率,然后将结果相加。
Example 1: The probability distribution of a discrete random variable X is given below:
例1:离散随机变量X的概率分布如下:
| x | 1 | 2 | 3 | 4 |
| P(X = x) | 0.2 | 0.3 | 0.4 | 0.1 |
Calculate E(X).
计算 E(X)。
Solution: Multiply each value by its probability and sum:
解答:将每个值乘以其概率然后求和:
E(X) = 1(0.2) + 2(0.3) + 3(0.4) + 4(0.1) = 0.2 + 0.6 + 1.2 + 0.4 = 2.4
Always check that the probabilities sum to 1 before proceeding. In this case, 0.2 + 0.3 + 0.4 + 0.1 = 1.0, so the table is valid.
在计算之前务必检查概率之和是否等于1。本例中,0.2 + 0.3 + 0.4 + 0.1 = 1.0,因此该表是有效的。
4. Expectation of a Function of X | X的函数的期望
Sometimes you need to find E(g(X)), where g is some function applied to X. The formula is:
有时你需要求 E(g(X)),其中 g 是应用于 X 的某个函数。公式为:
E(g(X)) = Σ g(xᵢ) · pᵢ
This is a common source of error: students sometimes try to compute E(X²) as [E(X)]², which is not generally true. The correct method is to apply the function to each value first, then take the weighted average.
这是一个常见的错误来源:学生有时试图将 E(X²) 计算为 [E(X)]²,这通常是不成立的。正确的方法是先将函数应用于每个值,然后取加权平均值。
Example 2: Using the distribution from Example 1, find E(X²).
例2:使用例1中的分布,求 E(X²)。
Solution: Apply the square to each value first:
解答:先将平方应用于每个值:
E(X²) = 1²(0.2) + 2²(0.3) + 3²(0.4) + 4²(0.1) = 0.2 + 1.2 + 3.6 + 1.6 = 6.6
Note that [E(X)]² = (2.4)² = 5.76 ≠ 6.6. This distinction is critical, especially when calculating variance.
注意 [E(X)]² = (2.4)² = 5.76 ≠ 6.6。这个区别至关重要,尤其是在计算方差时。
5. Properties of Expectation | 期望的性质
Several properties of expectation greatly simplify calculations. These properties are frequently tested in IB exams:
期望的几个性质可以极大地简化计算。这些性质在IB考试中经常被考查:
Property 1: E(c) = c, where c is a constant. The expected value of a constant is the constant itself.
性质1: E(c) = c,其中 c 是常数。常数的期望值就是该常数本身。
Property 2: E(aX + b) = aE(X) + b, where a and b are constants. This is known as linearity of expectation with respect to constants.
性质2: E(aX + b) = aE(X) + b,其中 a 和 b 是常数。这被称为期望关于常数的线性性。
Property 3: E(X + Y) = E(X) + E(Y), for any two random variables X and Y (whether or not they are independent). This is a powerful result because it requires no conditions on the relationship between X and Y.
性质3: 对于任意两个随机变量X和Y,都有 E(X + Y) = E(X) + E(Y)(无论它们是否独立)。这是一个强大的结果,因为它对X和Y之间的关系没有任何条件要求。
Property 4: E(XY) = E(X)E(Y) only if X and Y are independent. Without independence, this equality does not necessarily hold.
性质4: 只有当X和Y独立时,才有 E(XY) = E(X)E(Y)。如果没有独立性,这个等式不一定成立。
6. Expectation of Linear Combinations | 线性组合的期望
In IB Mathematics, you will often encounter problems involving linear combinations of independent random variables. For example, if X and Y are independent random variables, then:
在IB数学中,你经常会遇到涉及独立随机变量线性组合的问题。例如,如果X和Y是独立随机变量,那么:
E(aX + bY) = aE(X) + bE(Y)
This formula follows directly from Properties 2 and 3. It is worth noting that this holds for any number of variables, not just two.
这个公式直接从性质2和性质3得出。值得注意的是,这对任意数量的变量都成立,而不仅仅是两个。
Example 3: The random variable X has E(X) = 5 and the random variable Y has E(Y) = 3. If X and Y are independent, find E(2X – Y + 4).
例3: 随机变量X有 E(X) = 5,随机变量Y有 E(Y) = 3。如果X和Y独立,求 E(2X – Y + 4)。
Solution:
解答:
E(2X – Y + 4) = 2E(X) – E(Y) + 4 = 2(5) – 3 + 4 = 10 – 3 + 4 = 11
Notice that the constant 4 is added directly, and the constants outside X and Y (2 and -1) multiply their respective expectations.
注意常数4被直接加上,而X和Y外面的常数(2和-1)分别乘以其期望值。
7. Expectation for the Binomial Distribution | 二项分布的期望
One of the most important applications of expectation in IB Mathematics is the binomial distribution. If X ~ B(n, p), meaning X counts the number of successes in n independent trials, each with success probability p, then:
期望在IB数学中最重要应用之一是二项分布。如果 X ~ B(n, p),意味着X是在n次独立试验中成功的次数,每次试验的成功概率为p,那么:
E(X) = np
This elegant result is derived from the fact that a binomial random variable can be viewed as the sum of n independent Bernoulli random variables, each of which has expectation p.
这个简洁的结果源于这样一个事实:二项随机变量可以看作n个独立伯努利随机变量之和,每个伯努利变量的期望为p。
Example 4: A factory produces light bulbs with a 2% defect rate. If a quality inspector randomly selects 500 bulbs, what is the expected number of defective bulbs?
例4: 一家工厂生产的灯泡有2%的次品率。如果质量检验员随机抽取500个灯泡,预期次品数量是多少?
Solution: Let X = number of defective bulbs. Then X ~ B(500, 0.02), and E(X) = 500 × 0.02 = 10 bulbs.
解答:设X = 次品灯泡的数量。则 X ~ B(500, 0.02),E(X) = 500 × 0.02 = 10个灯泡。
This does not mean exactly 10 bulbs will always be defective; rather, over many batches of 500 bulbs, the average number of defects will approach 10.
这并不意味着每批恰好有10个次品;而是在多批500个灯泡中,次品数量的平均值将趋近于10。
8. Expectation in Game Fairness Problems | 游戏公平性中的期望
A classic IB exam question involves determining whether a game is “fair.” A game is considered fair if the expected net gain is zero. If the expected net gain is positive, the game favors the player; if negative, it favors the house.
一个经典的IB考试题目涉及判断游戏是否“公平”。如果期望净收益为零,则该游戏被认为是公平的。如果期望净收益为正,游戏有利于玩家;如果为负,则有利于庄家。
Example 5: In a carnival game, you pay $5 to play. You draw a card from a standard deck of 52 cards (no jokers). If you draw an ace, you win $20. If you draw a heart that is not an ace, you win $10. Otherwise, you win nothing. Is this game fair?
例5: 在一个嘉年华游戏中,你支付5美元来玩游戏。你从一副标准的52张牌(无王牌)中抽一张牌。如果抽到A,你赢20美元。如果抽到一张非A的红心牌,你赢10美元。否则,你什么都赢不到。这个游戏公平吗?
Solution: First, note that the payout is the gross winnings. The net gain is payout minus the $5 cost. Let X be the net gain.
解答:首先注意,奖金是总赢款。净收益等于奖金减去5美元成本。设X为净收益。
There are 4 aces in the deck: P(ace) = 4/52 = 1/13, payout = $20, so net gain = 20 – 5 = $15.
牌堆中有4张A:P(A) = 4/52 = 1/13,奖金为20美元,所以净收益 = 20 – 5 = 15美元。
There are 13 hearts in total, and one of them is the ace of hearts (already counted). So there are 13 – 1 = 12 non-ace hearts: P(non-ace heart) = 12/52 = 3/13, payout = $10, so net gain = 10 – 5 = $5.
红心牌共有13张,其中一张是红心A(已被计算)。所以非A红心牌有13 – 1 = 12张:P(非A红心) = 12/52 = 3/13,奖金为10美元,所以净收益 = 10 – 5 = 5美元。
For all other cards: number of such cards = 52 – 4 – 12 = 36, P(other) = 36/52 = 9/13, payout = $0, so net gain = 0 – 5 = -$5.
对于所有其他牌:数量 = 52 – 4 – 12 = 36,P(其他) = 36/52 = 9/13,奖金为0美元,所以净收益 = 0 – 5 = -5美元。
Now compute the expected net gain:
现在计算期望净收益:
E(X) = 15 × (1/13) + 5 × (3/13) + (-5) × (9/13) = (15 + 15 – 45)/13 = -15/13 ≈ -$1.15
Since E(X) ≈ -$1.15, the expected net gain is negative, meaning the player loses about $1.15 per game on average. The game is not fair; it favors the house.
由于 E(X) ≈ -1.15美元,期望净收益为负,意味着玩家平均每局损失约1.15美元。该游戏不公平;它有利于庄家。
9. Common Mistakes and How to Avoid Them | 常见错误及避免方法
Through years of teaching IB Mathematics, several recurring errors have been observed when students calculate expected values. Here are the most important ones to watch out for:
通过多年的IB数学教学经验,观察到学生在计算期望值时会出现几个反复出现的错误。以下是需要注意的最重要的几点:
- Forgetting to multiply by the probability: Every value must be weighted by its probability. A common mistake is to simply average the values without considering their probabilities.
- 错误一:忘记乘以概率:每个值都必须以其概率为权重。一个常见错误是直接对值取平均而不考虑它们的概率。
- Confusing E(X²) with [E(X)]²: These are different unless X is constant. Always apply the function to the values first, then take the weighted average.
- 错误二:混淆 E(X²) 与 [E(X)]²:除非X是常数,否则这两个是不同的。务必先将函数应用于值,再取加权平均值。
- Not checking that probabilities sum to 1: Before doing any calculation, verify that Σpᵢ = 1. If not, the distribution is not valid.
- 错误三:不检查概率之和是否为1:在进行任何计算之前,请验证 Σpᵢ = 1。如果不是,该分布无效。
- Sign errors with negative values: When X can take negative values (as in net gain problems), be careful to include the negative sign in the multiplication.
- 错误四:负值的符号错误:当X可以取负值时(如在净收益问题中),小心在乘法中包含负号。
- Applying E(XY) = E(X)E(Y) without independence: This property only holds when X and Y are independent. Without this condition, it cannot be assumed.
- 错误五:在X和Y不独立时应用 E(XY) = E(X)E(Y):这个性质仅在X和Y独立时成立。在没有这个条件时,不能假设成立。
10. Practice Problems | 练习题
Test your understanding with these carefully selected problems. Solutions are provided for the first two, with the remaining left for you to try.
用这些精选题目来测试你的理解。前两题提供解答,其余留给你自己尝试。
Problem 1: A discrete random variable X has the following probability distribution:
题1:离散随机变量X具有如下概率分布:
| x | 0 | 1 | 2 | 3 |
| P(X = x) | 0.1 | 0.3 | 0.4 | 0.2 |
Find E(X) and E(X²).
求 E(X) 和 E(X²)。
Solution: E(X) = 0(0.1) + 1(0.3) + 2(0.4) + 3(0.2) = 0 + 0.3 + 0.8 + 0.6 = 1.7.
解答:E(X) = 0(0.1) + 1(0.3) + 2(0.4) + 3(0.2) = 0 + 0.3 + 0.8 + 0.6 = 1.7。
E(X²) = 0²(0.1) + 1²(0.3) + 2²(0.4) + 3²(0.2) = 0 + 0.3 + 1.6 + 1.8 = 3.7.
E(X²) = 0²(0.1) + 1²(0.3) + 2²(0.4) + 3²(0.2) = 0 + 0.3 + 1.6 + 1.8 = 3.7。
Problem 2: X ~ B(20, 0.3). Find E(X).
题2: X ~ B(20, 0.3)。求 E(X)。
Solution: E(X) = np = 20 × 0.3 = 6.
解答:E(X) = np = 20 × 0.3 = 6。
Problem 3: In a raffle, 1000 tickets are sold for $2 each. There is one prize of $500, two prizes of $100, and five prizes of $50. What is the expected net gain for a person buying one ticket?
题3:在一个抽奖活动中,1000张彩票每张售价2美元。有1个500美元的奖项、2个100美元的奖项和5个50美元的奖项。购买一张彩票的人的期望净收益是多少?
Problem 4: The random variable X has E(X) = 4 and E(X²) = 20. Find E(3X – 2) and E(X² + 2X + 1).
题4:随机变量X满足 E(X) = 4 且 E(X²) = 20。求 E(3X – 2) 和 E(X² + 2X + 1)。
Problem 5: A game costs $3 to play. You flip a fair coin three times. If you get three heads, you win $10; if you get exactly two heads, you win $4; otherwise you win nothing. Determine whether the game is fair.
题5:一个游戏需要3美元才能玩。你掷一枚公平硬币三次。如果得到三个正面,你赢10美元;如果恰好得到两个正面,你赢4美元;否则什么都赢不到。判断这个游戏是否公平。
11. Expected Value and Variance Link | 期望与方差的联系
The expected value plays a central role in the definition of variance. The variance of a random variable X is defined as:
期望值在方差的定义中起着核心作用。随机变量X的方差定义为:
Var(X) = E(X²) – [E(X)]²
This “shortcut formula” for variance is widely used in IB Mathematics. It requires you to compute both E(X) and E(X²), which demonstrates why mastering the calculation of expectation is so important. From this, the standard deviation is simply σ = √Var(X).
这种方差的“简化公式”在IB数学中被广泛使用。它要求你同时计算E(X)和E(X²),这说明了为什么掌握期望的计算如此重要。由此,标准差就是 σ = √Var(X)。
Example 6: From Example 1, compute the variance and standard deviation of X.
例6:根据例1,计算X的方差和标准差。
Solution: We have E(X) = 2.4 and E(X²) = 6.6. Therefore:
解答:已知 E(X) = 2.4 且 E(X²) = 6.6。因此:
Var(X) = 6.6 – (2.4)² = 6.6 – 5.76 = 0.84
σ = √0.84 ≈ 0.9165
This shows how expectation calculations feed directly into other statistical measures.
这展示了期望计算如何直接关联到其他统计量。
12. Summary and Key Takeaways | 总结与关键要点
Mathematical expectation is a cornerstone of probability and statistics in IB Mathematics. Here are the key points to remember:
数学期望是IB数学中概率与统计的基石。以下是需要记住的关键要点:
- E(X) = Σ xᵢpᵢ for a discrete random variable X — it is a probability-weighted average.
- E(X) = Σ xᵢpᵢ 为离散随机变量X的期望 —— 它是一个概率加权平均值。
- To calculate E(g(X)), apply the function g to each value first, then multiply by probabilities and sum.
- 要计算 E(g(X)),先将函数g应用于每个值,然后乘以概率并求和。
- Linearity holds: E(aX + bY + c) = aE(X) + bE(Y) + c for constants a, b, c.
- 线性性成立:对于常数a、b、c,有 E(aX + bY + c) = aE(X) + bE(Y) + c。
- For a binomial distribution, E(X) = np.
- 对于二项分布,E(X) = np。
- Always verify that probabilities sum to 1, and be careful with negative values and squared expectations.
- 始终验证概率之和为1,并对负值和平方期望保持谨慎。
- A game is fair when the expected net gain equals zero.
- 当期望净收益等于零时,游戏是公平的。
Understanding expectation not only helps you score well on IB exams but also builds intuition for decision-making under uncertainty—a skill that is valuable far beyond the classroom.
理解期望不仅帮助你在IB考试中取得好成绩,还能建立不确定性下决策的直觉——这是一项在课堂之外同样宝贵的技能。
Keep practicing, check your distributions carefully, and remember: the expected value is your long-run average, not a promise for any single trial. Good luck with your studies!
继续练习,仔细检查你的分布表,并记住:期望值是长期平均值,而不是对任何单次试验的承诺。祝你在学业中好运!
Published by TutorHao | Mathematics Revision Series | aleveler.com
更多咨询请联系16621398022(同微信)
屏轩国际教育cambridge primary/secondary checkpoint, cat4, ukiset,ukcat,igcse,alevel,PAT,STEP,MAT, ibdp,ap,ssat,sat,sat2课程辅导,国外大学本科硕士研究生博士课程论文辅导