foundations of computational agents
The third edition of Artificial Intelligence: foundations of computational agents, Cambridge University Press, 2023 is now available (including full text).
The expected value of a numerical function on worlds is the function’s average value, averaged over all possible worlds.
Let be a function on worlds. could select the value of one of the random variables, it could be the number of bits used to describe the world, or it could be some measure of how much an agent likes the world.
The expected value of , written , with respect to probability is
One special case is if is a proposition, and is the function that has value 1 when is true, and 0 otherwise, then .
In an electrical domain, if is the number of switches broken,
would give the expected number of broken switches given by probability distribution . If the world acted according to the probability distribution , this would give the long-run average number of broken switches. If there were three switches, each with a probability of being broken, the expected number of broken switches is:
where is in the middle two products because there are 3 worlds with 1 switch broken, and 3 worlds with 2 switches broken.
In a manner analogous to the semantic definition of conditional probability, the conditional expected value of conditioned on evidence , written , is
The expected number of broken switches given that light is not lit is given by
This is obtained by averaging the number of broken switches over all of the worlds in which light is not lit.
If a variable is Boolean, with represented as 1 and as 0, the expected value is the probability of the variable. Thus any algorithms for expected values can also be used to compute probabilities, and any theorems about expected values are also directly applicable to probabilities.