Skip to content

Add price-control gap properties#167

Draft
alexanderthclark wants to merge 1 commit into
mainfrom
codex/add-price-control-gaps
Draft

Add price-control gap properties#167
alexanderthclark wants to merge 1 commit into
mainfrom
codex/add-price-control-gaps

Conversation

@alexanderthclark
Copy link
Copy Markdown
Owner

Summary

  • Add first-class market gap properties to Equilibrium/Market for Econ 101 price-control analysis.
  • Expose quantity demanded, quantity supplied, shortage, and excess-supply surplus at the relevant market price.
  • Add compatibility aliases for excess_demand_quantity and excess_supply.
  • Update the price-controls tutorial to use the new properties instead of manually computing gaps from the curves.

Behavior

  • Binding ceilings still trade at quantity supplied and now expose the resulting shortage.
  • Binding floors still trade at quantity demanded and now expose the resulting surplus.
  • Non-binding controls and free-market equilibria return zero shortage and zero surplus.
  • Welfare properties such as consumer_surplus, producer_surplus, and total_surplus are unchanged.

Validation

  • pytest -q tests/test_equilibrium.py passed: 7 passed, 1 warning.
  • pytest -q passed: 140 passed, 2 warnings.

Notes

This PR intentionally avoids plotting changes, notebook regeneration, docs build artifacts, and version changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant