49
Review of Set Operation The mathematical basis of probability is the theory of sets.

Review of Set Operation The mathematical basis of probability is the theory of sets

Embed Size (px)

Citation preview

Review of Set Operation

• The mathematical basis of probability is the theory of sets.

Review of Set Operation

De Morgan’s Law

Review of Set Operation

Applying Set Theory to Probability

Sample space, Events and Probabilities:• Outcome: an outcome of an experiment is any possible observations of that

experiment.• Sample space: is the finest-grain, mutually exclusive, collectively exhaustive

set of all possible outcomes.• Event: is a set of outcomes of an experiment.• Event Space: is a collectively exhaustive, mutually exclusive set of events.

Set Algebra Probability

Set Event

Universal set Sample space

Element Outcome

Finest-grain: All possible distinguishable outcomes are identified separately

Applying Set Theory to Probability

Example Q: A company has a model of telephone usage. It classifies all calls as L (long),

B (brief). It also observes whether calls carry voice(V ), fax (F), or data(D). The sample space has six outcomes

The probability can be represented in the table

Find the probability of a brief data call(0.08),

and the probability of a long call ? (0.3+0.15+0.12)

Law of Total Probability

Ex

工廠有 4 部機器生產同一產品,令其為機器A1,A2,A3,A4 。各機器出產產品數量各佔總產量之比為 0.4 ,0.3 ,0.2 ,0.1。再令產品為不良品的事件為 B。各部機器產品的不良率分別為0.02,0.05,0.01,0.02試問若隨機抽取一產品,其為不良品的機率為?

ans.所欲求之不良品的機率即為 P(B),且依題目所示可知若隨機抽取一產品,則 P(A1)=0.4, P(A2)=0.3, P(A3)=0.2,P(A4)=0.1, P(B|A1)=0.02, P(B|A2)=0.05,P(B|A3)=0.01,P(B|A4)

=0.02

P(B)=

4

1

)(i

iAP P(B|Ai)

= P(A1)P(B|A1) + P(A2)P(B|A2) + P(A3)P(B|A3) +P(A4)P(B|A4)

=0.40.02+0.30.05+0.20.01+0.10.02

=0.027

ex• 設某工廠甲、乙、丙 3 個車間生產同一種產品,產量依次

占全廠的 45%,35%,20% 。且各車間的次品率依次為4%,2%,5% 。現在從待出廠產品中檢查出 1 個次品,問該產品是由哪個車間生產的可能性大 ?

Ans

• Let A denote the event that product is defected.

• Bi denote the product is product from I-th factory

,,, %)(%)(%)( 203545 321 BPBPBP

,,, %)|(%)|(%)|( 524 321 BAPBAPBAP

)|()()|()()|()()( 332211 BAPBPBAPBPBAPBPAP

514.0035.0

44.045.0

)(

)()|( 1

1

AP

ABPABP

Ans.

200003500203502

2 ..

..)()(

)|( APABP

ABP

286003500502003

3 ..

..)()(

)|( APABP

ABP

Bayes’ Theorem

36

Example of Bayes Theorem• Given:

• A doctor knows that meningitis causes stiff neck 50% of the time• Prior probability of any patient having meningitis is 1/50,000• Prior probability of any patient having stiff neck is 1/20

• If a patient has stiff neck, what’s the probability he/she has meningitis?

0002.020/150000/15.0

)()()|(

)|( SP

MPMSPSMP

ex

•假定用血清蛋白診斷肝癌 , 已知確實患肝癌者被診斷為有肝癌的概率為 0.95. 確實不是患肝癌者被診斷為有肝癌的概率為 0.1 . 假設在所有人中患有肝癌的概率為 0.0004 . 現在有一個人被診斷為患有肝癌,求此人確實為肝癌患者的概率

ANS

• A 表示診斷出被檢查者患有肝癌的事件

• B 表示被檢查者確實患有肝癌的事件。

• P(A|B)=0.95 • P(A|BC)=0.1• P(B)=0.0004 • P (B|A) =

)|()()|()(

)|()()|(

BAPBPBAPBP

BAPBPABP

...).(..

..00380

100004019500004095000040

Ex • Let 1-Bi, i = 1, 2, 3, denote the probability that plane will

be found upon a search of the i-th region when the plane is in that region.

• What is the conditional probability that the plane is in the i-th region given that a search of region 1 is unsuccessful?

Ans.

• Let Ai be the event that the plane is in region i.• Let B be the event that a search of region 1 is unsucessful

,)()|(

)()|(

)(

)()|()|(

1

n

iii

iiiii

APABP

APABP

BP

APABPBAP

P(A1|B ) =(B1 * 1/3 ) /( B1 * 1/3 + 1*1/3 + 1*1/3) = B1 / (B1 + 2)

J = 2, 3 P(Aj |B ) =(1 * 1/3 ) /( B1 * 1/3 + 1*1/3 + 1*1/3) = 1 / (B1 + 2)

Independence

Sequential Experiments and Tree Diagrams