方針
ベータ分布と二項分布の関係を示す問題.X~Beta(alpha,beta)の時,確率密度関数は,
f_X(x)=\frac{1}{B(\alpha,\beta)}x^{\alpha-1}(1-x)^{\beta-1}
ただしBをベータ関数といい,
B(\alpha,\beta)=\int_0^1t^{\alpha-1}(1-t)^{\beta-1}dt
である,ベータ関数は
B(\alpha,\beta)=\frac{\Gamma(\alpha)\Gamma(\beta)}{\Gamma(\alpha+\beta)}
という性質を持つ.全確率1を示す.
\begin{align}
\int_0^1\frac{1}{B(\alpha,\beta)}x^{\alpha-1}(1-x)^{\beta-1}dx&= \frac{1}{B(\alpha,\beta)}\int_0^1x^{\alpha-1}(1-x)^{\beta-1}dx\\
&= \frac{B(\alpha,\beta)}{B(\alpha,\beta)}\\
&= 1
\end{align}
分布関数は,
\begin{align}
F_X(x)&= \int_0^x\frac{1}{B(\alpha,\beta)}t^{\alpha-1}(1-t)^{\beta-1}dt\\
&= \frac{1}{B(\alpha,\beta)}\int_0^xt^{\alpha-1}(1-t)^{\beta-1}dt
\end{align}
期待値と分散は,
\begin{align}
\mathbb{E}_{X\sim Beta(\alpha,\beta)}[X]&= \int_0^1\frac{1}{B(\alpha,\beta)}x^\alpha(1-x)^{\beta-1}dx\\
&= \frac{B(\alpha+1,\beta)}{B(\alpha,\beta)}\int_0^1\frac{1}{B(\alpha+1,\beta)}x^\alpha(1-x)^{\beta-1}dx\\
&= \frac{\Gamma(\alpha+1)\Gamma(\beta)}{\Gamma(\alpha+\beta+1)}\frac{\Gamma(\alpha+\beta)}{\Gamma(\alpha)\Gamma(\beta)}\\
&= \frac{\alpha}{\alpha+\beta}\\
\mathbb{E}_{X\sim Beta(\alpha,\beta)}[X^2]&= \int_0^1\frac{1}{B(\alpha,\beta)}x^{\alpha+1}(1-x)^{\beta-1}dx\\
&= \frac{B(\alpha+2,\beta)}{B(\alpha,\beta)}\int_0^1\frac{1}{B(\alpha+2,\beta)}x^{\alpha+1}(1-x)^{\beta-1}dx\\
&= \frac{\Gamma(\alpha+1)\Gamma(\beta)}{\Gamma(\alpha+\beta+2)}\frac{\Gamma(\alpha+\beta)}{\Gamma(\alpha)\Gamma(\beta)}\\
&= \frac{\alpha(\alpha+1)}{(\alpha+\beta+1)(\alpha+\beta)}\\
Var(X)&= \frac{\alpha(\alpha+1)}{(\alpha+\beta+1)(\alpha+\beta)}-\frac{\alpha^2}{(\alpha+\beta)^2}\\
&= \frac{\alpha\beta}{(\alpha+\beta+1)(\alpha+\beta)^2}
\end{align}
答案
X~Bin(n,p)の時,
\begin{align}
P[X\leq x]=\sum_{k=0}^x{}_nC_xp^x(1-p)^{n-x}
\end{align}
Y~Beta(n-x,x+1)の時,
\begin{align}
P[Y\leq 1-p]&= \int_0^{1-p}\frac{1}{B(n-x,x+1)}y^{n-x-1}(1-y)^xdy\\
&= \frac{\Gamma(n+1)}{\Gamma(n-x)\Gamma(x+1)}\int_0^{1-p}y^{n-x-1}(1-y)^xdy\\
&= \frac{n!}{(n-x-1)!x!}\int_0^{1-p}\{\frac{1}{n-x}y^{n-x}\}'(1-y)^xdy\\
&= \frac{n!}{(n-x)!x!}\{\left[y^{n-x}(1-y)^x\right]_0^{1-p}+x\int_0^{1-p}y^{n-x}(1-y)^{x-1}dy\}\\
&= {}_nC_xp^x(1-p)^{n-x}+\frac{n!}{(n-x)!(x-1)!}\int_0^{1-p}y^{n-x}(1-y)^{x-1}dy\\
&= {}_nC_xp^x(1-p)^{n-x}+\frac{\Gamma(n+1)}{\Gamma(n-x+1)\Gamma(x)}\int_0^{1-p}y^{n-x}(1-y)^{x-1}dy\\
&= {}_nC_xp^x(1-p)^{n-x}+\int_0^{1-p}\frac{1}{B(n-x+1,x)}y^{n-x}(1-y)^{x-1}dy\tag{1}
\end{align}
ここで,
P_x=\int_0^{1-p}\frac{1}{B(n-x,x+1)}y^{n-x-1}(1-y)^xdy
と置くと,
\begin{align}
P_0&= \int_0^{1-p}\frac{1}{B(n,1)}y^{n-1}dy\\
&= n\int_0^{1-p}y^{n-1}dy\\
&= n\left[\frac{1}{n}y^n\right]_0^{1-p}\\
&= (1-p)^n\\
&= {}_nC_0p^0(1-p)^n
\end{align}
である.(1)より,
\begin{align}
P[Y\leq 1-p]&= P_x\\
&= {}_nC_xp^x(1-p)^{n-x}+P_{x-1}\\
&= {}_nC_xp^x(1-p)^{n-x}+{}_nC_{x-1}p^{x-1}(1-p)^{n-x+1}+P_{x-2}\\
&\vdots\\
&= {}_nC_xp^x(1-p)^{n-x}+{}_nC_{x-1}p^{x-1}(1-p)^{n-x+1}+...+{}_nC_0p^0(1-p)^n\\
&= \sum_{k=0}^x{}_nC_kp^k(1-p)^{n-k}\\
&= P[X\leq x]
\end{align}
参考文献
- 『現代数理統計学の基礎』(久保川達也 著)