Probability solutions

This commit is contained in:
2026-09-18 15:44:18 +00:00
parent 9d17864613
commit 0ac525644e
+251 -54
View File
@@ -2,13 +2,17 @@
<title>Definition of Probability</title> <title>Definition of Probability</title>
<p> <p>
Now that we have the language to refer to outcomes and events of an experiment, we want to start quantifying how likely those outcomes/events are to occur. Now that we have the language to refer to outcomes and events of an
experiment, we want to start quantifying how likely those outcomes/events
are to occur.
</p> </p>
<definition xml:id="def-probability-distribution"> <definition xml:id="def-probability-distribution">
<statement> <statement>
<p> <p>
A <term>probability distribution</term> on a sample space <m>\Omega</m> assigns probabilities to every event, satisfying the following conditions: A <term>probability distribution</term> on a sample space <m>\Omega</m>
assigns probabilities to every event, satisfying the following
conditions:
<ol> <ol>
<li> <li>
<p> <p>
@@ -24,7 +28,8 @@
<li> <li>
<p> <p>
If <m>A \cap B = \emptyset</m>, then <m>\Pr(A\cup B) = \Pr(A) + \Pr(B)</m>. If <m>A \cap B = \emptyset</m>, then
<m>\Pr(A\cup B) = \Pr(A) + \Pr(B)</m>.
</p> </p>
</li> </li>
</ol> </ol>
@@ -33,8 +38,11 @@
</definition> </definition>
<p> <p>
For small probability spaces (i.e., with finitely many outcomes in the sample space), we'll usually assign probabilities to each individual outcome, and perhaps list them in a table. For small probability spaces (i.e., with finitely many outcomes in the
Then, to find the probability of any event, simply add together the probabilities of each outcome in that event. sample space), we'll usually assign probabilities to each individual
outcome, and perhaps list them in a table.
Then, to find the probability of any event, simply add together the
probabilities of each outcome in that event.
</p> </p>
<example> <example>
@@ -87,7 +95,8 @@
</table> </table>
<p> <p>
One possible event is <m>A = \{2, 4, 6\}</m>, i.e., the event that the result of the roll is even. One possible event is <m>A = \{2, 4, 6\}</m>, i.e., the event that the
result of the roll is even.
The probability of <m>A</m> is: The probability of <m>A</m> is:
<md> <md>
<mrow> \Pr(A) = \Pr(2) + \Pr(4) + \Pr(6) = \frac{1}{6} + \frac{1}{6} + \frac{1}{6} = \frac{3}{6} = \frac{1}{2} </mrow> <mrow> \Pr(A) = \Pr(2) + \Pr(4) + \Pr(6) = \frac{1}{6} + \frac{1}{6} + \frac{1}{6} = \frac{3}{6} = \frac{1}{2} </mrow>
@@ -99,16 +108,20 @@
<definition xml:id="def-discrete-uniform-distribution"> <definition xml:id="def-discrete-uniform-distribution">
<statement> <statement>
<p> <p>
Let <m>\Omega = \{x_1, x_2, \dotsc, x_n\}</m> be a sample space and <m>A\subset \Omega</m> an event. Let <m>\Omega = \{x_1, x_2, \dotsc, x_n\}</m> be a sample space and
We refer to the distribution in which <m>\Pr(x_i) = \frac{1}{n}</m> for all <m>i</m> as the <term>uniform distribution</term>. <m>A\subset \Omega</m> an event.
We refer to the distribution in which <m>\Pr(x_i) = \frac{1}{n}</m> for
all <m>i</m> as the <term>uniform distribution</term>.
In this case, it follows that <m>\Pr(A) = \frac{|A|}{|\Omega|}</m>. In this case, it follows that <m>\Pr(A) = \frac{|A|}{|\Omega|}</m>.
</p> </p>
</statement> </statement>
</definition> </definition>
<p> <p>
When we talk about a fair coin flip or a fair die roll, the word "fair" is indicating a uniform distribution. When we talk about a fair coin flip or a fair die roll, the word "fair" is
However, don't make the mistake of assuming that all distributions are uniform by default. indicating a uniform distribution.
However, don't make the mistake of assuming that all distributions are
uniform by default.
</p> </p>
<example> <example>
@@ -121,27 +134,32 @@
<answer> <answer>
<p> <p>
Without assuming the distribution is fair (i.e., that each value <m>1, 2, \dotsc, 10</m>) has probability <m>1/10</m> of occurring), we don't have enough information to answer this question. Without assuming the distribution is fair (i.e., that each value
<m>1, 2, \dotsc, 10</m> ) has probability <m>1/10</m> of occurring), we
don't have enough information to answer this question.
</p> </p>
<p> <p>
In fact, the situation is even more vague than that: the sample space itself is unclear. In fact, the situation is even more vague than that: the sample space
Are we only allowed to pick integer values? What about fractions like <m>7/2</m>? What about irrational numbers like <m>\pi</m>? itself is unclear.
Are we only allowed to pick integer values?
What about fractions like <m>7/2</m>?
What about irrational numbers like <m>\pi</m>?
</p> </p>
</answer> </answer>
</example> </example>
<exercises xml:id="exercises-Probability"> <exercises xml:id="exercises-Probability">
<exercise> <exercise>
<statement> <statement>
<p> <p>
Consider the sample space <m>\Omega = \{1, 2, 3, 4, 5, 6, 7, 8\}</m> with probability distribution below. Consider the sample space <m>\Omega = \{1, 2, 3, 4, 5, 6, 7, 8\}</m>
Calculate the probabilities of <m>A = \{1, 3, 7, 8\}</m>, <m>B = \{2, 3, 6, 7\}</m>, <m>A\cup B</m>, and <m>A \cap B</m>. with probability distribution below.
Calculate the probabilities of <m>A = \{1, 3, 7, 8\}</m>,
<m>B = \{2, 3, 6, 7\}</m>, <m>A\cup B</m>, and <m>A \cap B</m>.
</p> </p>
<table> <table>
<title></title> <title/>
<tabular halign="center"> <tabular halign="center">
<row bottom="minor"> <row bottom="minor">
<cell><m>x</m></cell> <cell><m>x</m></cell>
@@ -196,11 +214,41 @@
</table> </table>
</statement> </statement>
<hint>
<p>
Remember that, to calculate the probability of an event, you should
add up the probabilities of each outcome in the event.
</p>
</hint>
<answer> <answer>
<p> <p>
<m>\Pr(A) = 0.45, \Pr(B) = 0.4, \Pr(A \cup B) = 0.6, \Pr(A \cap B) = 0.25.</m> <m>\Pr(A) = 0.45, \Pr(B) = 0.4, \Pr(A \cup B) = 0.6, \Pr(A \cap B) = 0.25.</m>
</p> </p>
</answer> </answer>
<solution>
<p>
<md>
<mrow> \Pr(A) \amp = \Pr(1) + \Pr(3) + \Pr(7) + \Pr(8) </mrow>
<mrow> \amp = 0.1 + 0.2 + 0.05 + 0.1 </mrow>
<mrow> \amp = 0.45 </mrow>
<mrow> \Pr(B) \amp = \Pr(2) + \Pr(3) + \Pr(6) + \Pr(7) </mrow>
<mrow> \amp = 0.05 + 0.2 + 0.1 + 0.05 </mrow>
<mrow> \amp = 0.4 </mrow>
</md>
The other events are <m>A\cup B = \{1, 2, 3, 6, 7, 8\}</m> and
<m>A\cap B = \{3, 7\}</m>, so:
<md>
<mrow> \Pr(A \cup B) \amp = \Pr(1) + \Pr(2) + \Pr(3) + \Pr(6) + \Pr(7) + \Pr(8) </mrow>
<mrow> \amp = 0.1 + 0.05 + 0.2 + 0.1 + 0.05 + 0.1 </mrow>
<mrow> \amp = 0.6 </mrow>
<mrow> \Pr(A \cap B) \amp = \Pr(3) + \Pr(7) </mrow>
<mrow> \amp = 0.2 + 0.05 </mrow>
<mrow> \amp = 0.25 </mrow>
</md>
</p>
</solution>
</exercise> </exercise>
<exercise> <exercise>
@@ -208,11 +256,11 @@
<p> <p>
Suppose we flip a coin two times. Suppose we flip a coin two times.
Answer the questions below. Answer the questions below.
What about three flips? What about four flips? What about three flips?
What about four flips?
</p> </p>
</introduction> </introduction>
<task> <task>
<statement> <statement>
<p> <p>
@@ -227,11 +275,11 @@
</answer> </answer>
</task> </task>
<task> <task>
<statement> <statement>
<p> <p>
Make a probability distribution table for <m>\Omega</m> assuming the coin is fair. Make a probability distribution table for <m>\Omega</m> assuming the
coin is fair.
</p> </p>
</statement> </statement>
@@ -269,11 +317,11 @@
</answer> </answer>
</task> </task>
<task> <task>
<statement> <statement>
<p> <p>
Make a probability distribution table assuming the coin comes up heads with probability 0.3. Make a probability distribution table assuming the coin comes up
heads with probability 0.3.
</p> </p>
</statement> </statement>
@@ -315,12 +363,11 @@
<exercise> <exercise>
<introduction> <introduction>
<p> <p>
Suppose we roll a die two times. Suppose we roll a fair 6-sided die two times.
Answer the questions below. Answer the questions below.
</p> </p>
</introduction> </introduction>
<task> <task>
<statement> <statement>
<p> <p>
@@ -342,32 +389,40 @@
</answer> </answer>
</task> </task>
<task> <task>
<statement> <statement>
<p> <p>
Make a probability distribution table for <m>\Omega</m> assuming the die is fair. Make a probability distribution table for <m>\Omega</m> assuming the
die is fair.
</p> </p>
</statement> </statement>
<answer> <answer>
<p> <p>
We'll avoid an overly large table and note that, since the die is fair, every outcome is equally likely. We'll avoid an overly large table and note that, since the die is
Therefore, <m>\Pr(x) = \frac{1}{36}</m> for every <m>x\in \Omega</m>. fair, every outcome is equally likely.
Therefore, <m>\Pr(x) = \frac{1}{36}</m> for every
<m>x\in \Omega</m>.
</p> </p>
</answer> </answer>
</task> </task>
<task> <task>
<statement> <statement>
<p> <p>
Let <m>A</m> be the event that the second roll is higher than the first, and let <m>B</m> be the event that the first roll is even. Let <m>A</m> be the event that the second roll is higher than the
first, and let <m>B</m> be the event that the first roll is even.
Find <m>\Pr(A), \Pr(B)</m>, and <m>\Pr(A \cap B)</m>. Find <m>\Pr(A), \Pr(B)</m>, and <m>\Pr(A \cap B)</m>.
</p> </p>
</statement> </statement>
<answer> <answer>
<p>
<m>\Pr(A) = \frac{5}{12}, \Pr(B) = \frac{1}{2}, \Pr(A \cap B) = \frac{1}{6}</m>.
</p>
</answer>
<solution>
<p> <p>
<md> <md>
<mrow> A = \{ \amp (1, 2), (1, 3), (1, 4), (1, 5), (1, 6), </mrow> <mrow> A = \{ \amp (1, 2), (1, 3), (1, 4), (1, 5), (1, 6), </mrow>
@@ -381,18 +436,23 @@
<mrow> A \cap B = \{ \amp (2, 3), (2, 4), (2, 5), (2, 6), </mrow> <mrow> A \cap B = \{ \amp (2, 3), (2, 4), (2, 5), (2, 6), </mrow>
<mrow> \amp (4, 5), (4, 6)\} </mrow> <mrow> \amp (4, 5), (4, 6)\} </mrow>
</md> </md>
Therefore <m>\Pr(A) = \frac{15}{36} = \frac{5}{12}, \Pr(B) = \frac{18}{36} = \frac{1}{2}, \Pr(A \cap B) = \frac{6}{36} = \frac{1}{6}.</m> Therefore
<m>\Pr(A) = \frac{15}{36} = \frac{5}{12}, \Pr(B) = \frac{18}{36} = \frac{1}{2}, \Pr(A \cap B) = \frac{6}{36} = \frac{1}{6}.</m>
</p> </p>
</answer> </solution>
</task> </task>
</exercise> </exercise>
<exercise> <exercise>
<statement> <statement>
<p> <p>
Suppose a die has the values <m>1, 2, 3, 4, 5, 6</m> on the faces, but the die is not fair. Suppose a die has the values <m>1, 2, 3, 4, 5, 6</m> on the faces, but
Instead, the probabilities scale by the same amount as the face values. the die is not fair.
For example, a result of 4 is twice as likely as a result of 2, since 4 is twice as large as 2; a result of 6 is six times more likely than a result of 1; and so on. Instead, the probabilities scale by the same amount as the face
values.
For example, a result of 4 is twice as likely as a result of 2, since
4 is twice as large as 2; a result of 6 is six times more likely than
a result of 1; and so on.
Write a probability distribution table for this die. Write a probability distribution table for this die.
</p> </p>
</statement> </statement>
@@ -439,13 +499,74 @@
</tabular> </tabular>
</table> </table>
</answer> </answer>
<solution>
<p>
Let <m>\Pr(1) = x</m>.
Then <m>\Pr(2) = 2 \Pr(1) = 2x</m>, and <m>\Pr(3) = 3\Pr(1) = 3x</m>,
and so on.
So the total probability in the space is:
<md>
<mrow> Pr(\Omega) \amp = \Pr(1) + \Pr(2) + \Pr(3) + \Pr(4) + \Pr(5) + \Pr(6) </mrow>
<mrow> \amp = x + 2x + 3x + 4x + 5x + 6x </mrow>
<mrow> \amp = 21x </mrow>
</md>
Since the total probability must add up to 1, we have <m>1 = 21x</m>,
so <m>x = \frac{1}{21}</m>, and we can calculate the rest of the
probabilities from there.
</p>
<table>
<title>Probability Distribution for a Linearly Scaled Die</title>
<tabular halign="center">
<row bottom="minor">
<cell><m>x</m></cell>
<cell><m>\Pr(x)</m></cell>
</row>
<row>
<cell>1</cell>
<cell><m>1/21</m></cell>
</row>
<row>
<cell>2</cell>
<cell><m>2/21</m></cell>
</row>
<row>
<cell>3</cell>
<cell><m>3/21</m></cell>
</row>
<row>
<cell>4</cell>
<cell><m>4/21</m></cell>
</row>
<row>
<cell>5</cell>
<cell><m>5/21</m></cell>
</row>
<row>
<cell>6</cell>
<cell><m>6/21</m></cell>
</row>
</tabular>
</table>
</solution>
</exercise> </exercise>
<exercise> <exercise>
<statement> <statement>
<p> <p>
Suppose a die has the values <m>1, 2, 3, 4, 5, 6</m> on the faces, but the die is not fair. Suppose a die has the values <m>1, 2, 3, 4, 5, 6</m> on the faces, but
Instead, each even value has an equal probability, each odd value has an equal probability, and the even values are each twice as likely as the odd values to appear on a roll. the die is not fair.
Instead, each even value has an equal probability, each odd value has
an equal probability, and the even values are each twice as likely as
the odd values to appear on a roll.
Write a probability distribution table for this die. Write a probability distribution table for this die.
</p> </p>
</statement> </statement>
@@ -492,36 +613,112 @@
</tabular> </tabular>
</table> </table>
</answer> </answer>
<solution>
<p>
Let <m>\Pr(1) = x</m>.
Then <m>\Pr(3) = x</m> and <m>\Pr(5) = x</m>, since all odd rolls must
have the same probability.
The even rolls must have twice the probability, so
<m>\Pr(2) = \Pr(4) = \Pr(6) = 2x</m>.
Now:
<md>
<mrow> Pr(\Omega) \amp = \Pr(1) + \Pr(2) + \Pr(3) + \Pr(4) + \Pr(5) + \Pr(6) </mrow>
<mrow> \amp = x + 2x + x + 2x + x + 2x </mrow>
<mrow> \amp = 9x </mrow>
</md>
Since the total probability must add up to 1, we have <m>1 = 9x</m>,
so <m>x = \frac{1}{9}</m>, and we can calculate the rest of the
probabilities from there.
</p>
<table>
<title>Probability Distribution for an Even-biased Die</title>
<tabular halign="center">
<row bottom="minor">
<cell><m>x</m></cell>
<cell><m>\Pr(x)</m></cell>
</row>
<row>
<cell>1</cell>
<cell><m>1/9</m></cell>
</row>
<row>
<cell>2</cell>
<cell><m>2/9</m></cell>
</row>
<row>
<cell>3</cell>
<cell><m>1/9</m></cell>
</row>
<row>
<cell>4</cell>
<cell><m>2/9</m></cell>
</row>
<row>
<cell>5</cell>
<cell><m>1/9</m></cell>
</row>
<row>
<cell>6</cell>
<cell><m>2/9</m></cell>
</row>
</tabular>
</table>
</solution>
</exercise> </exercise>
<exercise> <exercise>
<statement> <statement>
<p> <p>
A toxin molecule inside a cell has a 0.3 probability of leaving the cell during a 1-minute period. A toxin molecule inside a cell has a 0.3 probability of leaving the
For each value of <m>n = 1, 2, 3, \dotsc</m>, find the probability of the toxin molecule leaving the cell during the <m>n</m>th minute. cell during a 1-minute period.
What is the probability of the molecule leaving the cell during the first 3 minutes? For each value of <m>n = 1, 2, 3, \dotsc</m>, find the probability of
the toxin molecule leaving the cell during the <m>n</m> th minute.
What is the probability of the molecule leaving the cell during the
first 3 minutes?
</p> </p>
</statement> </statement>
<answer> <answer>
<p> <p>
For short, write <m>\Pr(n)</m> to mean the probability of the toxin molecule leaving during the <m>n</m>th minute. Write <m>T</m> for the minute that the toxin molecule leaves the cell.
Then <m>\Pr(n) = (0.7)^{n - 1} (0.3).</m> Then <m>\Pr(T = n) = (0.7)^{n - 1} (0.3)</m>, and <m>\Pr(T \leq 3) = 0.657</m>.
</p>
</answer>
<solution>
<p>
Write <m>T</m> for the minute that the toxin molecule leaves the cell.
We're told that the toxin molecule has probability <m>0.3</m> of leaving during each minute.
Therefore, the probability of remaining during a particular minute is <m>1 - 0.3 = 0.7</m>.
</p> </p>
<p> <p>
The probability of leaving during the first 3 minutes is <m>\Pr(1) + \Pr(2) + \Pr(3) = 0.657.</m> For the toxin molecule to leave the cell during minute <m>n</m>, it must remain for minutes <m>1, 2, \dotsc, n - 1</m>, and then leave during minute <m>n</m>.
The probability to remain each minute is <m>0.7</m>, so we must multiply <m>n - 1</m> copies of <m>0.7</m>.
Then the probability of leaving is <m>0.3</m>, so we multiply by a factor of <m>0.3</m>, yielding the formula:
<md>
<mrow> \Pr(T = n) = (0.7)^{n - 1}(0.3). </mrow>
</md>
</p> </p>
</answer>
</exercise>
<!--
<exercise>
<statement>
<p> <p>
Each of 10 toxin molecules inside a cell has a 0.3 probability of leaving the cell during a 1-minute period. Then, the probaiblity of the molecule leaving within the first three minutes will be:
For each value of <m>n = 1, 2, 3, \dotsc</m>, and for each value of <m>0\leq k \leq n</m>, find the probability that exactly <m>k</m> toxin molecules remain in the cell after the <m>n</m>th minute. <md>
<mrow> \Pr(T \leq 3) \amp = \Pr(T = 1) + \Pr(T = 2) + \Pr(T = 3) </mrow>
<mrow> \amp = 0.3 + (0.7)(0.3) + (0.7)^2(0.3) </mrow>
<mrow> \amp = 0.657. </mrow>
</md>
</p> </p>
</statement> </solution>
</exercise> </exercise>
needs binomial coefficients --> </exercises> </exercises>
</section> </section>