The Ambiguity of "Utility"
The term plays an important role in both philosophy and economics. In philosophy, it is associated with Jeremy Bentham and utilitarianism; in that context utility means, roughly, happiness. In Bentham's view, one ought to act so as to maximize the total of human utility, misleadingly described as "the greatest good for the greatest number."
To an economist, on the other hand, your utility function describes not how you should act but how you will act. "The utility to me of consuming an apple is greater than that of consuming an orange" means that, given the choice, I will choose the former over the latter.
We expect people to choose what makes them happy (cynics and psychologists are welcome to leave the conversation at this point, if they feel left out). Hence we would expect at least a close correlation between utility in the economist's sense and utility in the philosopher's sense. That matters, because one of the things economists do, when they are not making a point of being objective, value-free scientists, is to draw conclusions about what people ought to do—for instance, that they ought to abolish tariffs and price controls. Those conclusions frequently depend on the assumption, stated or unstated, that maximizing utility in the economist's sense will also maximize it in the philosopher's sense. That point was probably clearer a little over a century ago when the economic arguments were being made by an economist, Alfred Marshall, who was a utilitarian and not afraid to make explicit the utilitarian foundations of his economic conclusions.
The concept of utility is, however, ambiguous in other and subtler ways. Imagine, for instance, that you are going to die six months from now. Is your utility greater if you have several months advanced warning, as cancer patients often do, or if your death comes as a complete surprise?
Spending several months knowing that you are about to die would be, for most of us, a very unpleasant experience. If utility is another word for happiness, imagined as a characteristic of what is going on inside your head, the second alternative is almost certainly preferable to the first.
But happiness, in that sense, is not all that matters to people. If one could somehow choose in advance whether, when and if you were in the situation described, it would be the first alternative or the second, many of us would choose the first. Many of us, after all, have things we would like to get done before dying—things to be said to children, wife, friends, perhaps enemies as well. Projects to be completed whose completion matters, if only to our sense of having lived a life worth living. Arrangements to be made for the future of those dear to us. A close friend, not all that long ago, spent a good deal of his last few months reducing to something more like order his crowded and cluttered house for the benefit of his wife and daughters.
For a different slant on the same problem, consider the experience machine, as hypothesized by Robert Nozick—or the real world equivalent in which I spend a good many hours a week, now that virtual reality is really here. Nozick's version provides you with the illusion of a life—the entire rest of your life, stretched out over the length of time it would actually occupy. The proprietor has somehow determined the life you are going to live and believably guarantees you a modest improvement, an illusory life in which things turn out marginally better, in a variety of dimensions, than they would have in the real thing. Assuming you believe him, do you accept the offer?
If the economist's utility and the philosopher's are the same, if choice is entirely about happiness, and if happiness is really a state of mind, then the answer is obviously "yes." For me and, I suspect, many other people, it is just as obviously "no." I don't merely want the illusion of accomplishing things, I want the reality.
Which is one reason why I don't spend all of my life in World of Warcraft.