Non-Fiction, Student's Shortcut, Consumer Theory

Consumer Theory Excel eBook

Calculate utility maximization, budget constraints

by Fountain Morgan

  • English
  • 137 pages
  • 2026
  • SamEnrico

Calculate utility maximization, budget constraints, and indifference curves using Excel.

Formats

Free sample

Chapter 1: The Invisible Line...--–- Economics textbooks have a dirty little secret. They spend hundreds of pages describing how consumers make optimal choices, but they rarely show you how to actually calculate those choices. You learn about budget constraints as abstract equations, indifference curves as theoretical constructs, and utility maximization as a calculus problem solved on the back of an envelope. Then you graduate, open Excel, and realize that nobody ever taught you how to model a consumer's decision in a spreadsheet. This book fixes that gap.

Welcome to the world where economic theory meets computational practice.The Problem with Pencil-and-Paper Economics Every intermediate microeconomics course teaches the budget constraint. The professor writes on the board:Px X+Py Y=IP_x X + P_y Y = IPx​X+Py​Y=IYou learn that this line represents all affordable combinations of two goods. You calculate intercepts: I/Px I/P_x I/Px​ and I/Py I/P_y I/Py​. You compute the slope: −Px/Py-P_x/P_y−Px​/Py​. You pass the exam.

Then you close the textbook and never touch the budget constraint again because solving it manually for every price change, income shift, or policy intervention is tedious and error-prone.Here is the truth that working economists know but textbooks rarely emphasize: the budget constraint is not an equation to be solved; it is a model to be built. And the best place to build it is in Excel.Excel forces you to make the budget constraint explicit, dynamic, and reusable. Change one number—the price of coffee, your monthly income, a new tax rate—and the entire feasible set updates instantly. You can see the line pivot, shift, and rotate in real time. This visual immediacy transforms the budget constraint from a static formula into a living analytical tool.By the end of this chapter, you will have built exactly such a tool.

You will understand the budget constraint not as abstract algebra but as an interactive frontier that maps the boundary between possibility and impossibility. More importantly, you will have developed a spreadsheet that serves as the foundation for every model in this book.What the Budget Constraint Really Means Before we open Excel, let us establish a clear conceptual foundation. The budget constraint answers a deceptively simple question: given your income and the prices of two goods, which combinations of those goods can you afford?The Equation and Its Components The standard form is:Px X+Py Y=IP_x X + P_y Y = IPx​X+Py​Y=IWhere:Px P_x Px​ = price of Good X (say, coffee at $4 per cup)Py P_y Py​ = price of Good Y (say, tea at $3 per cup)III = your income (say, $120 per week)XXX = quantity of coffee YYY = quantity of tea The equation says: total spending on coffee plus total spending on tea equals your total income. You cannot spend more than III. You can spend less, but the budget constraint typically assumes you spend all your income because saving is treated as consumption of a "future goods" (a topic we will cover in Chapter 11).The Intercepts Tell a Story The X-intercept is what happens when you spend your entire income on coffee and zero on tea:Xmax=IPx=1204=30 cups X_{max} = \frac{I}{P_x} = \frac{120}{4} = 30 \text{ cups}Xmax​=Px​I​=4120​=30 cups The Y-intercept is the opposite extreme:Ymax=IPy=1203=40 cups Y_{max} = \frac{I}{P_y} = \frac{120}{3} = 40 \text{ cups}Ymax​=Py​I​=3120​=40 cups These two points are the extremes of possibility.

Every affordable combination lies on the straight line connecting them.The Slope Is Opportunity Cost The slope of the budget line is:Slope=−Px Py=−43≈−1.333\text{Slope} = -\frac{P_x}{P_y} = -\frac{4}{3} \approx -1.333Slope=−Py​Px​​=−34​≈−1.333This negative slope has a profound economic meaning: to consume one more cup of coffee, you must give up Px/Py P_x/P_y Px​/Py​ cups of tea. In this case, each additional coffee costs you 1.33 cups of tea that you cannot buy. This trade-off is the opportunity cost of coffee in terms of tea.Many students memorize the slope formula but miss its intuition. Let me give you a concrete example. Suppose you are at the point (15 cups of coffee, 20 cups of tea).

If you want one more coffee (moving to 16 cups), your total spending on coffee rises by 4.Tostaywithinyour4. To stay within your 4.Tostaywithinyour120 budget, you must reduce tea spending by $4, which means buying 4/3=1.334/3 = 1.334/3=1.33 fewer cups of tea. Your new tea quantity becomes 18.67 cups. The slope of -1.33 exactly captures this trade-off.The Numeraire Shortcut Here is a trick that professional economists use constantly: set the price of one good equal to 1. This good becomes the numeraire—the unit of account against which all other prices are measured.If we set Py=1P_y = 1Py​=1, then the budget constraint becomes:Px X+Y=IP_x X + Y = IPx​X+Y=INow the price of XXX is measured in units of YYY.

For example, if Px=4P_x = 4Px​=4 and Py=1P_y = 1Py​=1, one coffee costs four teas. The slope simplifies to −Px-P_x−Px​. The Y-intercept is still III. The X-intercept becomes I/Px I/P_x I/Px​.Why use a numeraire? Because it reduces the number of parameters in your model.

You only need to track relative prices, not absolute prices. This simplification is especially useful when building Excel models because it reduces the number of input cells and makes sensitivity analysis cleaner. We will revisit the numeraire concept in Chapter 11 when we model labor-leisure decisions.The Initial Endowment: A Different Starting Point Most budget constraint discussions assume you start with cash income. But in many economic contexts—especially labor supply (Chapter 11) and international trade—you start with an initial endowment of goods rather than cash.Suppose you initially own 10 cups of coffee and 20 cups of tea. Your endowment point is E=(10,20)E = (10, 20)E=(10,20).

You can sell goods at market prices to buy other goods. Your budget constraint becomes:Px X+Py Y=Px Xˉ+Py YˉP_x X + P_y Y = P_x \bar{X} + P_y \bar{Y}Px​X+Py​Y=Px​Xˉ+Py​YˉThe right side is the market value of your endowment. You are not constrained by cash income but by what you can trade. This formulation is critical for understanding labor supply (you start with 24 hours of time) and welfare economics (initial allocations matter for efficiency).For now, we will stick with the simpler cash income formulation. We introduce the endowment here only to avoid confusion later when you see it in Chapter 11.

When we say "endowment" in this book, we mean initial allocation of goods or time—not the behavioral economics concept of loss aversion. That distinction matters, and we will respect it throughout.Building Your First Budget Constraint in Excel Now we move from theory to practice. Open a new Excel workbook. We will build a budget constraint that responds instantly to changes in prices and income.Step 1: Set Up Your Input Cells In cells B2 through B4, enter the following labels and values:Cell Label Initial Value B2Price of X (Px)4B3Price of Y (Py)3B4Income (I)120These are…

This is the end of the free sample. Get the eBook to keep going. Buy now

About this book

Calculate utility maximization, budget constraints, and indifference curves using Excel.

Details

Author
Fountain Morgan
Publisher
SamEnrico
Language
English
Genre
Non-Fiction, Student's Shortcut, Consumer Theory
Released
2026-05-30
Pages (approx.)
137
Available as
eBook, Audiobook

Read better in the ZLOADR app

Your eBooks on your phone or tablet. Sign in with your SamEnrico account and start reading.

More by Fountain Morgan

See all

You may also like

See all