设一组样本 ( X 1 , X 2 , ⋯ , X n ) ∼ N ( μ , σ 2 ) (X_1,X_2,\cdots,X_n)\sim N(\mu,\sigma^2) (X1,X2,⋯,Xn)∼N(μ,σ2),记其期望和离差平方和为
X ‾ = 1 n ∑ i = 1 n X i S S ( X ) = ∑ i = 1 n ( X i − X ‾ ) 2 \begin{gathered} \overline{X}=\frac{1}{n}\sum_{i=1}^n{X_i} \\ SS(X)=\sum_{i=1}^{n}(X_i-\overline{X})^2 \end{gathered} X=n1i=1∑nXiSS(X)=i=1∑n(Xi−X)2
证明
S S ( X ) σ 2 ∼ χ 2 ( n − 1 ) \frac{SS(X)}{\sigma^2}\sim\chi^2(n-1) σ2SS(X)∼χ2(n−1)
证:对 ( X i − X ‾ ) 2 (X_i-\overline{X})^2 (Xi−X)2,凑出 ( X i − μ ) 2 (X_i-\mu)^2 (Xi−μ)2并还原
S S ( X ) = ∑ i = 1 n [ ( X i − μ ) 2 + 2 X i μ − μ 2 − 2 X i X ‾ + X ‾ 2 ] SS(X)=\sum_{i=1}^n\left[(X_i-\mu)^2+2X_i\mu-\mu^2-2X_i\overline{X}+\overline{X}^2\right] SS(X)=i=1∑n[(Xi−μ)2+2Xiμ−μ2−2XiX+X2]
分解求和式并求和
S S ( X ) = ∑ i = 1 n ( X i − μ ) 2 + ∑ i = 1 n [ X ‾ 2 − μ 2 + 2 X i ( μ − X ‾ ) ] = ∑ i = 1 n ( X i − μ ) 2 + n ( X ‾ 2 − μ 2 ) + 2 ( μ − X ‾ ) ∑ i = 1 n X i = ∑ i = 1 n ( X i − μ ) 2 + n ( X ‾ + μ ) ( X ‾ − μ ) + 2 n ( μ − X ‾ ) X ‾ = ∑ i = 1 n ( X i − μ ) 2 + n ( X ‾ − μ ) ( X ‾ + μ − 2 X ‾ ) = ∑ i = 1 n ( X i − μ ) 2 − n ( X ‾ − μ ) 2 \begin{aligned} SS(X)&=\sum_{i=1}^n(X_i-\mu)^2+\sum_{i=1}^n\left[\overline{X}^2-\mu^2+2X_i(\mu-\overline{X})\right] \\ &=\sum_{i=1}^n(X_i-\mu)^2+n\left(\overline{X}^2-\mu^2\right)+2(\mu-\overline{X})\sum_{i=1}^nX_i \\ &=\sum_{i=1}^n(X_i-\mu)^2+n(\overline{X}+\mu)(\overline{X}-\mu)+2n(\mu-\overline{X})\overline{X} \\ &=\sum_{i=1}^n(X_i-\mu)^2+n(\overline{X}-\mu)(\overline{X}+\mu-2\overline{X}) \\ &=\sum_{i=1}^n(X_i-\mu)^2-n(\overline{X}-\mu)^2 \end{aligned} SS(X)=i=1∑n(Xi−μ)2+i=1∑n[X2−μ2+2Xi(μ−X)]=i=1∑n(Xi−μ)2+n(X2−μ2)+2(μ−X)i=1∑nXi=i=1∑n(Xi−μ)2+n(X+μ)(X−μ)+2n(μ−X)X=i=1∑n(Xi−μ)2+n(X−μ)(X+μ−2X)=i=1∑n(Xi−μ)2−n(X−μ)2
两侧同除 σ 2 \sigma^2 σ2
S S ( X ) σ 2 = ∑ i = 1 n ( X i − μ ) 2 − n ( X ‾ − μ ) 2 σ 2 = ∑ i = 1 n ( X i − μ σ ) 2 − [ n σ ( X ‾ − μ ) ] 2 \begin{aligned} \frac{SS(X)}{\sigma^2}&=\frac{\sum_{i=1}^n(X_i-\mu)^2-n(\overline{X}-\mu)^2}{\sigma^2} \\ &=\sum_{i=1}^n(\frac{X_i-\mu}{\sigma})^2-\left[\frac{\sqrt{n}}{\sigma}(\overline{X}-\mu)\right]^2 \end{aligned} σ2SS(X)=σ2∑i=1n(Xi−μ)2−n(X−μ)2=i=1∑n(σXi−μ)2−[σn(X−μ)]2
X i − μ σ \frac{X_i-\mu}{\sigma} σXi−μ是对 X i X_i Xi的归一化,因此 X i − μ σ ∼ N ( 0 , 1 ) \frac{X_i-\mu}{\sigma}\sim N(0,1) σXi−μ∼N(0,1),故
∑ i = 1 n ( X i − μ σ ) 2 ∼ χ 2 ( n ) \sum_{i=1}^n(\frac{X_i-\mu}{\sigma})^2\sim\chi^2(n) i=1∑n(σXi−μ)2∼χ2(n)
由于 X ‾ ∼ N ( μ , σ 2 n ) \overline{X}\sim N\left(\mu,\frac{\sigma^2}{n}\right) X∼N(μ,nσ2),因此
n σ ( X ‾ − μ ) ∼ N ( 0 , 1 ) [ n σ ( X ‾ − μ ) ] 2 ∼ χ 2 ( 1 ) \begin{gathered} \frac{\sqrt{n}}{\sigma}(\overline{X}-\mu)\sim N(0,1) \\ \left[\frac{\sqrt{n}}{\sigma}(\overline{X}-\mu)\right]^2\sim\chi^2(1) \end{gathered} σn(X−μ)∼N(0,1)[σn(X−μ)]2∼χ2(1)
故
S S ( X ) σ 2 ∼ χ 2 ( n − 1 ) \frac{SS(X)}{\sigma^2}\sim\chi^2(n-1) σ2SS(X)∼χ2(n−1)