The utility is an economist’s way of measuring pleasure or happiness with a product, service, or labor and how it relates to the decisions that people make in purchasing or performing it. Utility measures the benefits (or drawbacks) from consuming a good or service or from work, and although utility is not directly measurable, it can be inferred from the decisions that people make. In economics, marginal utility is usually described by a function, such as the exponential utility function. In measuring the utility of a certain good, service, or labor, economics use either expected or indirect utility to express the amount of pleasure from consuming or purchasing an object. Expected utility refers to the utility of an agent facing uncertainty and is calculated by considering possible state and constructing a weighted average of utility. These weights are therein determined by the probability of each state given the agent’s estimate. Expected utility is applied in any situation where the outcome of using the good or service or working is deemed a risk for the consumer. Essentially, it is hypothesized that the human decider may not always choose the higher expected value investment option. Such is the case in the example of being guaranteed a $1 payment or gambling for a $100 payment with a probability of reward at 1 in 80, otherwise getting nothing. This results in an expected value of $1.25. According to the expected utility theory, a person may be so risk averse they will still choose the less valuable guarantee rather than gambling for the $1.25 expected value. For this purpose, the indirect utility is very much like a total utility, calculated via a function using variables of price, supply, and availability. It creates a utility curve to define and graph the subconscious and conscious factors that determine customer product valuation. The calculation relies on a function of variables like the availability of goods in the market (which is its maximum point) against a person’s income versus a change in the price of goods. Though usually, consumers think of their preferences in terms of consumption rather than price. In terms of microeconomics, the indirect utility function is the inverse of the expenditure function (when the price is kept constant), whereby the expenditure function determines the minimum amount of money a person must spend to receive any amount of utility from a good. After you determine both of these functions, you can then determine the marginal utility of a good or service because marginal utility is defined as the utility gained from consuming one additional unit. Basically, the marginal utility is a way for economists to determine how much of a product consumers will buy. Applying this to economic theory relies on the law of diminishing marginal utility which states that each subsequent unit of product or good consumed will diminish in value. In practical application, that would mean that once a consumer has used a single unit of a good, such as a slice of pizza, the next unit would have less utility.