Game Development Reference
In-Depth Information
Looking at the factors in order of decreasing importance, therefore, we find:
time > price > desire
The question we need to answer is, “What is the proportional relationship
between these factors?� To determine this, we can assign coefficients to each of the
three factors so that their respective ratios are reflective of the relative merits of
the factors. Let's say, being the wise AI programmers that we have become by this
point, we decide that the coefficients are as follows:
time
5
price
3
desire
2
As you can see, price is 1.5 times as important as desire but a little more than
half as important as time . Also, time is 2.5 times as important as desire .
With the magnitude established, we can pair them with the individual utility
scores for each of the factors to construct a single formula that takes all three com-
ponents into account.
As we can see, the utility ( U ) is the sum of the three component utility values
( t , p , d ) after weighting them appropriately. By plugging in some sample data, we
can test drive our formula and its weights. We are working with the assumption
that we have calculated the three utility values elsewhere and come away with nor-
malized utilities for each of them.
One important thing to note is that the time values are inversely proportional
to the actual time that it takes to acquire the food. In this case, driving to the steak-
house and waiting for the food is the longest time, so it is the lowest utility.
Microwaving a couple of burritos is the shortest time, giving it the maximum utility
of 1.0. The same pattern exists for price: The steak dinner is the most expensive,
thereby garnering the lowest utility score, and the frozen pizza is the least expensive.
Selection
Time
Price
Desire
Utility
Steak dinner
0.1
0.1
1.0
2.8
Chinese take-out
0.3
0.6
0.3
3.9
Microwave burritos
1.0
0.8
0.3
8.0
Frozen pizza
0.7
1.0
0.5
7.5
 
Search WWH ::




Custom Search