13.1 Representing Knowledge in an Uncertain Domain
Choose random variables and dependencies that capture the structure of the domain. A Bayesian network pairs a directed acyclic graph with a conditional probability table for each variable.
AI · Uncertain knowledge and reasoning
Bayesian networks factor a joint distribution into local conditional probabilities. Evidence can then update beliefs through exact or approximate inference.
Choose random variables and dependencies that capture the structure of the domain. A Bayesian network pairs a directed acyclic graph with a conditional probability table for each variable.
The graph encodes conditional independence: each variable is independent of its non-descendants given its parents. The joint probability is the product of all local conditionals.
Exact inference sums over hidden variables and normalizes. Variable elimination avoids repeated work by combining and summing factors in a chosen order.
Sampling methods estimate answers when exact computation is too expensive; their estimates can improve with more representative samples.
A causal interpretation supports interventions, written do(X=x), which set a variable externally rather than merely observing it. This differs from conditioning on X=x.
Exact enumeration
The graph factors P(R,S,W)=P(R)P(S)P(W|R,S). The displayed probabilities are illustrative; all hidden assignments are summed exactly.
Posterior belief
Let N be the number of binary network variables. Full-joint enumeration checks 2N assignments; evaluating the network factorization takes O(N) per assignment. General time: O(N·2N). Auxiliary space: O(N) to hold or recurse over one assignment (this implementation streams the two loop variables and uses O(1) temporary scalars). For this exact three-node network, the loops inspect four parent assignments, so both runtime and working memory are O(1).
The posterior bar and text are a fixed-size visualization (O(1) UI memory). These bounds are for exact enumeration with finite binary variables and nonzero evidence probability; they are not sampling or variable-elimination bounds.