Name: SUID:
AA228/CS238: Decision Making under Uncertainty
Autumn 2019
Prof. Mykel J. Kochenderfer • Durand 255 • email:
MIDTERM 1 Due date: October 15
You have 60 minutes to complete this exam. You may use one page of notes (front and back) but no other resources. All
questions are weighted equally. All answers should be written in dark pencil or pen. Please write your full name and Stanford
email address (SUNet ID) at the top of this page.
Question 1. We have a Bayesian network with four variables. Each variable can take on one of k values (k is the same for all
variables). Draw a network and specify the k that results in exactly 20 independent parameters.
Question 2. A supplier provides spark plugs to us by mail. With probability θ, a spark plug that we order arrives to us broken. The
value of θ is unknown. We have placed three orders, and none of them arrived broken. We want to determine what is the probability
that our next order arrives broken. We can model this problem as a Bayesian network with five nodes: θ, B1, B2, B3, and B4. Let
Bi represent a binary variable indicating whether the ith order arrives broken. We assume that the structure implies Bi⊥Bj | θ for
i 6= j and that we have a uniform prior over θ. Draw the associated Bayesian network and compute the probability the next order is
broken given the information we have. Hint:
∫ 1
0
x4dx = 0.2,
∫ 1
0
x(1− x)3dx = 0.05, and
∫ 1
0
x2(1− x)2dx = 1/30, though you do not
need to necessarily use all of these facts.
1
Question 3. Suppose we are rolling a standard six-sided die, and the outcomes of different rolls are independent of each other.
The probability side i comes up is denoted θi. We roll the die six times, and every single time it comes up 3. We use a Dirichlet
distribution to model our uncertainty over θ. If our posterior ends up being Dir(10, 10, 10, 4, 4, 4), what was our prior?
Question 4. We have a Bayesian network with nodes X1:4 and only two edges X1 → X2 → X3. How many networks are in the
neighborhood?
Question 5. Suppose we have a diagnostic test for a disease. The joint distribution over the outcome of the test T and the presence
of the disease D is as follows:
T D P (T,D)
0 0 0.89
0 1 0.01
1 0 0.02
1 1 0.08
We must decide whether to operate. If we operate, regardless of whether we have the disease, then our utility is −10. If we do
not operate, our utility is −100 when we have the disease and 0 when we do not have the disease. What is the value of information
associated with the diagnostic test? Hint: V OI(O′ | o) =
(∑
o′ P (o
′ | o)EU∗(o, o′)
)
− EU∗(o).
Question 6. Given the payoff matrix below, what is a possible assignment to x and y such that a single pure strategy Nash
equilibrium exists? What actions do the two players take at this pure strategy Nash equilibrium?
Player 2
A B
Player 1 A (1, 1) (0, 0.5)
B (x, 0) (1, y)
2