(Problem 5: Fuzzy Logic)
 
(29 intermediate revisions by 14 users not shown)
Line 1: Line 1:
 +
[[Category:ECE302Fall2008_ProfSanghavi]]
 +
[[Category:probabilities]]
 +
[[Category:ECE302]]
 +
[[Category:homework]]
 +
[[Category:problem solving]]
 +
 
== Instructions ==
 
== Instructions ==
 
Homework 3 can be [https://engineering.purdue.edu/ece302/homeworks/HW3FA08.pdf downloaded here] on the [https://engineering.purdue.edu/ece302/ ECE 302 course website].
 
Homework 3 can be [https://engineering.purdue.edu/ece302/homeworks/HW3FA08.pdf downloaded here] on the [https://engineering.purdue.edu/ece302/ ECE 302 course website].
Line 6: Line 12:
 
http://nostalgia.wikipedia.org/wiki/Monty_Hall_problem
 
http://nostalgia.wikipedia.org/wiki/Monty_Hall_problem
 
Explains the original Monty Hall problem and then the problem considering two contestants are involved.
 
Explains the original Monty Hall problem and then the problem considering two contestants are involved.
 +
 +
Consider the following twist on the monty hall problem (see video above to recollect):
 +
 +
There are 3 doors, behind one of which there is a car, and the remaining two have goats. You and a friend each pick a door. One of you will have definitely picked a goat. The host then opens one of the two chosen doors (i.e. yours or your friend's), shows a goat and kicks that person out (if both of you have chosen goats, he opens one door at random). The other person is given the option of staying put, or switching to the one remaining door.
 +
 +
*(a) When originally picking your doors, should you choose your door first, or let your friend go first? Does it make a difference?
  
 
[[HW3.1.a Zhongtian Wang_ECE302Fall2008sanghavi]]
 
[[HW3.1.a Zhongtian Wang_ECE302Fall2008sanghavi]]
  
 
[[HW3.1.a Shao-Fu Shih_ECE302Fall2008sanghavi]]
 
[[HW3.1.a Shao-Fu Shih_ECE302Fall2008sanghavi]]
 +
 +
[[HW3.1.a Michael Allen_ECE302Fall2008sanghavi]]
  
 
[[HW3.1.a Beau "ballah-fo-life" Morrison_ECE302Fall2008sanghavi]]
 
[[HW3.1.a Beau "ballah-fo-life" Morrison_ECE302Fall2008sanghavi]]
Line 16: Line 30:
  
 
[[HW3.1.a Chris Wacnik_ECE302Fall2008sanghavi]]
 
[[HW3.1.a Chris Wacnik_ECE302Fall2008sanghavi]]
 +
 +
[[HW3.1.a Chris Cadwallader_ECE302Fall2008sanghavi]]
  
 
[[HW3.1.a Dan Van Cleve_ECE302Fall2008sanghavi]]
 
[[HW3.1.a Dan Van Cleve_ECE302Fall2008sanghavi]]
  
 
[[HW3.1.a Joe Gutierrez_ECE302Fall2008sanghavi]]
 
[[HW3.1.a Joe Gutierrez_ECE302Fall2008sanghavi]]
 +
 +
*(b) It turns out that the host has just eliminated your friend. What should you do? (i.e. stick with your original door, or switch?) What are the probabilities of winning in each case?
  
 
[[HW3.1.b Zhongtian Wang & Jonathan Morales_ECE302Fall2008sanghavi]]
 
[[HW3.1.b Zhongtian Wang & Jonathan Morales_ECE302Fall2008sanghavi]]
Line 35: Line 53:
 
[[HW 3.1b Vivek Ravi_ECE302Fall2008sanghavi]]
 
[[HW 3.1b Vivek Ravi_ECE302Fall2008sanghavi]]
  
== Problem 1: Monte Hall, twisted ==
 
 
[[HW3.1.b Anand Gautam_ECE302Fall2008sanghavi]]
 
[[HW3.1.b Anand Gautam_ECE302Fall2008sanghavi]]
This scenario is almost the same like the original problem. Just that your friend is kicked out by the host. The probability of you picking the car if you swap is 2/3 and not swapping is 1/3.
 
  
 
[[HW3.1.b Steve Streeter_ECE302Fall2008sanghavi]]
 
[[HW3.1.b Steve Streeter_ECE302Fall2008sanghavi]]
The best way to look at this part of the problem is to divide it into 3 events.  A: [You-Car,Friend-Goat], B: [You-Goat,Friend-Car], C: [Both picked goats].  From there you can use the condition that your friend was kicked off.  So, for event A, if you switch, P(winning) = 0.  Not switching: P(winning) = 1.  You can determine the probabilities of other events in the same fashion.
 
  
 
[[HW3.1.b Kushagra Kapoor_ECE302Fall2008sanghavi]]
 
[[HW3.1.b Kushagra Kapoor_ECE302Fall2008sanghavi]]
This problem can be divided into 4 parts
 
  
A: P[pick car initially] = 1/3
+
[[HW3.1.b Anthony O'Brien_ECE302Fall2008sanghavi]]
  P[win car without swapping/you picked car initially] = 1/3
+
B: P[pick goat initially] = 2/3
+
  P[win car without swapping/you picked goat initially] = 0
+
C: P[pick goat initially] = 2/3
+
  P[win car after swapping/you picked goat initially] = 2/3
+
D: P[pick car initially] = 1/3
+
  P[win car after swapping/you picked car initially] = 0
+
  
So P[win car without swapping] = 1/3 and P[win car after swapping] = 2/3.
+
[[HW3.1.b Seraj Dosenbach_ECE302Fall2008sanghavi]]
  
[[HW3.1.b Anthony O'Brien_ECE302Fall2008sanghavi]]
+
[[HW3.1b Priyanka Savkar_ECE302Fall2008sanghavi]]
 +
 
 +
[[HW3.1.b Emily Blount_ECE302Fall2008sanghavi]]
  
 
== Problem 2: A Bayesian Proof ==
 
== Problem 2: A Bayesian Proof ==
 +
The theorem of total probability states that <math>P(A) = P(A|C)P(C) + P(A|C^c)P(C^c)</math>.  Show that this result still holds when everything is conditioned on event <math>B</math>, that is, prove that
 +
 +
<math>P(A|B) = P(A|B\cap C)P(C|B) + P(A|B\cap C^c)P(C^c|B).</math>
 +
 +
 
[[HW3.2 - Steve Anderson_ECE302Fall2008sanghavi]]
 
[[HW3.2 - Steve Anderson_ECE302Fall2008sanghavi]]
  
Line 66: Line 80:
  
 
[[HW3.2 Emir Kavurmacioglu_ECE302Fall2008sanghavi]]
 
[[HW3.2 Emir Kavurmacioglu_ECE302Fall2008sanghavi]]
 +
 +
[[HW3.2 Phil Cannon_ECE302Fall2008sanghavi]]
 +
 +
[[HW3.2 Sourabh Ranka_ECE302Fall2008sanghavi]]
  
 
== Problem 3: Internet Outage ==
 
== Problem 3: Internet Outage ==
 +
A certain Internet service provider in a midsize city relies on <math>k</math> separate connections between the city and neighboring cities, to connect its customers to the Internet. Based on past experience, management assumes that a given connection will be down on a given day with probability <math>p = 0.001</math>, independently of what happens on other days or with other connections. Total outage is said to occur if all connections are down on the same day. How large should <math>k</math> be so that the probability total outage occurs at least one day in a year is less than or equal to 0.001?
 +
 
[[HW3.3 Gregory Pajot_ECE302Fall2008sanghavi]]
 
[[HW3.3 Gregory Pajot_ECE302Fall2008sanghavi]]
  
Line 78: Line 98:
 
[[HW3.3 Jayanth Athreya_ECE302Fall2008sanghavi]]
 
[[HW3.3 Jayanth Athreya_ECE302Fall2008sanghavi]]
  
 +
[[HW3.3 Steven Millies_ECE302Fall2008sanghavi]]
 +
 +
[[HW3.3 Carlos Leon_ECE302Fall2008sanghavi]]
 +
 +
[[HW3.3 Ken Pesyna_ECE302Fall2008sanghavi]]
 
== Problem 4: Colored Die==
 
== Problem 4: Colored Die==
 +
There are three dice in a bag. One has one red face, another has two red faces, and the third has three red faces. One of the dice is drawn at random from the bag, each die having an equal chance of being drawn.  The selected die is repeatedly rolled.
 +
 +
*(a) What is the probability that red comes up on the first roll?
 
[[HW3.4.a Seraj Dosenbach_ECE302Fall2008sanghavi]]
 
[[HW3.4.a Seraj Dosenbach_ECE302Fall2008sanghavi]]
  
Line 87: Line 115:
 
[[HW3.4.a Eric Zarowny_ECE302Fall2008sanghavi]]
 
[[HW3.4.a Eric Zarowny_ECE302Fall2008sanghavi]]
  
HW3.1.b Anand Gautam For part a, the chance of drawing each die is independent of the other one. So the probability of red on the first roll is just the product of the chance of drawing a red face on each die. hope that makes sense.
+
[[HW3.4.a Anand Gautam_ECE302Fall2008sanghavi]]
 +
 
 +
[[HW3.4a Jaewoo Choi_ECE302Fall2008sanghavi]]
 +
 
 +
*(b) Given that red comes up on the first roll, what is the conditional probability that red comes up on the second roll?
  
 
[[HW3.4.b Joon Young Kim_ECE302Fall2008sanghavi]]
 
[[HW3.4.b Joon Young Kim_ECE302Fall2008sanghavi]]
Line 93: Line 125:
 
[[HW3.4.b Jared McNealis_ECE302Fall2008sanghavi]]
 
[[HW3.4.b Jared McNealis_ECE302Fall2008sanghavi]]
  
[HW 3.4.c Junzhe Geng]
+
[[HW3.4.b Seraj Dosenbach_ECE302Fall2008sanghavi]]
In this problem, we are asked to find the possibility of selecting a 3-red-face die when the first three rolls all give red faces.
+
 
which is to find      P(3-R-F|3R)
+
*(c) Given that red comes up on the first three rolls, what is the conditional probability that the selected die has red on three faces?
according to formula: P(3-R-F|3R)=P(3-R-F n 3R)/P(3R), P(3-R-F n 3R) is easy to find.
+
 
to find P(3R), we need to calculate each cases: selected 1-R-F(one red face), 2-R-F, or 3-R-F
+
[[HW 3.4.c Junzhe Geng_ECE302Fall2008sanghavi]]
thus,                P(3R)=P(3R n 1-R-F)+P(3R n 2-R-F)+P(3R n 3-R-F)
+
each of those are not hard to find.
+
my final result was 3/4. Hope it is right.
+
  
 
[[HW3.4 Aishwar Sabesan _ECE302Fall2008sanghavi]]
 
[[HW3.4 Aishwar Sabesan _ECE302Fall2008sanghavi]]
Line 106: Line 135:
 
[[HW3.4c AJ Hartnett_ECE302Fall2008sanghavi]]
 
[[HW3.4c AJ Hartnett_ECE302Fall2008sanghavi]]
  
[[HW3.4a Jaewoo Choi_ECE302Fall2008sanghavi]]
+
[[HW3.4c Patrick M. Avery Jr._ECE302Fall2008sanghavi]]
  
 
== Problem 5: Fuzzy Logic ==
 
== Problem 5: Fuzzy Logic ==
 +
As we saw in class, two random bits are independent if knowing the value of one does not change your beliefs about the other. We saw that if <math>A</math> and <math>B</math> are independent and each is equally likely to be 0 or 1, then <math>A</math> XOR <math>B</math> is independent of <math>A</math>. Is the same true if the bits are biased, with the probability of being 1 equal to <math>p</math>?
 +
 +
[[3.5 - Nicholas Browdues_ECE302Fall2008sanghavi]]
 +
 
[[3.5 - Divyanshu Kamboj_ECE302Fall2008sanghavi]]
 
[[3.5 - Divyanshu Kamboj_ECE302Fall2008sanghavi]]
  
Line 122: Line 155:
  
 
[[Monty Hall in Action - Henry Michl_ECE302Fall2008sanghavi]]
 
[[Monty Hall in Action - Henry Michl_ECE302Fall2008sanghavi]]
 +
----
 +
[[Main_Page_ECE302Fall2008sanghavi|Back to ECE302 Fall 2008 Prof. Sanghavi]]

Latest revision as of 11:55, 22 November 2011


Instructions

Homework 3 can be downloaded here on the ECE 302 course website.

Problem 1: Monte Hall, twisted

http://nostalgia.wikipedia.org/wiki/Monty_Hall_problem Explains the original Monty Hall problem and then the problem considering two contestants are involved.

Consider the following twist on the monty hall problem (see video above to recollect):

There are 3 doors, behind one of which there is a car, and the remaining two have goats. You and a friend each pick a door. One of you will have definitely picked a goat. The host then opens one of the two chosen doors (i.e. yours or your friend's), shows a goat and kicks that person out (if both of you have chosen goats, he opens one door at random). The other person is given the option of staying put, or switching to the one remaining door.

  • (a) When originally picking your doors, should you choose your door first, or let your friend go first? Does it make a difference?

HW3.1.a Zhongtian Wang_ECE302Fall2008sanghavi

HW3.1.a Shao-Fu Shih_ECE302Fall2008sanghavi

HW3.1.a Michael Allen_ECE302Fall2008sanghavi

HW3.1.a Beau "ballah-fo-life" Morrison_ECE302Fall2008sanghavi

HW3.1.a Suan-Aik Yeo_ECE302Fall2008sanghavi

HW3.1.a Chris Wacnik_ECE302Fall2008sanghavi

HW3.1.a Chris Cadwallader_ECE302Fall2008sanghavi

HW3.1.a Dan Van Cleve_ECE302Fall2008sanghavi

HW3.1.a Joe Gutierrez_ECE302Fall2008sanghavi

  • (b) It turns out that the host has just eliminated your friend. What should you do? (i.e. stick with your original door, or switch?) What are the probabilities of winning in each case?

HW3.1.b Zhongtian Wang & Jonathan Morales_ECE302Fall2008sanghavi

HW 3.1b Albert Lai_ECE302Fall2008sanghavi

HW3.1.b Spencer Mitchell_ECE302Fall2008sanghavi

HW 3.1b Sahil Khosla_ECE302Fall2008sanghavi

HW 3.1b Virgil Hsieh_ECE302Fall2008sanghavi

HW 3.1b Ben Wurtz_ECE302Fall2008sanghavi

HW 3.1b Vivek Ravi_ECE302Fall2008sanghavi

HW3.1.b Anand Gautam_ECE302Fall2008sanghavi

HW3.1.b Steve Streeter_ECE302Fall2008sanghavi

HW3.1.b Kushagra Kapoor_ECE302Fall2008sanghavi

HW3.1.b Anthony O'Brien_ECE302Fall2008sanghavi

HW3.1.b Seraj Dosenbach_ECE302Fall2008sanghavi

HW3.1b Priyanka Savkar_ECE302Fall2008sanghavi

HW3.1.b Emily Blount_ECE302Fall2008sanghavi

Problem 2: A Bayesian Proof

The theorem of total probability states that $ P(A) = P(A|C)P(C) + P(A|C^c)P(C^c) $. Show that this result still holds when everything is conditioned on event $ B $, that is, prove that

$ P(A|B) = P(A|B\cap C)P(C|B) + P(A|B\cap C^c)P(C^c|B). $


HW3.2 - Steve Anderson_ECE302Fall2008sanghavi

HW3.2 Tiffany Sukwanto_ECE302Fall2008sanghavi

HW3.2 Sang Mo Je_ECE302Fall2008sanghavi

HW3.2 Emir Kavurmacioglu_ECE302Fall2008sanghavi

HW3.2 Phil Cannon_ECE302Fall2008sanghavi

HW3.2 Sourabh Ranka_ECE302Fall2008sanghavi

Problem 3: Internet Outage

A certain Internet service provider in a midsize city relies on $ k $ separate connections between the city and neighboring cities, to connect its customers to the Internet. Based on past experience, management assumes that a given connection will be down on a given day with probability $ p = 0.001 $, independently of what happens on other days or with other connections. Total outage is said to occur if all connections are down on the same day. How large should $ k $ be so that the probability total outage occurs at least one day in a year is less than or equal to 0.001?

HW3.3 Gregory Pajot_ECE302Fall2008sanghavi

HW3.3 Monsu Mathew_ECE302Fall2008sanghavi

HW3.3 Joe Romine_ECE302Fall2008sanghavi

HW3.3 Katie Pekkarinen_ECE302Fall2008sanghavi

HW3.3 Jayanth Athreya_ECE302Fall2008sanghavi

HW3.3 Steven Millies_ECE302Fall2008sanghavi

HW3.3 Carlos Leon_ECE302Fall2008sanghavi

HW3.3 Ken Pesyna_ECE302Fall2008sanghavi

Problem 4: Colored Die

There are three dice in a bag. One has one red face, another has two red faces, and the third has three red faces. One of the dice is drawn at random from the bag, each die having an equal chance of being drawn. The selected die is repeatedly rolled.

  • (a) What is the probability that red comes up on the first roll?

HW3.4.a Seraj Dosenbach_ECE302Fall2008sanghavi

HW3.4.a Shweta Saxena_ECE302Fall2008sanghavi

HW3.4.a Joshua Long_ECE302Fall2008sanghavi

HW3.4.a Eric Zarowny_ECE302Fall2008sanghavi

HW3.4.a Anand Gautam_ECE302Fall2008sanghavi

HW3.4a Jaewoo Choi_ECE302Fall2008sanghavi

  • (b) Given that red comes up on the first roll, what is the conditional probability that red comes up on the second roll?

HW3.4.b Joon Young Kim_ECE302Fall2008sanghavi

HW3.4.b Jared McNealis_ECE302Fall2008sanghavi

HW3.4.b Seraj Dosenbach_ECE302Fall2008sanghavi

  • (c) Given that red comes up on the first three rolls, what is the conditional probability that the selected die has red on three faces?

HW 3.4.c Junzhe Geng_ECE302Fall2008sanghavi

HW3.4 Aishwar Sabesan _ECE302Fall2008sanghavi

HW3.4c AJ Hartnett_ECE302Fall2008sanghavi

HW3.4c Patrick M. Avery Jr._ECE302Fall2008sanghavi

Problem 5: Fuzzy Logic

As we saw in class, two random bits are independent if knowing the value of one does not change your beliefs about the other. We saw that if $ A $ and $ B $ are independent and each is equally likely to be 0 or 1, then $ A $ XOR $ B $ is independent of $ A $. Is the same true if the bits are biased, with the probability of being 1 equal to $ p $?

3.5 - Nicholas Browdues_ECE302Fall2008sanghavi

3.5 - Divyanshu Kamboj_ECE302Fall2008sanghavi

3.5 - Katie Pekkarinen_ECE302Fall2008sanghavi

3.5 - Caleb Ayew-ew_ECE302Fall2008sanghavi

3.5 - Brian Thomas_ECE302Fall2008sanghavi

3.5 - Justin Mauck_ECE302Fall2008sanghavi

Extras

Monty Hall in Action - Henry Michl_ECE302Fall2008sanghavi


Back to ECE302 Fall 2008 Prof. Sanghavi

Alumni Liaison

Questions/answers with a recent ECE grad

Ryne Rayburn