גווסמ אל--- quantitative methods 2013 · 2013-07-19 · quantitative methods 2013 1 ......

33
--- מסווג לא--- --- מסווג לא--- Quantitative Methods 2013 1 --- מסווג לא--- 2 Probability as a Numerical Measure of the Likelihood of Occurrence 0 1 0.5 Increasing Likelihood of Occurrence Probability: The event is very unlikely to occur. The occurrence of the event is just as likely as it is unlikely. The event is almost certain to occur. Probability – the chance that an uncertain event will occur (always between 0 and 1)

Upload: dohanh

Post on 16-Jun-2018

214 views

Category:

Documents


0 download

TRANSCRIPT

---לא מסווג--- ---לא מסווג---

Quantitative Methods2013

1

---לא מסווג---

2

Probability as a Numerical Measureof the Likelihood of Occurrence

0 10.5

Increasing Likelihood of Occurrence

Probability:

The eventis veryunlikelyto occur.

The occurrenceof the event isjust as likely asit is unlikely.

The eventis almostcertainto occur.

Probability – the chance that an uncertain event will  occur (always between 0 and 1)

---לא מסווג---

3

Probability Experiments

A probability experiment is an action through which specific results (counts, measurements or responses) are obtained.

Example:

Rolling a die and observing the 

number that is rolled is a 

probability experiment.

The result of a single trial in a probability experiment is the outcome.

---לא מסווג---

4

The set of all possible outcomes for an experiment is the sample space.

Example:

The sample space when rolling a die has six 

outcomes.  

{1, 2, 3, 4, 5, 6}

---לא מסווג---

5

EventsAn event consists of one or more outcomes and is a subset of the sample space.

Example:

A die is rolled.  Event A is rolling an even number.

Events are represented by uppercase letters.

A simple event is an event that consists of a single outcome.

Example:

A die is rolled.  Event A is rolling an even number.  

This is not a simple event because the outcomes of 

event A are {2, 4, 6}.

---לא מסווג---

6

Classical Probability

Classical  (or theoretical) probability is used when each outcome in a sample space is equally likely to occur.

The classical probability for event E is given by

Number of outcomes in event( ) .Total number of outcomes in sample space

P E =

Example:

A die is rolled.  

Find the probability of Event A: rolling a 5. 

---לא מסווג---

7

There is one outcome in Event A: {5}

1 0.1676

≈P(A) =

“Probability of Event A.”

---לא מסווג---

8

Empirical (or statistical) probability is based on observations obtained from probability experiments.  The empirical frequency of an event E is the relative frequency of event E.

Empirical Probability

Frequency of Event ( ) Total frequency

EP E = fn=

Example:

A travel agent determines that in every 50 reservations 

she makes, 12 will be for a cruise.

What is the probability that the next reservation she 

makes will be for a cruise?12 0.2450

=P(cruise) =

---לא מסווג---

9

Subjective Probability

Subjective probability results from intuition, educated guesses, and estimates.  

Example:A business analyst predicts that the probability of a certain union going on strike is 0.15.

---לא מסווג---

10

Law of Large Numbers

As an experiment is repeated over and over, the empirical probability of an event approaches the theoretical (actual) probability of the event.  

Example:

Moshe flips a coin 20 times and gets 3 heads. 

The empirical probability is         

This is not representative of the theoretical probability 

which is

3 .20

1.2

---לא מסווג---

11

As the number of times Moshe tosses the coin 

increases, the law of large numbers indicates that the 

empirical probability will get closer and closer to the 

theoretical probability.

---לא מסווג---

12

Range of Probabilities Rule

The probability of an event E is between 0 and 1, inclusive.

That is 

0 ≤ P(E) ≤ 1.

Impossibleto occur

Certainto occurEven

chance

0.5

Certain

Impossible

0.5

1

0

---לא מסווג---

13

Which of the following  values cannot be the probability of an event?

a) 0.00.b) 0.78.c) 1.25.d) 1.00.

Question:

---לא מסווג---

14

Visualizing Events: Venn Diagrams

The rectangle represents the sample space, which is all of the possible outcomes of the experiment.

The circle labelled as A represents event A.In other words, all of the points within A represent possible ways of achieving the outcome of A.

A

Sample space

---לא מסווג---

15

Complementary Events

The complement of Event A is the set of all outcomes in the sample space that are not included in event A. (Denoted A′ and read “A prime.”)

A A’

P(A) + P (A′ )  = 1

P(A) = 1 – P (A′ ) 

P (A′ )  = 1 – P(A)

---לא מסווג---

16

Example:

There are 5 red chips, 4 blue chips, and 6 white chips in a basket.

Find the probability of randomly selecting a chip that is not blue.

P (selecting a blue chip) 4 0.26715= ≈

P (not selecting a blue chip)  4 111 0.73315 15= − = ≈

---לא מסווג---

17

Mutually Exclusive Events

Two events, A and B, are mutually exclusive if they cannot occur at the same time.

A and B are mutually exclusive.

A B

---לא מסווג---

18

Example:Decide if the two events are mutually exclusive.

Event A: Roll a number less than 3 on a die.     Event 

B: Roll a 4 on a die.

These events cannot happen at the same time, so the events are mutually exclusive.

1;2 4

---לא מסווג---

19

A and B are notmutually exclusive.

A B

Intersection of A and BIntersection of A and B

The intersection of events A and B is the set of allsample points that are in both A and B.

The intersection of events A and B is denoted by(A and B) or (A ∩ B).

---לא מסווג---

20

Joint probability is the probability that two (or more) events will occur simultaneously and denoted by

P (A and B) or P (A ∩ B).

If two events are mutually exclusive, then the probability of them both occurring at the same time is 0. 

---לא מסווג---

21

Example:Decide if the two events are mutually exclusive.

Event A: Select a Jack from a deck of cards.     

Event B: Select a heart from a deck of cards.

Because the card can be a Jack and a heart at the same time, the events are not mutually exclusive.

2♥3♥

4♥5♥

6♥

A♥K♥

Q♥

10♥9♥

8♥

7♥J♠

J♣

J♦

J♥

---לא מסווג---

22

Union of Two Events

The union of events A and B is the event containingall sample points that are in A or B or both.

A B

The union of events A and B is denoted by (A or B) or (A ∪ B).

---לא מסווג---

23

Addition Law

The probability that event A or B will occur is given by

P (A or B) = P (A) + P (B) – P (A and B ).

If events A and B are mutually exclusive, then the rule can be simplified to P (A or B) = P (A) + P (B).

A B

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

---לא מסווג---

24

Example:You roll a die.  Find the probability that you roll a number less than 3 or a 4.

The events are mutually exclusive.

P (roll a number less than 3 or roll a 4)

= P (number is less than 3) + P (4)

2 1 3 0.56 6 6

= + = =

---לא מסווג---

25

Example:A card is randomly selected from a deck of cards.  Find the probability that the card is a Jack or the card is a heart.  

The events are not mutually exclusive because the Jack of hearts can occur in both events.

P (select a Jack or select a heart)

= P (Jack) + P (heart) – P (Jack and hearts)

4 13 152 52 52

= + − 1652

= 0.308≈

---לא מסווג---

26

Conditional Probability

A conditional probability is the probability of an event occurring, given that another event has already occurred.

P (B |A) “Probability of B, given A”

The conditional probability of A given B is denoted by

---לא מסווג---

27

A conditional probability is computed as follows :

( )( | )

( )P A B

P A BP B

∩=

( )( | )

( )P A B

P A BP B

∩=

A B

P(A ∩ B)

B is the “new” sample space

---לא מסווג---

28

Example:There are 5 red chip, 4 blue chips, and 6 white chips in a basket.  

Two chips are randomly selected. 

Find the probability that the second chip is red given that the first chip is blue.  (Assume that the first chip is not replaced.)

Because the first chip is selected and not replaced, there are only 14 chips remaining.

P (selecting a red chip|first chip is blue) 5 0.357

14= ≈

---לא מסווג---

29

Example:100 students were surveyed and asked how many hours a week they spent studying.  The results are in the table below.  Find the probability that a student spends more than 10 hours studying given that the student is a male.

Less then 5 5 to 10

More than 10 Total

Male 11 22 16 49Female 13 24 14 51Total 24 46 30 100

---לא מסווג---

30

Of the cars on a used car lot, 70% have air conditioning (AC) and 40% have a CD player (CD). 

20% of the cars have both.

Example:

What is the probability that a car has a CD player, given that it has AC ?

We want to find   P(CD | AC)

0.28570.7

0.2

P(AC)

AC)andP(CDAC)|P(CD ===

---לא מסווג---

31

Multiplication Rule

The probability that two events, A and B both occur is 

P (A and B) = P (A) ∙ P (B |A). 

---לא מסווג---

32

Example:

P(interest rates will increase) = P(I) = 40%

P(recession given a rate increase) = P(R|I) = 70%

Probability of a recession and an increase in rates:

P(R and I) = P(R|I) × P(I) = 0.7 × 0.4 = 28%

---לא מסווג---

33

Example:

Two cards are selected, without replacement, from a deck.  Find the probability of selecting a diamond, and then selecting a spade.

---לא מסווג---

34

Independent Events

Two events are independent  if the occurrence of one of the events does not affect the probability of the other event. 

Two events A and B are independent if

P (B | A) = P(B) or if P(A|B) = P(A). 

Events that are not independent are dependent.

---לא מסווג---

35

Example: Flipping a fair coin, P(heads) = 50%

The probability of 3 heads in succession is:

0.5 × 0.5 × 0.5 = 0.53 = 0.125 or 12.5%

---לא מסווג---

36

Example:A die is rolled and two coins are tossed.  Find the probability of rolling a 5, and flipping two tails.

P (rolling a 5) =  1 .6

Whether or not the roll is a 5, P (Tail ) =     so the events are independent. 

1 ,2

P (5 and T and T ) = P (5)∙ P (T )∙ P (T ) 

1 1 16 2 2

= ⋅ ⋅

124

= 0.042≈

---לא מסווג---

37

Question:

A gambler in a casino has rolled a five on a singledie three times in a row. What is the probability ofrolling another five on the next roll, assuming it is afair die?

A. 0.001B. 0.167C. 0.500D. 0.200

---לא מסווג---

38

Independence RevisitedThe following four statements are equivalent 

• A and B are independent events • P(A and B) = P(A) * P(B) • P(A|B) = P(A) • P(B|A) = P(B) 

The last two are because if two events are independent, the occurrence of one doesn't change the probability of the occurrence of the other. This means that the probability of B occurring, whether A has happened or not, is simply the probability of B occurring. 

---לא מסווג---

39

Question:

Let A and B be two mutually exclusive events with P(A) = 0.40 and P(B) = 0.20.

Therefore:

A) P(A and B) = 0.B) P(B|A) = 0.20.C) P(A or B) = 0.52.D) P(A and B) = 0.08.

---לא מסווג---

40

An investor has an A‐rated bond, a BB‐rated bond, and a CCC‐rated bond where the probabilities of default over the next three years are 4 percent, 12 percent, and 30 percent, respectively. What is the probability that all of these bonds will default in the next three years if the individual default probabilities are independent?

A) 1.44%.

B) 23.00%.

C) 0.14%.

D) 46.00%.

Question:

---לא מסווג---

41

---לא מסווג---

42

Bayes’ Theorem

Often we begin probability analysis with initial or prior probabilities.

Then we obtain some additional information.

Given this information, we calculate revised orposterior probabilities.

Bayes’ theorem provides the means for revising theprior probabilities.

Thomas Bayes

Prior probabilities Data from test or sample

Bayes’ theorem gives posterior probabilities

---לא מסווג---

43

Consider a manufacturing firm that receives shipmentsof parts from two different suppliers. 

Let A1 denote the event that a part is from supplier 1 and A2 denote the event that a part is from supplier 2. 

Currently, 65% of the parts purchased by the company are from supplier 1 and the remaining 35% are from supplier 2.

Hence, if a part is selected at random, we would assign the prior probabilities

P(A1)=0.65 and P(A2)=0.35.

---לא מסווג---

44

The quality of the purchased parts varies with the source of supply.

If we let G denote the event that a part is good and B denote the event that a part is bad:

P(G | A1) = 0.98 P(B | A1) = 0.02

P(G | A2)  = 0.95 P(B | A2) = 0.05

---לא מסווג---

45

TREE DIAGRAM FOR TWO‐SUPPLIER EXAMPLE

Step 1Supplier

Step 2Condition

ExperimentalOutcome 

(A1 and G)

(A1 and B)

(A2 and G)

(A2 and B)

Note: Step 1 shows that the part comes from one of two suppliers,and step 2 shows whether the part is good or bad.

A1

A2

G

B

G

B

---לא מסווג---

46

Each of the experimental outcomes is the intersection of two events, so we can use the multiplication rule to compute the probabilities. 

For instance,

P(A1 and G) = P(A1)P(G | A1)

---לא מסווג---

47

PROBABILITY TREE FOR TWO‐SUPPLIER EXAMPLE

Step 1Supplier

Step 2Condition

ExperimentalOutcome 

P(A1)=0.65

P(A2)=0.35

P(G|A1)=0.98

P(B|A1)=0.02

P(G|A2)=0.95

P(B|A2)=0.05

P(A1 and G) = P(A1)P(G|A1) =0.637

P(A1 and B) = P(A1)P(B|A1) =0. 0130

P(A2 and G) = P(A2)P(G|A2) =0. 3325

P(A2 and B) = P(A2)P(B|A2) =0. 0175

The process of computing these joint probabilities can be depicted in what is called a probability tree. 

---לא מסווג---

48

Suppose now that the parts from the two suppliers are used in the firm’s manufacturing process and that a machine breaks down because it attempts to process a bad part.

Given the information that the part is bad, what is the probability that it came from supplier 1 and what is the probability that it came from supplier 2? 

With the information in the probability tree, Bayes’ theorem can be used to answer these questions.

---לא מסווג---

49

Letting B denote the event that the part is bad, we are looking for the posterior probabilitiesP(A1|B) and P(A2|B). 

From the law of conditional probability, we know that

)(

)()|( 1

1 BP

BAPBAP

∩=

---לא מסווג---

50

)(

)()|( 1

1 BP

BAPBAP

∩=

---לא מסווג---

51

)(

)()|( 1

1 BP

BAPBAP

∩=

To find P(B), we note that event B can occur in only two ways: (A1 and B) and (A2 and B).

Therefore, we have

)()()( 21 BAPBAPBP ∩+∩=

---לא מסווג---

52

)()()( 21 BAPBAPBP ∩+∩=)|()()|()( 2211 ABPAPABPAP +=

1 11

1 1 2 2

( ) ( )( | )

( ) ( | ) ( ) ( | )

P A P B AP A B

P A P B A P A P B A=

+

2 22

1 1 2 2

( ) ( | )( | )

( ) ( | ) ( ) ( | )

P A P B AP A B

P A P B A P A P B A=

+

---לא מסווג---

53

1 11

1 1 2 2

( ) ( | )( | )

( ) ( | ) ( ) ( | )

0.65 0.02 0.0130.4262

0.65 0.02 0.35 0.05 0.0305

P A P B AP A B

P A P B A P A P B A=

+⋅

= = =⋅ + ⋅

5738.00305.0

0175.0

05.035.002.065.0

05.035.0)|( 2 ==

⋅+⋅⋅

=BAP

Note that in this application we started with a probability of 0.65 that a part selected at random was from supplier 1.

However, given information that the part is bad, the probability that the part is from supplier 1 drops to 0.4262. 

---לא מסווג---

54

NewInformation

Applicationof Bayes’Theorem

PosteriorProbabilities

PriorProbabilities

Bayes’ theorem is used to revise previously calculated probabilities after new information is obtained.

))P(BB|P(A))P(BB|P(A))P(BB|P(A

))P(BB|P(AA)|P(B

k k 2 2 1 1

i i i +++

=K

---לא מסווג---

55

The probability of event A = 0.3The probability of event B = 0.25The probability of (B|A) = 0.5

Using Bayes’ formula, what is P(A|B)?

Question:

Using Bayes’ formula, we can solve for P(A|B):P(A|B) = [ P(B|A) / P(B) ] × P(A)

= [0.5 / 0.25] × 0.3 = 0.60

Answer:

---לא מסווג---

56

Bonds rated B have a 25% chance of default in five years. Bonds rated CCC have a 40% chance of default in five years. A portfolio consists of 30% B and 70% CCC‐rated bonds. If a randomly selected bond defaults in a five‐year period, what is the probability that it was a B‐rated bond?

A) 0.625.B) 0.429.C) 0.211.

D) 0.250.

Question:

---לא מסווג---

57

According to Bayes' formula:

P(B|default) = P(default and B)/P(default).

P(default and B )= P(default/B) × P(B) = 0.250 × 0.300 = 0.075

P(default and CCC) = P(default/CCC) × P(CCC) = 0.400 × 0.700 = 0.280

P(default) = P(default and B) + P(default and CCC) = 0.355

P(B|default) = P(default and B)/P(default) = 0.075 / 0.355 = 0.211

---לא מסווג---

58

APPENDIX

---לא מסווג---

59

Counting Rules

Rules for counting the number of possible outcomes.

Counting Rule 1:If any one of  k  different mutually exclusive and collectively exhaustive events can occur on each of  n  trials, the number of possible outcomes is equal to

kn

---לא מסווג---

60

• Counting Rule 2:– If there are k1 events on the first trial, k2 events on the second trial, … and kn events on the n

th trial, the number of possible outcomes is

– Example:• You want to go to a park, eat at a restaurant, and see a movie.  There are 3 parks, 4 restaurants, and 6 movie choices.  How many different possible combinations are there?

• Answer:  (3)(4)(6) = 72 different possibilities

(k1)(k2)…(kn)

---לא מסווג---

61

• Counting Rule 3:

– The number of ways that n items can be arranged in order is

– Example:

• Your restaurant has five menu choices for lunch.  How many ways can you order them on your menu?

• Answer:  5! = (5)(4)(3)(2)(1) = 120 different possibilities

n! = (n)(n – 1)…(1)

---לא מסווג---

62

• Counting Rule 4:– Permutations: The number of ways of arranging X objects selected from n objects in order is

– Example:• Your restaurant has five menu choices, and three are selected for daily specials.   How many different ways can the specials menu be ordered?

• Answer:   different possibilities

X)!(n

n!Pxn −

=

602

120

3)!(5

5!

X)!(n

n!nPx ==

−=

−=

---לא מסווג---

63

• Counting Rule 5:– Combinations: The number of ways of selecting X objects from n objects, irrespective of order, is

– Example:• Your restaurant has five menu choices, and three are selected for daily specials.   How many different special combinations are there, ignoring the order in which they are selected?

• Answer:  different possibilities

X)!(nX!

n!Cxn −

=

10(6)(2)

120

3)!(53!

5!

X)!(nX!

n!Cxn ==

−=

−=

---לא מסווג---

64

Bayes’ Theorem Example

A drilling company has estimated

a 40% chance of striking oil 

for their new well.

A detailed test has been scheduled for more information.

Historically, 60% of successful wells have had detailed tests, and 20% of unsuccessful wells have had detailed tests.  

Given that this well has been scheduled for a  detailed test, what is the probability  that the well will be successful?

---לא מסווג---

65

Let   S = successful well 

U = unsuccessful well

P(S) = 0.4 , P(U) = 0.6    (prior probabilities)

Define the detailed test event as  D

Conditional probabilities:

P(D|S) = 0.6          P(D|U) = 0.2

Goal is to find   P(S|D)

---לא מסווג---

66

0.6670.120.24

0.24

(0.2)(0.6)(0.6)(0.4)

(0.6)(0.4)

U)P(U)|P(DS)P(S)|P(D

S)P(S)|P(DD)|P(S

=+

=

+=

+=

Apply Bayes’ Theorem:

So the revised probability of success, given that this well has been scheduled for a detailed test, is 0.667