English Explanations for checking this guide Exactly two successes? Counting with the binomial distribution This companion brings together explanations included in the guide. Suppose each of four trials has a 1/2 chance of success. To find the chance of exactly two successes, pay attention to which trials succeed. Both the first and second trials could be the only successes, or the first and fourth could be the only successes. Fix the number of trials n in advance and classify each result as a success or a failure. If each trial has the same success probability p and the results are mutually independent, the success count X has a binomial distribution, written Bin(n, p). We will look at its probabilities, mean and variance in turn. Choose the positions of exactly two successes In the first quiz question, choose two of the four positions for the successes and count the other two as failures. The success positions can be (1, 2), (1, 3), (1, 4), (2, 3), (2, 4), or (3, 4). For example, the probability of success, failure, failure, success is (1/2)⁴ = 1/16 because the trials are independent. Each of the other five sequences also has probability 1/16. The sequences are mutually exclusive, so we add their probabilities. The chance of exactly two successes is 6 × (1/16) = 3/8. Add the mean contribution of each trial Record a success as 1 and a failure as 0. Adding those entries gives the number of successes. The mean of one entry is 1 × p + 0 × (1 − p) = p. Add the means of all the entries to get np. This is the mean, or expected value, of the success count. For Bin(10, 0.3) in the second quiz question, it is 10 × 0.3 = 3. It describes the average count across many sets of ten trials. Add the variances of the independent trials The mean of a single entry is p. A success is 1 − p away from the mean in the positive direction, and a failure has a signed difference of −p. Square both differences and weight each by its probability. The variance is p(1 − p)² + (1 − p)p² = p(1 − p). When you add independent entries, their variances add. The variance of the success count is therefore np(1 − p). For Bin(8, 1/2) in the third quiz question, the mean is 8 × (1/2) = 4 and the variance is 8 × (1/2) × (1/2) = 2. Practice finding the positions when the success chance is 1/3 Suppose you run three independent trials, each with a 1/3 chance of success. There are three sequences with exactly two successes, one for each possible position of the failure. Every sequence has two successes and one failure, giving probability (1/3)² × (2/3) = 2/27. Adding the probabilities of the three sequences gives 2/9 for exactly two successes. How to practise Count the trials n and check that the trials are mutually independent and have the same success probability p. For an exact count, multiply the number of ways to choose the success positions by the probability of one such sequence. Use np for the mean of the success count and np(1 − p) for its variance. Check independence as well as the success probability Draw twice from a bag with one red and one blue ball, without replacement, and call red a success. Before any draw, the chance of red is 1/2 on either draw. Once you know the first ball was red, the chance of red on the second draw is zero. The draws are dependent, and there is always exactly one success. Example 1 Four independent trials each have success probability 1/2. What is the probability of exactly two successes? Choices 1/4 1/2 1/8 3/8 Answer: 3/8 There are 4 choose 2 = 6 ways to select the two successful positions. Each four-outcome sequence has probability (1/2)⁴ = 1/16. The total is 6/16 = 3/8. Example 2 X has binomial distribution Bin(10, 0.3). What is its mean? Choices 3 0.3 7 2.1 Answer: 3 Write X as the sum of ten success indicators, each with expectation 0.3. Expectations add, giving 10 × 0.3 = 3. Example 3 X has binomial distribution Bin(8, 1/2). What is its variance? Choices 1/2 2 4 8 Answer: 2 Each independent success indicator has variance p(1 − p). Add eight such variances: 8 × (1/2) × (1/2) = 2. 日本語 本文と例題の確認用説明 成功がちょうど2回の確率は? 二項分布で回数を数えよう この記事に掲載している説明をまとめた確認用の補足です。 4回の試行で、成功する確率は毎回1/2。ちょうど2回成功する確率を求めるには、どの回が成功になるかに注目します。1回目と2回目だけが成功する並びも、1回目と4回目だけが成功する並びもあります。 先に試行回数 n を決め、各回の結果を成功か失敗に分けます。各回の成功確率が同じ p で、結果が互いに独立なら、成功回数 X は二項分布 Bin(n, p) に従います。確率、平均、分散を順に見ていきましょう。 ちょうど2回の確率は、成功の位置を選んで求める 1問目では、4つの位置から成功する2つを選び、残りを失敗とします。成功位置は (1, 2)、(1, 3)、(1, 4)、(2, 3)、(2, 4)、(3, 4) の6通りです。 例えば「成功、失敗、失敗、成功」の確率は、4回が独立なので (1/2)⁴=1/16 です。他の5通りも1/16ずつで、これらは同時には起きません。足し合わせると、ちょうど2回成功する確率は 6×(1/16)=3/8 になります。 平均は、1回あたりの成功回数を足す 1回の結果を成功なら1、失敗なら0と記録すると、記録を足した数が成功回数です。1回分の記録の平均は 1×p+0×(1−p)=p になります。 各回の平均を足すと、成功回数の平均、つまり期待値は np です。2問目の Bin(10, 0.3) なら 10×0.3=3。10回を1組にして何組も試したときの、1組あたりの平均を表します。 分散は、独立な各回の分散を足す 1回分の記録の平均は p でした。平均との差は成功なら 1−p、失敗なら −p。差を二乗して、それぞれが起こる確率を掛けて足すと、分散は p(1−p)²+(1−p)p²=p(1−p) です。 独立な記録を足すと、各回の分散も足せます。したがって成功回数の分散は np(1−p) です。3問目の Bin(8, 1/2) では平均が 8×(1/2)=4、分散が 8×(1/2)×(1/2)=2 になります。 練習 成功確率が1/3のときも位置から考える 毎回の成功確率が1/3で、独立に3回試すとします。ちょうど2回成功する並びは、失敗の位置を選ぶと3通りです。 どの並びも成功が2回、失敗が1回なので、確率は (1/3)²×(2/3)=2/27。3通りを足すと、ちょうど2回成功する確率は2/9です。 取り組み方 試行回数 n を数え、毎回の成功確率 p が同じか、試行が互いに独立かを確認する。 ちょうど何回かを求めるときは、成功する位置の選び方と、1つの並びが起こる確率を掛ける。 求めたいのが平均なら np、分散なら np(1−p) を使う。 各回の成功確率に加えて、独立性も確かめる 赤1個、青1個の袋から、1個ずつ戻さずに2回引いて赤を成功とします。引く前に見れば、どちらの回も赤の確率は1/2です。ただし1回目が赤と分かると、2回目に赤が出る確率は0です。この手順では独立性が成り立たず、成功は必ず1回です。 例題 1 独立な4回の試行、毎回成功確率1/2。成功がちょうど2回の確率は? 選択肢 1/4 1/2 1/8 3/8 正解:3/8 成功位置は4C2=6通り。各並び1/16で6/16。 例題 2 Xが二項分布Bin(10,0.3)に従う。平均は? 選択肢 3 0.3 7 2.1 正解:3 各試行の成功指標の平均0.3を10回足すのでnp。 例題 3 Xが二項分布Bin(8,1/2)に従う。分散は? 選択肢 1/2 2 4 8 正解:2 独立な成功指標の分散p(1−p)をn回足す。