Skip to content

Opportunity Cost Calculator

Run the Opportunity Cost Calculator MicroSim Fullscreen
Edit in the p5.js Editor

About This MicroSim

This MicroSim helps students understand that the true cost of any decision includes not just the money you spend, but also the value of the next best alternative you give up. Students configure two competing choices (such as going to a movie versus working an extra shift), set parameters like hours, direct cost, and enjoyment level, then click "Calculate" to see an animated breakdown of the true opportunity cost of each option. The sim also computes a "value per dollar" metric so students can compare which choice delivers more satisfaction relative to its full cost.

How to Use

  1. Set your hourly wage using the slider at the bottom of the simulation. This determines the dollar value of your time.
  2. Configure Choice A by adjusting the Hours, Cost, and Fun sliders on the left card. These represent how long the activity takes, its direct dollar cost, and how much you enjoy it on a 1-10 scale.
  3. Configure Choice B by adjusting the same sliders on the right card.
  4. Click "Calculate" to see an animated breakdown showing the direct cost, time value, and true opportunity cost for each choice.
  5. Compare the results at the bottom, which shows the value per dollar for each option and highlights which choice gives more enjoyment per true dollar spent.
  6. Click "Reset" to clear the results and try different combinations.

Iframe Embed Code

You can add this MicroSim to any web page by adding this to your HTML:

<iframe src="https://dmccreary.github.io/economics-course/sims/opportunity-cost-calculator/main.html"
        height="602px"
        width="100%"
        scrolling="no"></iframe>

Lesson Plan

Grade Level

9-12 (High School Economics)

Duration

10-15 minutes

Prerequisites

  • Understanding of basic arithmetic (multiplication, division)
  • Familiarity with the concept of scarcity and the idea that resources (time and money) are limited

Activities

  1. Exploration (5 min): Set the hourly wage to $15 and compare "Go to Movie" (3 hours, $15 cost, 7/10 fun) with "Work Extra Shift" (3 hours, $0 cost, 4/10 fun). Click Calculate and observe how the time value of your hours factors into the true cost of each choice.
  2. Guided Practice (5 min): Change the hourly wage from $10 to $25 and notice how the true cost changes for both options. Discuss with a partner why higher wages make leisure activities more expensive in terms of opportunity cost.
  3. Assessment (5 min): Create your own real-life scenario using two choices you face regularly (such as studying versus playing video games). Set realistic values and explain in writing which choice has the lower opportunity cost and why.

Assessment

  • Students can correctly define opportunity cost as the value of the next best alternative foregone
  • Students can identify both the direct cost and the time-value component of a decision
  • Students can explain why changing the hourly wage affects the opportunity cost of leisure activities

References

  1. Opportunity Cost - Wikipedia - Comprehensive overview of the concept of opportunity cost in economic theory.
  2. Opportunity Cost - Investopedia - Practical explanation with real-world examples of how opportunity cost affects everyday decisions.
  3. Opportunity Cost and Trade-offs - Khan Academy - Lesson connecting opportunity cost to the production possibilities curve.