Mathematics Assignment Solved Solution Sample

QUESTION

 

1. Consider two events A and B such that Pr(B) = 1/2 and Pr(A) = 1/3. Determine the value ofPr(B ∩ Ac) for each of the following conditions:
• A and B are mutually exclusive.
• A ⊂ B.
• Pr(A ∩ B) = 1/8.
2. A computer password consists of nine characters
• How many different passwords are possible if each character may be any lowercase letter or digit?
• How many different passwords are possible if each character may be any lowercase letter or digit and at least one character must be a digit?
• A computer system requires that passwords contain at least one digit. If 9 characters are generated at random, and each is equally likely to be any of the 26 letters or 10 digits, what is the probability that a valid password will be generated?
3. Let A and B be events with Pr(B) = 0.5, Pr(A ∪ B) = 0.8. What is the value of Pr(A) when A and B are independent?
4. A manufacturing plant has 3 different machines denoted M1, M2 and M3. 20%, 35% and 45% of the production comes from machines M1, M2 and M3 respectively. 3% of the production from M1 is defective, 2% of the production from M2 is defective and 1% of the production from M3 is defective.
• Compute the production of defective items from this manufacturing plant.
• A truck load of items is brought to quality control clerk who randomly selects one item and finds it to be defective. What is the probability that this item was manufactured by machine M2?
5. The return on a one unit investment is found to be a discrete random variable X with probability mass function given by .Find the value of c that makes pX(x) a valid probability mass function.
6. The time to failure (in years) of a certain engine component is a continuous random variableY with cdf given by y > 0.Compute the probability that this component will last at most 6 years.
7. Consider a special 8 sided die with 1 face painted 1, 2 faces painted 2, 3 faces painted 3 and 1 face painted 4 and 1 face painted 5. Assume now that the die is loaded so that the face painted 5 is three times more likely than each of the other faces. The die is rolled and the face observed. Determine the sample space and compute the probability that an odd number appears.
8. A radioactive mass emits particles from time to time. The time between two emissions israndom. Let T represent the time in seconds between two emissions. Assume that the cumulative distribution function of T is given by
• Computer the probability that at least 10 seconds will elapse before the next emission
• Compute the value of Pr(T ∈ [1,2]).
9. Probabilities around the union
• Compute Pr(A ∪ B) if it is given that Pr(A) = 1/3 and Pr(B|Ac) = 1/4.
• Compute Pr(B) if it is given that Pr(A ∪ B) = 2/3 and Pr(Ac|Bc) = 1/3.
10. Two independent events A and B are given, and Pr(B|A ∪ B) = 2/3 and Pr(A|B) = 1/2. Compute Pr(B).

Part II – Computational Exploration
All your answers for the computational section must be typeset. Handwritten answer sheets are NOT acceptable for this section. All the computing outputs must clear, succinct and properly captioned and commented. Failure to properly present will result in loss of points.
1. A system is made up of m independent components connected in series. It is known that each component fails with the same probability θ. Let W denote the event that the system is functional (ie working).

1. Find the expression of pW = Pr[W] the probability of W.
2. Compute the theoretical value of pW when m = 4 and θ = 0.05.
3. Write a piece of R code to compute the empirical value of pW when m = 4 and θ = 0.05.
4. Explore your empirical computations for various values of the number n of replications 100, 1000, etc … and plot your empirical value as a function of n.
5. Comment on the probabilistic law demonstrated by your exploration

2. The code shown below generates a sequence of random coin tosses sequence <- NULL for(i in 1:5) sequence <- c(sequence, sample(c(’H’,’T’),1)) print(sequence)
1. Change the length of the sequence using 4, 5, 7 , 10, 20, 40
2. Comment on how the length of the sequence impact its characteristics.
3. Relate your comment to the definition of probability.

3. The following code depicts an experiment with two fair six-faced dice n <- 10000; f <- 0
for(i in 1:n) f <- f + ifelse((sample(6)[1]==sample(6)[1]),1,0) print(f/n) Roll two dice and compute empirical probability that
1. The first yields an outcome greater than the second
2. The sum of the outcomes is less than 9
3. In each case, compare your empirical probabilities to the theoretical counterparts

4. Consider the following bag U = {b,b,b,b,r,r,r,r,r,r} representing the colors (’b’ for blue, and ’r’ for red) of the toys being distributed at a children’s playground. Suppose that on this occasion, 3 toys are to be drawn randomly from the bag and given away to some of the kids attending.

1. Theoretical computations
• Compute the number of ways in which the three toys can be drawn from the bag without replacement.
• Compute the number of ways in which the three randomly drawn toys will all come out red.
• Compute the number of ways in which the three randomly drawn toys will all come out blue.
• Compute the probability that all the three toys are of the same colors

2. Empirical computations
• Write a piece of R code to empirically compute the estimated probability that all the three toys are of the same colors, using n = 100 as your number of random samples from the bag.
• Using values of n from 100 to 40000, compute various realizations of the estimated probability that all the three toys are of the same colors.
• Plot your estimated probabilities as a function of n and comment on what transpires. Specifically discuss the law at work in the pattern of your plot.

5. Let fX(x) = 3x 2 for 0 < x < 1.
1. Compute Pr[1/5 < X < 3/5] using Monte Carlo as per the R code of session 1
2. Compare your answer to the theoretical answer, and argue in terms of the number of Monte Carlo draws

6. Consider the pdf f(x,y) = kxy where 0 < x < 2 and 0 < y < 2. Use the Monte Carlo approach
described in the R Code of session 1
1. Find Pr[A] = Pr[X > 1]
2. Find Pr[B] = Pr[Y < 1]
3. Find Pr[A ∩ B] = Pr[X > 1 ∩ Y < 1]
4. Find Pr[A|B] = Pr[X > 1|Y < 1]
5. Compare (d) to (a) and Comment use = 10000, 100000, 1000000
6. Compare your results to their theoretical counterparts

Exercise

1. Show that if P(A) = 0 or P(A) = 1, then A is independent of every other event.
2. Show that if A is independent of itself, then P(A) is either 0 or 1.
3. Suppose that A and B are independent events. Show that Ac and Bc are independent events.

Exercise

Consider a collection M1,M2,··· ,Mj,··· ,Mn of n independent messengers given the task to relay an important message from one end to the other. Assume that the message is binary. It is known that all the messengers considered are unfortunately plagued with ugly sin of lying. More specifically, each messenger Mj lies about the message received with a probability p, meaning that Mj will transmit the message received with probability p. Assumed that the initial messenger M0 transmits the message intact with probability 1. We seek to compute the probability that the message goes intact from M0 to the last messenger Mn.
1. Let Ck represent the probability that the message arrives goes from messenger Mk intact, and the express Ck as a function of Ck−1. [Hint: Use the law of total probability, namely P(A) = P(A ∩ B) + P(A ∩ Bc)]
2. Simplify the formula using your knowledge of arithmetic and geometric sequences to express Cn as a function of p and n.
3. Interpret and explain the meaning of p = 1/2.

 

 

ANSWER

 

1. Consider two events A and B such that Pr(B) = 1/2 and Pr(A) = 1/3. Determine the value of Pr(B Ac) for each of the following conditions:

A and B are mutually exclusive.

A B.

Pr(A ∩ B) = 1/8.

Answer:

(a) Pr(B ∩ ) = Pr() + Pr(B)-Pr(B )

= Pr() + Pr(B)-( Pr() + Pr(B)) = 0

= Pr(B ∩ ) = 0

(b) Pr(B ∩ )= Pr( ) =2/3

c) Pr(B ∩ ) = Pr(B)- Pr(A ∩ B)

2. A computer password consists of nine characters

How many different passwords are possible if each character may be any lowercase letter or digit?

How many different passwords are possible if each character may be any lowercase letter or digit and at least one character must be a digit?

A computer system requires that passwords contain at least one digit. If 9 characters are generated at random, and each is equally likely to be any of the 26 letters or 10 digits, what is the probability that a valid password will be generated?

Answer: (A) the possible passwords would be

(B) The different passwords are possible if each character may be any lowercase letter or digit and at least one character must be a digit = .

(C ) = .

 

3. Let A and B be events with Pr(B) = 0.5, Pr(A B) = 0.8. What is the value of Pr(A) when A and B are independent?

 

Answer: , Pr(A B) = Pr(B) + Pr(A)- = Pr(B ∩ A )

0.8 = 0.5 + Pr(A) –(0.8)

Pr(A)= 0.7

4. A manufacturing plant has 3 different machines denoted M1, M2 and M3. 20%, 35% and 45% of the production comes from machines M1, M2 and M3 respectively. 3% of the production from M1 is defective, 2% of the production from M2 is defective and 1% of the production from M3 is defective.

Compute the production of defective items from this manufacturing plant.

A truck load of items is brought to quality control clerk who randomly selects one item and finds it to be defective. What is the probability that this item was manufactured by machine M2?

Answer:

Pr(All defective) = 0.2

In percentage = 1.8 %

b) Pr(M2 defective) =

5.The return on a one unit investment is found to be a discrete random variable X with probability mass function given by

{

Find the value of c that makes pX(x) a valid probability mass function

 

Answer :

C = 1/17

6.

The time to failure (in years) of a certain engine component is a continuous random variableY with cdf given by

F(y) = 1- y > 0

Compute the probability that this component will last at most 6 years.

Answer: probability that this component will last at most 6 years

F(6) – F(0) = 1-

 

7.

Consider a special 8 sided die with 1 face painted 1, 2 faces painted 2, 3 faces painted 3 and 1 face painted 4 and 1 face painted 5. Assume now that the die is loaded so that the face painted 5 is three times more likely than each of the other faces. The die is rolled and the face observed. Determine the sample space and compute the probability that an odd number appears.

 

Answer: sample space ={ 1,2,3,4,5,6,7,8}

Pr (odd) = = = 0.5

8.

A radioactive mass emits particles from time to time. The time between two emissions israndom. Let T represent the time in seconds between two emissions. Assume that the cumulative distribution function of T is given by •

{

{0 , t

Computer the probability that at least 10 seconds will elapse before the next emission

Compute the value of Pr(T [1,2]).

Answer: a) Computer the probability that at least 10 seconds will elapse before the next emission

F(

= (

 

[Pr

b)

apply limits

= 3.351 +2 – (4.09 +1) = 0.261

= 0.261

 

9. Probabilities around the union

Compute Pr(A B) if it is given that Pr(A) = 1/3 and Pr(B|Ac) = 1/4.

Compute Pr(B) if it is given that Pr(A B) = 2/3 and Pr(Ac|Bc) = 1/3.

Answer : by the information

 

= 0.667

Pr(B|) = = Pr(B) = ¼ =0.25

Pr(A B)= Pr(A) + Pr(B) –Pr (

= 0.333+0.25-0.25*0.33 =0.4975

 

b} Pr(Ac|Bc) = =

Pr(B) = 1

 

10.

Two independent events A and B are given, and Pr(B|A B) = 2/3 and Pr(A|B) = 1/2.

Compute Pr(B).

Answer: by the information

Pr(B|A B) =

3

Pr(B)= 2/3

Pr(A)= Pr(A|B)= ½

Part II – Computational Exploration

1. A system is made up of m independent components connected in series. It is known that each component fails with the same probability θ. Let W denote the event that the system is functional (ie working). 1. Find the expression of pW = Pr[W] the probability of W.

2. Compute the theoretical value of pW when m = 4 and θ = 0.05.

3. Write a piece of R code to compute the empirical value of pW when m = 4 and θ = 0.05.

4. Explore your empirical computations for various values of the number n of replications 100, 1000, etc … and plot your empirical value as a function of n.

5. Comment on the probabilistic law demonstrated by your exploration

Answer; 1.

If the components fail or survive independently of one another, then this probability becomes n

P[system failure] = 1 –

Then the probability of survival of all components is given by

P[system survival] = 1-[ 1 –

=

2.

For all components having same probability then

=

2.The code shown below generates a sequence of random coin tosses

sequence <- NULL

for(i in 1:5) sequence <- c(sequence, sample(c(’H’,’T’),1)) print(sequence)

1. Change the length of the sequence using 4, 5, 7 , 10, 20, 40

2. Comment on how the length of the sequence impact its characteristics.

3. Relate your comment to the definition of probability.

Answer:

sequence <- NULL

for(i in 1:5) sequence <- c(sequence, sample(c(’H’,’T’),1))

print(sequence)

for sequence =4

sequence <- NULL

for(i in 1:4) sequence <- c(4, sample(c(’H’,’T’),1))

print(4)

for sequence =5

sequence <- NULL

for(i in 1:5) sequence <- c(5, sample(c(’H’,’T’),1))

print(5)

for sequence =7

sequence <- NULL

for(i in 1:7) sequence <- c(7, sample(c(’H’,’T’),1))

print(7)

for sequence =10

sequence <- NULL

for(i in 1:10) sequence <- c(10, sample(c(’H’,’T’),1))

print(10)

for sequence =20

sequence <- NULL

for(i in 1:20) sequence <- c(20, sample(c(’H’,’T’),1))

print(20)

for sequence =40

sequence <- NULL

for(i in 1:40) sequence <- c(40, sample(c(’H’,’T’),1))

print(40)

B]

The checnge in length afftects the total sequence outcome. Changing length changes the number of sequence occurred.

C] the change in length of sequence may increase or decrease the probability but it will keep it in the value less than 1.

3. The following code depicts an experiment with two fair six-faced dice

n <- 10000; f <- 0

for(i in 1:n) f <- f + ifelse((sample(6)[1]==sample(6)[1]),1,0) print(f/n)

Roll two dice and compute empirical probability that

1. The first yields an outcome greater than the second

2. The sum of the outcomes is less than 9

3. In each case, compare your empirical probabilities to the theoretical counterparts

Answer:

A] The first yields an outcome greater than the second

[p<6]= p[1]+p[2]+p[3]+p[4]+p[5]

= 1/6+1/6+1/6+1/6+1/6= 5/6

B] . The sum of the outcomes is less than 9

P [sum<9]= p[sum=2]+p[sum=3]+p[sum=4]+p[sum=5]+p[sum=6]+p[sum=7]+p[sum=8]

= 1/36+2/36+3/36+4/36+5/36+6/36+2/36+3/36

P[sum<9]=26/36

C] the empirical probabilities gain the same value as the theoretical values of probability.

4. Consider the following bag U = {b,b,b,b,r,r,r,r,r,r} representing the colors (’b’ for blue, and ’r’ for red) of the toys being distributed at a children’s playground. Suppose that on this occasion, 3 toys are to be drawn randomly from the bag and given away to some of the kids attending.

1. Theoretical computations

Compute the number of ways in which the three toys can be drawn from the bag without replacement.

Compute the number of ways in which the three randomly drawn toys will all come out red.

Compute the number of ways in which the three randomly drawn toys will all come out blue.

Compute the probability that all the three toys are of the same colors

2. Empirical computations

Write a piece of R code to empirically compute the estimated probability that all the three toys are of the same colors, using n = 100 as your number of random samples from the bag.

Using values of n from 100 to 40000, compute various realizations of the estimated probability that all the three toys are of the same colors.

Plot your estimated probabilities as a function of n and comment on what transpires. Specifically discuss the law at work in the pattern of your plot

Answer:

1. a) The number of ways in which the three toys can be drawn from the bag without replacement.

 

= 10

b) The number of ways in which the three randomly drawn toys will all come out red.

 

C) The number of ways in which the three randomly drawn toys will all come out blue.

 

d) The probability that all the three toys are of the same colors

2.

a)

comb_with_replacement <- function(n, r){
return( factorial(n + r – 1) / (factorial(r) * factorial(n – 1)) )
}
#have 3 elements, choosing 3
comb_with_replacement(3,3)
#[1] 10

comb_with_replacement(100,3)

ballsample(1:3, size = 100, replace = TRUE, ordered = FALSE)

b)

comb_with_replacement <- function(n, r){
return( factorial(n + r – 1) / (factorial(r) * factorial(n – 1)) )
}
#have 3 elements, choosing 3
comb_with_replacement(3,3)
#[1] 10

comb_with_replacement(100 t0 40000,3)

ballsample(1:3, size = 100 t0 40000, replace = TRUE, ordered = FALSE)

c)

1. Compute Pr[1/5 < X < 3/5] using Monte Carlo as per the R code of session 1

5. Let fX(x) = 3x2 for 0 < x < 1.

1. Compute Pr[1/5 < X < 3/5] using Monte Carlo as per the R code of session 1

2. Compare your answer to the theoretical answer, and argue in terms of the number ofMonte Carlo draws

Answer:

a] =

b]all answers follow the theoretical values of answers.

 

6. Consider the pdf f(x,y) = kxy where 0 < x < 2 and 0 < y < 2. Use the Monte Carlo approach described in the R Code of session 1

1. Find Pr[A] = Pr[X > 1]

2. Find Pr[B] = Pr[Y < 1]

3. Find Pr[A B] = Pr[X > 1 ∩ Y < 1]

4. Find Pr[A|B] = Pr[X > 1|Y < 1]

5. Compare (d) to (a) and Comment use = 10000, 100000, 1000000

6. Compare your results to their theoretical counterparts

6. Consider the pdf f(x,y) = kxy where 0 < x < 2 and 0 < y < 2. Use the Monte Carlo approach described in the R Code of session 1

1. Find Pr[A] = Pr[X > 1]

2. Find Pr[B] = Pr[Y < 1]

3. Find Pr[A B] = Pr[X > 1 ∩ Y < 1]

4. Find Pr[A|B] = Pr[X > 1|Y < 1]

5. Compare (d) to (a) and Comment use = 10000, 100000, 1000000

6. Compare your results to their theoretical counterparts

Answer:

A] dx = 3ky/2

B] = -kx/2

C] Pr[A B] = Pr[X > 1 ∩ Y < 1]= -3k

D] Pr[A|B] = Pr[X > 1|Y < 1]= = 3ky/2

F] all results satisfies the theoretical result.

Exercise

1. Show that if P(A) = 0 or P(A) = 1, then A is independent of every other event.

 

Answer:

Suppose P (A) = 1. Then, 0 ≤ P (B \ A) ≤ P ( ) = 0 and hence P (A ∩ B) = P (B) − P (B \ A) = P (B) = P (B) P (A)=0.

Suppose P (A) = 0. Then, 0 ≤ P (A ∩ B) ≤ P (A) = 0 and hence P (A ∩ B) = 0 = P (A) P (B)

2. Show that if A is independent of itself, then P(A) is either 0 or 1.

 

Answer:

If A is independent of itself, then P (A) = P (A ∩ A) = P (A) P (A)

which implies P (A) is 0 or 1.

For example: The solutions of x = are x = 0 or 1.

 

3. Suppose that A and B are independent events. Show that Ac and Bc are independent events.

 

Answer;

It is known that P(A) + P( ) = 1 ……………………………………………..Identity 1

It is also known that P(A ∩ ) + P( ) = P( ) …………………………..Identity 2

Therefore, we have P(A)*P( ) = [1−P( )]P() = P( )−P( )*P( ) and by Identity 1 and we know

P(A∩ ) = P( )−P( ).

Substituting into the equation P(A∩ ) = P(A)*P( ),

we obtain P( ) − P( ) = P( ) − P( ) * P( ).

Subtracting P( ) from both sides and dividing by (−1)

we obtain P( ) = P( ) * P( ).

It shows that , and are independent.

 

Exercise

Consider a collection M1,M2,··· ,Mj,··· ,Mn of n independent messengers given the task to relay an important message from one end to the other. Assume that the message is binary. It is known that all the messengers considered are unfortunately plagued with ugly sin of lying. More specifically, each messenger Mj lies about the message received with a probability p, meaning that Mj will transmit the message received with probability p. Assumed that the initial messenger M0 transmits the message intact with probability 1. We seek to compute the probability that the message goes intact from M0 to the last messenger Mn.

1. Let Ck represent the probability that the message arrives goes from messenger Mk intact, and the express Ck as a function of Ck−1. [Hint: Use the law of total probability, namely P(A) = P(A B) + P(A Bc)]

2. Simplify the formula using your knowledge of arithmetic and geometric sequences to expressCn as a function of p and n.

3. Interpret and explain the meaning of p = 1/2.

 

 

Answer:

A]

The total probability that the message arrives goes from messenger Mk intact, is

Ck= P(successful sending successful receiving) = P(successful sending ) – P(successful sending )

= p-p*(1-p)

 

Ck-1 =

 

B]

Cn-Cn-1=

Cn= =

C]

at p=1/2

Cn= =1/4

 

 

Looking for best Mathematics Assignment Help. Whatsapp us at +16469488918 or chat with our chat representative showing on lower right corner or order from here. You can also take help from our Live Assignment helper for any exam or live assignment related assistance.