📚 9C Continuous random variables | 连续随机变量
In IB Mathematics, we move from discrete random variables, which take separate countable values, to continuous random variables, which can assume any value in a given interval. Instead of a probability mass function, we use a probability density function (PDF) to describe the distribution. Understanding how to integrate the PDF, to find probabilities, expected values, and variances, is crucial for both Analysis & Approaches and Applications & Interpretation courses.
在 IB 数学中,我们从取可分立的可数值的离散随机变量过渡到可取某个区间内任意值的连续随机变量。我们用概率密度函数(PDF)来描述分布,而非概率质量函数。理解如何对 PDF 积分以求出概率、期望值和方差对 Analysis & Approaches 和 Applications & Interpretation 课程都至关重要。
1. From Discrete to Continuous | 从离散到连续
and the sum of all probabilities equals 1. A continuous random variable can take infinitely many values; the probability of any exact value is zero. Instead we work with the area under a curve.
离散随机变量拥有概率质量函数 p(x) = P(X = x),且所有概率之和为 1。连续随机变量可取无穷多个值;取任何精确值的概率为零。我们转而处理曲线下的面积。
In a continuous setting, we define a random variable X on an interval. For example, the time taken to answer a question, the height of plants, or the voltage in a circuit all can be modelled as continuous random variables.
在连续场合中,我们在某个区间上定义一个随机变量 X。例如,回答问题所花的时间、植物的高度或电路中的电压都可以被建模为连续随机变量。
A valid continuous model is specified by a probability density function (PDF) f(x) that is non‑negative and whose total area under the curve equals 1.
一个有效的连续模型由一个概率密度函数 f(x) 来刻画,该函数非负且曲线下的总面积为 1。
2. Probability Density Function – PDF | 概率密度函数
nditions: f(x) ≥ 0 for all real x, and the integral across the whole real line equals one:
概率密度函数 f(x) 须满足两个条件:对所有实数 x 有 f(x) ≥ 0,且在整个实数轴上的积分等于 1:
∫-∞∞ f(x) dx = 1
his is because the area of a line under the curve is zero. Probabilities are only defined over intervals.
对任何具体数值 c,有 P(X = c) = 0。这是因为曲线下一条线的面积为零。概率仅定义在区间上。
A PDF can exceed 1 on some subinterval, as long as the total integrated area remains 1. Do not confuse the density value with a probability.
PDF 在某些子区间上可以超过 1,只要总的积分面积保持为 1。切勿将密度值与概率混淆。
3. Cumulative Distribution Function – CDF | 累积分布函数
x. For a continuous random variable it is defined as the integral of the PDF from −∞ to x:
累积分布函数 F(x) 给出 X 至多为 x 的概率。对连续随机变量,它定义为 PDF 从 −∞ 到 x 的积分:
F(x) = P(X ≤ x) = ∫-∞x f(t) dt
F(x) is non‑decreasing, continuous from the right, and satisfies limx→−∞ F(x) = 0 and limx→∞ F(x) = 1. Where F is differentiable, the PDF can be recovered: f(x) = F'(x).
F(x) 非减、右连续,且满足 limx→−∞ F(x) = 0 和 limx→∞ F(x) = 1。在 F 可导之处,可反推出 PDF:f(x) = F'(x)。
Knowing F(x) makes interval probabilities easy to compute: P(a ≤ X ≤ b) = F(b) − F(a).
知道了 F(x),求区间概率就很简单:P(a ≤ X ≤ b) = F(b) − F(a)。
4. Calculating Probabilities Using Integration | 计算概率——积分方法
To find the probability that X falls between a and b, integrate the PDF:
P(a ≤ X ≤ b) = ∫ab f(x) dx
求 X 落在 a 与 b 之间的概率,只需对 PDF 积分即可。
Because P(X = a) = 0, whether we write strict or non‑ inequalities does not matter for continuous variables: P(a ≤ X ≤ b) = P(a < X < b).
由于 P(X = a) = 0,对连续变量而言,写成严格不等式还是非严格不等式并无区别:P(a ≤ X ≤ b) = P(a < X < b)。
Always check whether a PDF is given in pieces. Integrate only over the support where f(x) > 0. Outside that range the integrand is taken as zero.
务必检查 PDF 是否分段给出。只在支撑集(f(x) > 0 的区间)上积分,超出该范围被积函数视为零。
5. Expected Value E(X) | 期望值 E(X)
For a continuous random variable with PDF f(x), the expectation or mean is
μ = E(X) = ∫-∞∞ x f(x) dx
对于具有 PDF f(x) 的连续随机变量,期望或均值为上述公式。
More generally, for any function g(X), the expectation is E(g(X)) = ∫-∞∞ g(x) f(x) dx. This is used to find E(X²), E(X³), etc.
更一般地,对任意函数 g(X),期望为 E(g(X)) = ∫-∞∞ g(x) f(x) dx。这可用于求 E(X²)、E(X³) 等。
X) + b, where a and b are constants. This property holds for both discrete and continuous variables.
期望具有线性性质:E(aX + b) = a E(X) + b,其中 a 和 b 为常数。该性质对离散和连续变量均成立。
6. Variance and Standard Deviation | 方差与标准差
Variance measures the spread of the distribution. For a continuous X with mean μ,
Var(X) = E[(X − μ)²] = ∫-∞∞ (x − μ)² f(x) dx
方差衡量分布的离散程度。对均值为 μ 的连续变量 X,方差如上述公式。
E(X²) − [E(X)]². First compute E(X²) = ∫ x² f(x) dx, then subtract the square of the mean.
计算上更简便的公式为 Var(X) = E(X²) − [E(X)]²。先计算 E(X²) = ∫ x² f(x) dx,再减去均值的平方。
root of the variance: σ = √Var(X). It has the same units as X and is easier to interpret.
标准差是方差的算术平方根:σ = √Var(X)。它与 X 的单位相同,更易于解释。
ar(Y) = a² Var(X). The constant b only shifts the distribution and does not affect spread.
对于线性变换 Y = aX + b,方差变为 Var(Y) = a² Var(X)。常数 b 仅平移分布,不影响离散程度。
7. Median and Mode | 中位数与众数
t the CDF equals 0.5: F(m) = 0.5. It divides the area under the PDF into two equal halves.
连续随机变量的中位数 m 是满足累积分布函数等于 0.5 的数值:F(m) = 0.5。它将 PDF 下的面积平分为两半。
To find m, solve ∫-∞m .5. If the PDF is defined only on a bounded interval, integrate from the lower bound to m.
要求出 m,解方程 ∫-∞m f(x) dx = 0.5,或等价地 F(m) = 0.5。如果 PDF 仅定义在有界区间上,则从下界积分至 m。
The mode is the value of x where f(x) attains its maximum. For a continuous distribution there may be a single mode (unimodal), more than one (multimodal), or no mode if f is constant.
众数是使 f(x) 取得最大值的 x。连续分布可以是单峰的、多峰的,或在 f 为常数时没有众数。
8. Percentiles and Quantiles | 百分位数与分位数
The k-th percentile Pk is the value such that F(Pk) = k/100. For example, the lower quartile Q1 satisfies F(Q1) = 0.25, and the upper quartile Q3 satisfies F(Q3) = 0.75.
第 k 百分位数 Pk 是满足 F(Pk) = k/100 的值。例如,下四分位数 Q1 满足 F(Q1) = 0.25,上四分位数 Q3 满足 F(Q3) = 0.75。
The interquartile range (IQR) = Q3 − Q1 measures the middle 50% spread. It is a robust measure of variability that is not unduly influenced by extreme values.
四分位距 (IQR) = Q3 − Q1 衡量中间 50% 的分布范围。它是稳健的变异度量,不易受极端值的影响。
Finding percentiles usually requires solving an integral equation or using the inverse CDF when available. With a GDC, you can often use invNorm for normal distributions.
求百分位数通常需要解积分方程,或在有反函数时使用逆 CDF。对于正态分布,利用 GDC 常可使用 invNorm 功能。
9. Linear Transformations | 线性变换的性质
If Y = aX + b, where X is a continuous random variable with PDF fX(x), then the mean and variance of Y are easy to find without deriving the whole distribution:
E(Y) = a E(X) + b, Var(Y) = a² Var(X)
若 Y = aX + b,其中 X 是 PDF 为 fX(x) 的连续变量,则 Y 的均值和方差可轻松求出,无需推导整个分布。
The shape of the distribution is also transformed: if X is uniform on [c,d], then Y is uniform on a different interval. If X is normal, Y remains normal with updated parameters.
分布的形状也随之变换:若 X 在 [c,d] 上均匀分布,则 Y 在另一区间上均匀分布。若 X 服从正态分布,Y 仍是正态分布且参数更新。
d in statistical modelling and in standardising a normal variable to the standard normal Z ~ N(0,1) via Z = (X−μ)/σ.
这一线性性质在统计建模以及通过 Z = (X−μ)/σ 将正态变量标准化为标准正态变量时被大量运用。
10. Common Continuous Distributions | 常见连续分布
Uniform distribution: X ~ is (a+b)/2 and variance is (b−a)²/12. The CDF is linear: F(x) = (x−a)/(b−a) for a ≤ x ≤ b.
均匀分布:X ~ U(a,b) 的 PDF 为 f(x) = 1/(b−a) (a ≤ x ≤ b)。其均值为 (a+b)/2,方差为 (b−a)²/12。CDF 是线性的:F(x) = (x−a)/(b−a) (a ≤ x ≤ b)。
Normal distribution: X ~ N(μ,σ²) has the bell‑shaped PDF f(x) = 1/(σ√2π) e−(x−μ)²/(2σ²). Probabilities are computed using GDC's normalcdf function or by standardising to Z ~ N(0,1) and using tables.
正态分布:X ~ N(μ,σ²) 的钟形 PDF 为 f(x) = 1/(σ√2π) e−(x−μ)²/(2σ²)。概率通过 GDC 的 normalcdf 函数计算,或通过标准化为 Z ~ N(0,1) 查表求得。
Both distributions are central to IB exam questions. The uniform distribution often requires manual integration, whereas the normal distribution relies on technology.
这两种分布都是 IB 考试的核心。均匀分布常需手动积分,而正态分布则依赖计算器技术。
11. Worked Example | 典型例题解析
Problem: A continuous random variable X has PDF f(x) = kx² for 0 ≤ x ≤ 2, and 0 otherwise.
(题目:连续随机变量 X 的 PDF 为 f(x) = kx², 0 ≤ x ≤ 2,其他处为 0。)
a) Find the value of k. Set ∫02 kx² dx = 1. Integrate: k [x³/3]02 = k·(8/3) = 1 ⇒ k = 3/8.
a) 求 k 的值。令 ∫02 kx² dx = 1。积分得 k [x³/3]02 = k·(8/3) = 1 ⇒ k = 3/8。
b) Find E(X). E(X) = ∫02 x·(3/8)x² dx = (3/8) ∫02 x³ dx = (3/8)[x⁴/4]02 = (3/8)·(16/4) = (3/8)·4 = 1.5.
b) 计算 E(X)。E(X) = ∫02 x·(3/8)x² dx = (3/8) ∫02 x³ dx = (3/8)[x⁴/4]02 = (3/8)·4 = 1.5。
c) Find the median m. Solve ∫0m (3/8)x² dx = 0.5. LHS = (3/8)·m³/3 = m³/8. So m³/8 = 0.5 ⇒ m³ = 4 ⇒ m = ∛4 ≈ 1.587.
c) 求中位数 m。解 ∫0m (3/8)x² dx = 0.5。左侧 = (3/8)·m³/3 = m³/8。故 m³/8 = 0.5 ⇒ m = ∛4 ≈ 1.587。
d) Determine the mode. /8)x² is increasing on [0,2], so the maximum occurs at the right endpoint x = 2. Mode = 2.
d) 确定众数。f(x) = (3/8)x² 在 [0,2] 上递增,最大值出现在右端点 x = 2 处。众数 = 2。
This example illustrates the systematic use of integration to extract all key features of a continuous distribution.
该例题展示了如何系统地使用积分提取连续分布的所有关键特征。
Published by TutorHao | IB Mathematics Revision Series | aleveler.com
更多咨询请联系16621398022(同微信)

或截图后用「扫一扫 → 相册」选择本图