11
Rushdi Shams, Dept of CSE, KUET, Bangladesh 1 Knowledge Representation Probabilistic Logic Artificial Intelligence Version 2.0

Probabilistic logic

Embed Size (px)

DESCRIPTION

 

Citation preview

Page 1: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 1

Knowledge RepresentationProbabilistic Logic

Artificial IntelligenceVersion 2.0

Page 2: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 2

Conditional ProbabilityDefinition of conditional probability:

P(a | b) = P(a b) / P(b) if P(b) > 0

Product rule gives an alternative formulation:

P(a b) = P(a | b) P(b) = P(b | a) P(a)

Page 3: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 3

Inference with Probability

Page 4: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 4

Inference in ProbabilityP(toothache) =

0.108 + 0.012 + 0.016 + 0.064 = 0.2

Page 5: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 5

Inference in ProbabilityP(cavity V toothache) =

0.108 + 0.012 + 0.072 + .008 + 0.016 + 0.064 = 0.28

Page 6: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 6

Inference in ProbabilityCan also compute conditional probabilities:

Page 7: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 7

Inference in ProbabilityCan also compute conditional probabilities:

Page 8: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 8

Baye’s RuleProduct rule gives an alternative formulation:

P(a b) = P(a | b) P(b) = P(b | a) P(a)

Joining them together, we can find-P(a | b) = P(b | a) P(a)

P(b)

Page 9: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 9

Application of Bayes’ RuleA doctor knows that the disease meningitis causes the patient to have a stiff neck is 50%Means probability of stiff neck given the probability of having meningitis P(s | m) = 0.5He also knows that in every 50000 patients, 1 may have meningitisMeans probability that a patient has meningitisP (m) = 1/50000He also knows that in every 20 patients, 1 may have stiff neckMeans probability that a patient has meningitisP (m) = 1/20Then, from Bayes’ ruleP(m | s) = P(s | m) P(m)

P(s)

Page 10: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 10

Application of Bayes’ RuleP(m | s) = P(s | m) P(m)

P(s)= 0.5 X (1/50000)

1/20= 0.0002

Means he can expect only 1 in 5000 patients with a stiff neck

to have meningitis

Page 11: Probabilistic logic

Rushdi Shams, Dept of CSE, KUET, Bangladesh 11

ReferencesArtificial Intelligence: A Modern Approach

(2nd Edition)by Russell and NorvigChapter 13