← 返回资讯屏轩教育 · 行业资讯

Sample Space | 样本空间

2026-08-02 23:33 · 本文部分内容由AI辅助创作

📚 Sample Space | 样本空间

In probability theory, the foundation of any random experiment is the set of all possible outcomes. This set is called the sample space. Understanding how to define, represent and manipulate the sample space is essential for calculating probabilities, applying set theory and solving IB Mathematics examination problems. This article explores the concept of the sample space, its notation, its discrete and continuous forms, the main ways of representing it, and its role in counting principles, set operations and conditional probability.

在概率论中,任何随机试验的基础是所有可能结果构成的集合,这个集合称为样本空间。理解如何定义、表示和操作样本空间,对于计算概率、运用集合论以及解决 IB 数学考题至关重要。本文探讨样本空间的概念、表示符号、离散与连续两种形式、主要的表示方法,以及它在计数原理、集合运算和条件概率中的作用。


1. What is a Sample Space? | 什么是样本空间?

A sample space is the set of all possible outcomes of a random experiment. It is usually denoted by S or Ω. Two conditions must be satisfied: the outcomes must be distinct (no two listed outcomes are the same) and exhaustive (every possible result the experiment could produce is included). If an outcome is missing, the sample space is incomplete and every probability calculated from it will be unreliable.

样本空间是某个随机试验所有可能结果的集合,通常记作 S 或 Ω。它必须满足两个条件:结果互异(列出的结果没有两个是相同的),以及穷尽(试验可能产生的每一种结果都被包含在内)。如果遗漏了某个结果,样本空间就是不完整的,由它计算出的每一个概率都会不可靠。

For a single toss of a fair coin the sample space is S and T represents tails. For a single roll of a standard six-sided die the sample space is S = {1, 2, 3, 4, 5, 6}. For a randomly chosen letter from the English alphabet, S = {a, b, c, ..., z}, which contains 26 outcomes.

抛一枚公平硬币一次,样本空间为 S = {H, T},其中 H 代表正面,T 代表反面。掷一次标准六面骰子,样本空间为 S = {1, 2, 3, 4, 5, 6}。从英文字母表中随机抽取一个字母,则 S = {a, b, c, ..., z},共包含 26 个结果。

A key question in every probability problem is therefore: what exactly is one outcome? For the experiment "toss two coins", one outcome could be written as HH, HT, TH, TT, giving four outcomes; but if the experiment were recorded only as "number of heads", the sample space would be S ame physical process can have different sample spaces depending on what is being recorded.

因此,每个概率问题的关键问题是:一个"结果"究竟指什么?对于"抛两枚硬币"这个试验,一个结果可以写成 HH、HT、TH、TT,共 4 个结果;但如果只记录"正面出现的个数",则样本空间为 S = {0, 1, 2},只有 3 个结果。同一个物理过程,根据记录方式的不同,可以对应不同的样本空间。


2. Sample Points and Events | 样本点与事件

Each individual outcome inside the sample space is called a sample point or elementary outcome. An event is any subset of the sample space, consisting of one or more sample points. When rolling a die, the event "getting an even number" can be written as A taining a single sample point, such as {6}) or compound (containing several sample points, such as {2, 4, 6}).

样本空间中的每一个单独结果称为样本点或基本结果。事件是样本空间的任意子集,由一个或多个样本点组成。掷骰子时,"得到偶数点"这一事件可记作 A = {2, 4, 6}。事件可以是简单事件(只含一个样本点,如 {6}),也可以是复合事件(含多个样本点,如 {2, 4, 6})。

Two special events deserve attention. The empty set ∅ represents an impossible event, which contains no sample point at all. The whole sample space S very possible outcome is included in it. Therefore 0 ≤ P(A) ≤ 1 for every event A, with P(∅) = 0 and P(S) = 1.

有两个特殊事件值得关注。空集 ∅ 表示不可能事件,它不包含任何样本点。整个样本空间 S 表示必然事件,因为所有可能结果都包含在其中。因此对任意事件 A 都有 0 ≤ P(A) ≤ 1,其中 P(∅) = 0,P(S) = 1。


3. Notation: Set Theory in Probability | 集合论表示法

Probability uses set notation to describe events. The sample space S plays the role of the universal set. Outcomes ω are elements of S, written as ω ∈ S. Every event is a subset of S, written as A ⊆ S. The union A ∪ B contains all outcomes that are in A or in B (or in both); the intersection A ∩ B contains only those outcomes that are in both A and B.

概率论使用集合符号描述事件。样本空间 S 扮演全集(universal set)的角色,结果 ω 是 S 的元素,记作 ω ∈ S。每个事件都是 S 的子集,记作 A ⊆ S。并集 A ∪ B 包含属于 A 或属于 B(或同时属于两者)的所有结果;交集 A ∩ B 只包含同时属于 A 和 B 的结果。

The complement of A, written A' or Aᶜ, is the set of outcomes that are in S but not in A. Two events are mutually exclusive (disjoint) if they share no outcome, that is A ∩ B = ∅. The complement relationship always satisfies P(A') = 1 − P(A), a fact used constantly in examination questions that ask for "at least one".

A 的补集记作 A' 或 Aᶜ,表示属于 S 但不属于 A 的结果集合。若两个事件没有共同结果,即 A ∩ B = ∅,则称它们互斥(不相容)。补集关系恒满足 P(A') = 1 − P(A),这一关系在考卷中凡涉及"至少一个"的题目里反复使用。

De Morgan's laws link complements with unions and intersections, and are extremely useful for simplifying complicated expressions:

德摩根律把补集与并集、交集联系起来,对化简复杂表达式极为有用:

(A ∪ B)′ = A′ ∩ B′    (A ∩ B)′ = A′ ∪ B′

Correct notation does more than satisfy an examiner; it forces the solver to decide precisely which outcomes belong to each event, which is the real work of most probability questions.

正确的符号不仅仅是满足考官的评分要求,它还会迫使解题者精确判断每个事件包含哪些结果,而这正是大多数概率题目的真正工作。


4. Types of Sample Spaces: Discrete and Continuous | 样本空间的类型:离散与连续

A sample space is discrete when it consists of a finite or countably infinite set of separate outcomes. Coin tosses, dice rolls, card draws and the number of defective items in a batch all give discrete sample spaces. Probabilities are then found by counting: each outcome or group of outcomes is assigned a probability, and the values can be listed in a probability distribution table.

当样本空间由有限个或可数无限个彼此分离的结果组成时,它是离散的。抛硬币、掷骰子、抽扑克牌、一批产品中的次品数等,给出的都是离散样本空间。此时概率通过计数获得:每个结果或每组结果被赋予一个概率,这些数值可以列成概率分布表。

A sample space is continuous when outcomes can take any value in an interval, so the outcomes cannot be listed one by one. Typical examples include the exact height of a randomly chosen student, the lifetime of a light bulb in hours, or the time a commuter waits for a bus. For a continuous sample space, the probability of any single exact value is zero, and probabilities correspond to intervals:

当结果可以取区间内的任意数值、无法逐一列举时,样本空间是连续的。典型例子包括随机抽取学生的精确身高、灯泡寿命的小时数、通勤者等公交车的时间。对于连续样本空间,任一单个精确数值的概率为 0,概率对应的是区间:

P(a ≤ X ≤ b) = ∫ₐᵇ f(x) dx    ∫₋∞+∞ f(x) dx = 1

Here f(x) is the probability density function, and the probability equals the area under its curve between the two limits. The distinction matters because counting arguments apply only to discrete spaces, while continuous problems are handled with density curves, uniform distributions and, in some courses, integration.

这里的 f(x) 是概率密度函数,概率等于其曲线在两限之间的面积。这一区分很重要,因为计数方法只适用于离散样本空间,而连续问题则用密度曲线、均匀分布以及(在部分课程中)积分来处理。

Feature 特征Discrete 离散Continuous 连续
Outcomes 结果Separate, countable 分离、可数Any value in an interval 区间内任意值
Method 方法Counting 计数Area / integral 面积或积分
P(single value) 单点概率Usually > 0 通常大于 0Exactly 0 恰好为 0

5. Representing the Sample Space | 样本空间的表示方法

Choosing a good representation is often the difference between a quick solution and a confused one. A simple list works for small spaces such as {H, T} or {1, 2, 3, 4, 5, 6}. A two-way table is ideal when two characteristics are recorded, for example gender against preference, since each cell then represents one intersection event.

选择好的表示方法,往往决定了解题是迅速还是混乱。对于 {H, T} 或 {1, 2, 3, 4, 5, 6} 这类较小的样本空间,简单列举即可。当同时记录两个特征时,例如性别与偏好,二维表最为理想,因为每个单元格正好代表一个交集事件。

third 2, and the diagram ends with 2 × 2 × 2 = 8 terminal branches, each an outcome such as HTH. Probabilities are written on the branches and multiplied along a path.

树形图是处理多阶段试验的标准工具。抛三次硬币时,第一次分叉有 2 个选项,第二次 2 个,第三次 2 个,图的末端共有 2 × 2 × 2 = 8 条分支,每条分支都是一个结果,例如 HTH。概率写在分支上,沿一条路径相乘。

grid gives the 36 ordered pairs (1, 1), (1, 2), ..., (6, 6). This grid makes sums such as "total = 7" finally, is used when events overlap, because it shows the intersection region explicitly.

掷两枚骰子时,用 6 × 6 的网格可以列出全部 36 个有序对 (1, 1), (1, 2), ..., (6, 6)。这个网格让"点数和为 7"这类事件一目了然,因为有利的有序对正好排在一条对角线上。最后,当事件之间存在重叠时使用维恩图,因为它能明确显示交集区域。


6. Equally Likely Outcomes and Classical Probability | 等可能结果与古典概率公式

When every sample point in a finite sample space has the same probability, the space is called equiprobable. In that case the probability of an event is simply the ratio of the number of favourable outcomes to the total number of outcomes:

当有限样本空间中的每一个样本点概率都相同时,该样本空间称为等可能的。此时事件概率就等于有利结果数与结果总数之比:

P(A) = n(A) ÷ n(S)

广告 / Sponsored

For example, when two fair dice are rolled, n(S) = 36. The event "sum is 7" nted separately: (1, 6) and (6, 1) are different outcomes even though the sum is the same.

例如掷两枚公平骰子时,n(S) = 36。"点数和为 7"的事件为 A = {(1, 6), (2, 5), (3, 4), (4, 3), (5, 2), (6, 1)},故 n(A) = 6,P(A) = 6 ÷ 36 = 1 ÷ 6 ≈ 0.167。注意有序对是分别计数的:(1, 6) 与 (6, 1) 是两个不同的结果,尽管它们的和相同。

The equiprobable assumption is a modelling assumption, not a mathematical theorem. A biased coin, a loaded die or a spinner with unequal sectors all produce a valid sample space in which the classical formula fails, and probabilities must instead be given or estimated experimentally by relative frequency.

等可能假设是一种建模假设,而不是数学定理。偏心硬币、灌铅骰子或扇形面积不相等的转盘,都能构成合法的样本空间,但古典公式在其中失效,此时概率必须由题目给出,或通过相对频率由试验估计。


7. Counting Principles: Product Rule and Permutations | 计数原理:乘法原理与排列

d in m ways and a second in n ways, the two together can be performed in m × n ways. This extends to three or more stages, and it is exactly the rule that produces 2ⁿ outcomes when a coin is tossed n times.

庞大的样本空间很少逐一列举,而是用计数方法求出大小。乘法原理指出:若一个操作有 m 种做法,第二个操作有 n 种做法,则两者合计有 m × n 种做法。该原理可推广到三个阶段或更多,这正是抛 n 次硬币产生 2ⁿ 个结果的原因。

A permutation counts arrangements in which order matters. The number of ways of arranging r objects chosen from n distinct objects is

排列计算的是次序重要的安排方式。从 n 个不同对象中选出 r 个进行排列的方法数为

ⁿPᵣ = n! ÷ (n − r)!

n = 5 and r = 3, ⁿPᵣ = 5 × 4 × 3 = 60. If all n objects are arranged, the formula gives n!, for instance 4! d selections, such as forming a three-letter code or choosing a president and a secretary.

当 n = 5、r = 3 时,ⁿPᵣ = 5 × 4 × 3 = 60。若将全部 n 个对象排列,公式给出 n!,例如 4! = 4 × 3 × 2 × 1 = 24,即四人排成一排的坐法数。当样本空间由有序选取构成时使用排列,例如组成三位字母编码,或选出主席与秘书。

epetitions are allowed, the count changes: with n choices at each of r stages, there are nʳ therefore has a sample space of 10⁴ = 10 000 outcomes, provided leading zeros are allowed.

若允许重复,计数方式随之改变:若 r 个阶段各有 n 种选择,则共有 nʳ 个结果。因此由数字 0 到 9 组成的四位密码,其样本空间大小是 10⁴ = 10 000(前提是允许首位为 0)。


8. Combinations and Subsets | 组合与子集

A combination counts selections in which order does not matter, such as choosing a committee or a hand of cards. The number of ways of choosing r objects from n distinct objects is

组合计算的是次序无关的选取方式,例如挑选委员会成员或一手牌。从 n 个不同对象中选出 r 个的方法数为

ⁿCᵣ = n! ÷ (r! (n − r)!)

For example, ⁸C₃ = 8! ÷ (3! × 5! tee is equally likely. Any selection problem should first be classified: does order matter? If yes, use permutations; if no, use combinations.

例如 ⁸C₃ = 8! ÷ (3! × 5!) = 56,因此从 8 位候选人中选出 3 人组成委员会,若每个委员会等可能,则样本空间含 56 个结果。任何选取问题都应先分类:次序是否重要?若重要,用排列;若不重要,用组合。

at way of counting events: if a sample space has 4 elements, it has 2⁴ = 16 possible events, including ∅ and the whole space.

组合同时也用于计算集合的子集个数。含 n 个元素的集合恰有 2ⁿ 个子集,因为每个元素只有"被包含"或"不被包含"两种状态。这提供了一种简洁的事件计数方法:若样本空间有 4 个元素,则共有 2⁴ = 16 个可能事件,其中包括 ∅ 与全集本身。


9. Set Operations and the Addition Rule | 集合运算与加法法则

Once events are expressed as sets, probabilities of combined events follow the addition rule. For any two events A and B,

一旦把事件表示成集合,组合事件的概率就可由加法法则得到。对任意两个事件 A 与 B,有

P(A ∪ B) = P(A) + P(B) − P(A ∩ B)

tersection are counted twice if we simply add. If A and B are mutually exclusive, then P(A ∩ B) = 0 and the rule simplifies to P(A ∪ + P(B). For three events the inclusion-exclusion pattern continues with alternating signs.

减号不可或缺,因为若只是简单相加,交集中的结果会被重复计算两次。若 A 与 B 互斥,则 P(A ∩ B) = 0,法则简化为 P(A ∪ B) = P(A) + P(B)。对于三个事件,容斥规律继续以正负交替的形式延伸。

15 − 8 = 25, so the probability that a randomly chosen student studies at least one is 25 ÷ 30 = 5 ÷ 6. The complement, studying neither, has probability 1 − 5 ÷ 6 = 1 ÷ 6.

一个经典例子:某班 30 名学生中,18 人选修法语,15 人选修西班牙语,8 人两门都选。至少选修一门语言的人数为 18 + 15 − 8 = 25,因此随机抽取一名学生至少选修一门的概率为 25 ÷ 30 = 5 ÷ 6。其补集即两门都不选的学生的概率为 1 − 5 ÷ 6 = 1 ÷ 6。


10. Conditional Probability and Independence | 条件概率与独立性

Conditional probability asks how the knowledge of one event changes the probability of another. Given that B has occurred, the sample space effectively shrinks from S to B, and

条件概率研究的是:已知一个事件发生,会如何改变另一个事件的概率。在已知 B 发生的条件下,样本空间实际上从 S 缩小为 B,于是

P(A | B) = P(A ∩ B) ÷ P(B),   P(B) > 0

Rearranging gives the multiplication rule P(A ∩ B) = P(B) × P(A | Two events are independent if the occurrence of one does not affect the other, that is P(A | B) = P(A), which is equivalent to

移项即得乘法法则 P(A ∩ B) = P(B) × P(A | B),这正是树形图逐阶段计算的内容。若一个事件的发生不影响另一个事件,则称两事件相互独立,即 P(A | B) = P(A),这等价于

P(A ∩ B) = P(A) × P(B)

Distinguish clearly between mutually exclusive and independent: mutually exclusive events cannot happen together, so for non-empty events they are actually dependent, since knowing one occurred rules the other out. This confusion is one of the most common sources of lost marks.

要清楚区分互斥与独立:互斥事件不可能同时发生,因此对于非空事件而言它们实际上是相关的,因为已知其一发生就排除了另一个。这一混淆是最常见的失分原因之一。


11. Common Mistakes and Exam Tips | 常见错误与考试技巧

Most errors in sample space questions come from four sources. First, an incomplete sample space: forgetting that a coin tossed twice produces four outcomes, not three. Second, inconsistent counting, mixing ordered pairs with unordered selections in the same question. Third, double counting in the addition rule by ignoring the intersection. Fourth, confusing "with replacement" and "without replacement", which changes whether the denominator stays constant on the second stage.

样本空间题目中的错误大多来自四个方面。第一,样本空间不完整:忘记抛两次硬币产生 4 个结果而非 3 个。第二,计数方式不一致:在同一题中混用有序对与无序选取。第三,在加法法则中忽略交集导致重复计数。第四,混淆"有放回"与"无放回",这决定了第二阶段的分母是否保持不变。

A reliable routine helps. State the sample space explicitly, even briefly; decide whether outcomes are ordered and equally likely; count n(S) with a counting principle rather than listing when the space is large; then count n(A). If a question says "at least one", compute the complement and subtract from 1, since this is almost always faster and less error-prone.

一套可靠的解题流程很有帮助:明确写出样本空间(即使很简短);判断结果是否有序、是否等可能;当空间较大时用计数原理而非列举求 n(S);再求 n(A)。如果题目出现"至少一个",则计算其补集并用 1 相减,这几乎总是更快且更不易出错。


12. Worked Example and Summary | 例题与总结

R, RB, BR and BB. The total number of ordered pairs is 8 × 7 = 56. The number of ways of drawing one red and one blue is 5 × 3 + 3 × 5 = 30, so P(one of each colour) = 30 ÷ 56 = 15 ÷ 28.

考虑一个装有 5 个红球和 3 个蓝球的袋子,不放回地取出两个球。样本空间由有序抽取 RR、RB、BR、BB 组成。有序对总数为 8 × 7 = 56。取到一个红球和一个蓝球的方式数为 5 × 3 + 3 × 5 = 30,故 P

广告 / Sponsored
英文原版 The Cambridge Companion to the Beatles 剑桥披头士乐队研究指南 剑桥音…
音乐 备考教辅 · 正版现货 · 学习备考通用
查看详情 / View on Taobao
广告 / Sponsored
英国原版CGP教辅 New Edexcel International GCSE Chemistry Practice…
化学 备考教辅 · 正版现货 · 学习备考通用
查看详情 / View on Taobao

更多咨询请联系16621398022(同微信)

备考资讯每日更新,关注不错过
考纲变化 · 科目分析 · 学习方法
扫码关注公众号 tutorhao
在微信里长按二维码识别关注
或截图后用「扫一扫 → 相册」选择本图
公众号:tutorhao