0% found this document useful (0 votes)
9 views

Problem_Set_7

Uploaded by

louxiaoxiao42
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views

Problem_Set_7

Uploaded by

louxiaoxiao42
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 11

MATH-UA 120 Discrete Mathematics:

Problem Set 7
Elizabeth Bennet
Due Monday, November 25th, 2024

Assignment Instructions
• These are to be written up in LATEX and turned in on Gradescope.
• Click here to duplicate this .tex file in Overleaf .
• Write your solutions inside the solution environment.
• You are always encouraged to talk problems through with your peers and your instructor, but your
write up should be done independently.

• Problems are graded on correctness and fluency.


• Unless stated otherwise, all calculations require justification.
• Some tutorials on how to use LATEX can be found here. If you have any questions about LATEX
commands you can always ask your instructor for advice.

Statement on generative AI
In this and other mathematics courses, you are expected to construct clear and concise mathematical argu-
ments based on statements proven in our text and class notes. Large language models such as ChatGPT
are unable to produce this kind of solution. They also frequently generate circular logic and outright false
results.
You may use AI to summarise content, generate study plans, create problems, or do other study-related
activities. You may not ask a chatbot to solve your quiz or homework problems, or do any assessment-related
activities.
You may use AI tools to edit your grammar and punctuation, but remember that mathematical English
is not the same as academic English in other disciplines.

1
Problem 1
A fair coin is flipped 10 times.
a) What is the probability that there are an equal number of heads and tails?
b) What is the probability that the first three flips are heads?
c) What is the probability that there are an equal number of heads and tails and the first three flips are
heads?
d) What is the probability that there are an equal number of heads and tails or the first three flips are
heads?
For clarity, when we say A or B, this always includes the outcome where both events occur.

e) What is the probability that the first three flips are heads given that an equal number of heads and tails
are flipped?

Let the event A represent getting 5 heads and 5 tails in 10 coin flips, and let the event B represent that
the first 3 flips are heads.
(a) Probability of A: The probability of getting an equal number of heads and tails in 10 flips is:
 
10 1
P (A) = .
5 210

(b) Probability of B: The probability that the first 3 flips are heads is:
1
P (B) = .
23
(c) Conditional probability P (A | B): Given that the first 3 flips are heads, to ensure that the total
number of heads and tails are equal, there must be 2 heads and 5 tails among the remaining 7 flips. The
probability of this is:  
7 1
P (A | B) = .
2 27
(d) Probability of P (A ∪ B): The probability of A ∪ B is computed using the inclusion-exclusion formula:

P (A ∪ B) = P (A) + P (B) − P (A ∩ B).

Here, P (A ∩ B) = P (A | B)P (B). Substituting, we get:


   
10 1 1 7 1
P (A ∪ B) = 10
+ 3− .
5 2 2 2 210

(e) Conditional probability P (B | A): The probability P (B | A) is computed as:

P (A ∩ B)
P (B | A) = ,
P (A)

which can be simplified to:


10 1 1 7 1
 
5 210 + 3 − 2 210
P (B | A) = 10
2 1
.
5 210

2
Problem 2
An unfair coin shows heads with probability p and tails with probability 1 − p. Suppose this coin is flipped
2 times. Let A be the event that the coin comes up heads first and tails second. Let B be the event that
the coin comes up tails first and heads second.
a) Find P (A).

b) Find P (B).
c) Find P (A | A ∪ B).
d) Find P (B | A ∪ B).

(a) P (A) = p(1 − p)


(b) P (B) = (1 − p)p
(c) Firstly easy to see P (A ∪ B) = P (A) + P (B) − P (A ∩ B) = P (A) + P (B) = 2p(1 − p),then

P (A ∩ (A ∪ B))
P (A|A ∪ B) =
P (A ∪ B)
P (A)
=
2p(1 − p)
p(1 − p)
=
2p(1 − p)
1
= .
2
(d)Similarly

P (B ∩ (A ∪ B))
P (B|A ∪ B) =
P (A ∪ B)
P (B)
=
2p(1 − p)
p(1 − p)
=
2p(1 − p)
1
= .
2

3
Problem 3
Suppose that A and B are events in a sample space (S, P ). Prove or disprove:
a) If P (A ∩ B) = 0, then P (A | B) = P (B | A) if and only if P (A) = P (B).
b) If P (A) > 0 and P (B) > 0 but P (A ∩ B) = 0, then P (A | B) = P (B | A). If proven, give an example
of two such events with P (A) ̸= P (B).

(a) This statement is incorrect. Let’s consider an example with coin tosses. Suppose we toss a coin three
times. Let event A represent the outcome where the first toss is heads, and the last two tosses are tails. Let
event B represent the outcome where the first toss is tails, and exactly one of the last two tosses is tails.
In this case, P (A ∩ B) = 0, and we also have P (A | B) = P (B | A) = 0. However:
1
P (A) = ,
23
 
2 1
P (B) = ,
1 23
and clearly P (A) ̸= P (B).
(b) This statement is correct. The probabilities can be directly computed as follows:

P (A ∩ B)
P (A | B) = = 0,
P (B)

P (A ∩ B)
P (B | A) = = 0.
P (A)
Thus, P (A | B) = P (B | A).
The example in (a) is exactly the example we need.

4
Problem 4
A multiple choice exam has four options for each of the problems. Suppose a student has studied enough so
that:
• There is a 50% chance that they know the answer to a problem.
• There is a 25% chance that they can eliminate one of the incorrect answers.

• There is a 25% chance that they don’t know how to solve the problem.
If the student knows the answer to a problem they will answer it correct;y. If they do not know the answer
they will choose randomly from the three or four options.
You want the exam to to accurately measure what the students does and does not know, not how lucky
they can be at guessing answers.

a) Calculate the probability that the student knew to eliminate one option and got the answer correct.
b) Calculate the probability that the student gets the answer correct.

c) Calculate the probability that the student knew how to do the problem given that they got the answer
correct.

Let:

P (K) = 0.5 : Probability the student knows the answer


P (E) = 0.25 : Probability the student can eliminate one
P (G) = 0.25 : Probability the student guesses randomly.

Let C denote the event that the student give a correct answer.
Then P (C|K) = 1. P (C|E) = 13 . P (C|G) = 41 .
(a) We need to find P (E ∩ C).

P (E ∩ C) = P (E) · P (C|E)
1 1
= 0.25 · =
3 12
(b) There are 3 possibilities.
1. They know the answer (K).
2. They eliminate one incorrect option (E).
3. They guess randomly (G).
The total probability P (C) is:

P (C) = P (K) · P (C|K) + P (E) · P (C|E) + P (G) · P (C|G)


1 1
= 0.5 · 1 + 0.25 · + 0.25 ·
3 4
1 1
= 0.5 + +
12 16
24 4 3 31
= + + = .
48 48 48 48
(c) We need to calculate P (K|C), the probability the student knew the answer given that they got it
correct. Use Bayes’ theorem:
P (K ∩ C)
P (K|C) = .
P (C)

5
From the problem, P (K ∩ C) = P (K) · P (C|K), and P (C|K) = 1. Thus:

P (K ∩ C) = 0.5 · 1 = 0.5.
31
Substitute P (C) = 48 :
0.5 0.5 · 48 24
P (K|C) = 31 = = .
48
31 31

6
Problem 5
Provide an alternative proof to Proposition 31.7 using any of the statements in Proposition 31.8.
Proposition (31.7). Let A and B be events in a sample space (S, P ). Then

P (A) + P (B) = P (A ∪ B) + P (A ∩ B) .

Proposition (31.8). Let (S, P ) be a sample space and let A and B be events. We have the following:
(1) If A ∩ B = ∅, then P (A ∪ B) = P (A) + P (B).
(2) P (A ∪ B) ≤ P (A) + P (B).
(3) P (S) = 1.

(4) P (∅) = 0.

(5) P A = 1 − P (A).

We can proceed with the following decomposition of the sets:

A = [A − (A ∩ B)] ∪ (A ∩ B)
B = [B − (A ∩ B)] ∪ (A ∩ B)

Clearly:

[A − (A ∩ B)] ∩ (A ∩ B) = ∅
[B − (A ∩ B)] ∩ (A ∩ B) = ∅

Thus, by Property (1) of Proposition 31.8:

P (A) = P [A − (A ∩ B)] + P (A ∩ B)
P (B) = P [B − (A ∩ B)] + P (A ∩ B)

Since [A − (A ∩ B)] ∩ [B − (A ∩ B)] = ∅, we have:

P (A) + P (B) = P [A − (A ∩ B)] + P (A ∩ B) + P [B − (A ∩ B)] + P (A ∩ B).

Rearranging terms:

P (A) + P (B) = P {[A − (A ∩ B)] ∪ [B − (A ∩ B)]} + P (A ∩ B) + P (A ∩ B).

Now, observe:

[A − (A ∩ B)] ∪ [B − (A ∩ B)] ∩ (A ∩ B) = ∅
[A − (A ∩ B)] ∪ [B − (A ∩ B)] ∪ (A ∩ B) = A ∪ B

Thus:

P (A) + P (B) = P [A − (A ∩ B)] ∪ [B − (A ∩ B)] + P (A ∩ B) + P (A ∩ B)


= P [A − (A ∩ B)] ∪ [B − (A ∩ B)] ∪ (A ∩ B)) + P (A ∩ B)
= P (A ∪ B) + P (A ∩ B)

The proof is complete.

7
Problem 6
Consider the sample space S = {a, b, c} with equal probability for each outcome. Define the random variables
X and Y by the values in the table below.
a b c
X −1 0 1
Y 0 1 0
Check that Var (X + y) = Var (X) + Var (Y ) but that X and Y are not independent.

The sample space is S = {a, b, c}, and each outcome has equal probability:
1
P (a) = P (b) = P (c) = .
3
Compute V ar(X),V ar(Y ) firstly.
Var(X):
X 1 1 1
E[X] = P (s)X(s) = (−1) + (0) + (1) = 0.
3 3 3
s∈S
X 1 1 1
E[X 2 ] = P (s)X(s)2 = ((−1)2 ) + ((0)2 ) + ((1)2 ).
3 3 3
s∈S

1 1 1 2
E[X 2 ] = (1) + (0) + (1) = .
3 3 3 3
2 2
Var(X) = E[X 2 ] − (E[X])2 = − (0)2 = .
3 3
Var(Y ):
X 1 1 1 1
E[Y ] = P (s)Y (s) = (0) + (1) + (0) = .
3 3 3 3
s∈S
X 1 1 1
E[Y 2 ] = P (s)Y (s)2 = ((0)2 ) + ((1)2 ) + ((0)2 ).
3 3 3
s∈S

1 1 1 1
E[Y 2 ] = (0) + (1) + (0) = .
3 3 3 3
 2
1 1 1 1 2
Var(Y ) = E[Y 2 ] − (E[Y ])2 = − = − = .
3 3 3 9 9
Compute the Variance of X + Y
1 1
E[X + Y ] = E[X] + E[Y ] = 0 + = .
3 3

X
E[(X + Y )2 ] = P (s)(X(s) + Y (s))2
s∈S
1 1 1
= · 1 + · 1 + · 1 = 1.
3 3 3
 2
2 1 2 1 8
Var(X + Y ) = E[(X + Y ) ] − (E[X + Y ]) = 1 − =1− = .
3 9 9
Substitute the computed variances:

8
6 2 8
Var(X) + Var(Y ) = + = = Var(X + Y )
9 9 9
Thus:
Var(X + Y ) = Var(X) + Var(Y ).
The joint probabilities P (X = x, Y = y) do not factorize into P (X = x) · P (Y = y) for all pairs (x, y).
For example:
1 1 1
P (X = 0, Y = 1) = P (b) = , P (X = 0) = , P (Y = 1) = .
3 3 3
1 1 1 1
P (X = 0, Y = 1) = ̸= P (X = 0) · P (Y = 1) = · = .
3 3 3 9
Since P (X = 0, Y = 1) ̸= P (X = 0) · P (Y = 1), X and Y are not independent.

9
Problem 7
Suppose we have n identical tiles numbered 1, 2, . . . n in a bag and we draw all of the tiles out, one at a time,
without replacement. Let X be a random variable that gives the number of tiles for which the number on
the tile is larger than the number on the tiles drawn before it.
For example, if n = 4 and we drew the tiles in the order 4, 2, 1, 3, then X = 1 because only the first tile’s
number is larger than all of tile numbers before it. If we drew the tiles in the order 3, 1, 2, 4, then X = 2
because 3 and 4 have numbers larger than all of the ones that came before them.
1 1
Prove that E (X) = 1 + 2 + 3 + · · · + n1 .
Hint: Write X as the sum of simpler random variables.

We express X as the sum of simpler random variables. Define the indicator random variable Yi , which
represents whether the i-th card is larger than all the cards drawn before it:
(
1, if the number on the i-th card is larger than all the numbers on the previously drawn cards,
Yi =
0, otherwise.

Thus, the random variable X can be written as:


n
X
X= Yi .
i=1

In other words, X is the number of cards that satisfy the condition.


The condition for the i-th card to be the largest among the first i cards is that the number on the i-th
card is greater than the numbers on the i − 1 cards drawn before it.
Since the n cards are drawn in a random order, and all orders are equally likely, the probability that the
i-th card is the largest among the first i cards is:
1
P (Yi = 1) = .
i
Therefore:
1
E(Yi ) = P (Yi = 1) = .
i
Using the linearity of expectation:
n
! n n
X X X 1 1 1 1
E(X) = E Yi = E(Yi ) = =1+ + + ··· +
i=1 i=1 i=1
i 2 3 n

10
Problem 8
a) Let (S, P ) be a sample space and let A ⊆ S be an event. Define a random vairable IA whose value at
s ∈ S is (
1 if s ∈ A, and
IA (s) =
0 otherwise.
The random variable IA is called an indicator random variable because its value indicates whether or not
an event occurred.
Prove that E (IA ) = P (A).
b) Let (S, P ) be a sample space and let X : S −→ N be a non-negative-integer-valued random variable. Let
a be a positive integer. Prove that
E (X)
P (X ≥ a) ≤ .
a

(a) Possible value of IA are 0, 1. therefore


E(IA ) = 1 · P (A) + 0 · P (A) = P (A).
(b)
Consider the definition of P (X ≥ a):
X
P (X ≥ a) = P (s).
s∈S,X(s)≥a

The definition of the expectation of X is:


X
E(X) = X(s)P (s).
s∈S

We split this sum into two parts: one for X(s) ≥ a and the other for X(s) < a:
X X
E(X) = X(s)P (s) + X(s)P (s).
s∈S,X(s)≥a s∈S,X(s)<a

For the first term, when X(s) ≥ a, we know X(s) ≥ a. Thus:


X X
X(s)P (s) ≥ a P (s).
s∈S,X(s)≥a s∈S,X(s)≥a

For the second term, we know P (s) ≥ 0, s ≥ 0,


X
X(s)P (s) ≥ 0.
s∈S,X(s)<a

Which implies X
E(X) ≥ a · P (s) + 0.
s∈S,X(s)≥a

Notice that: X
P (s) = P (X ≥ a).
s∈S,X(s)≥a

Thus:
E(X) ≥ a · P (X ≥ a).

E(X)
P (X ≥ a) ≤ .
a

11

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy