Skip to content

Commit

Permalink
[intro_supply_demand] example admonition
Browse files Browse the repository at this point in the history
add two example admonitions
  • Loading branch information
longye-tian committed Aug 2, 2024
1 parent f3d8637 commit 197eb55
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lectures/intro_supply_demand.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ Before we look at the model of supply and demand, it will be helpful to have som

### A discrete example

```{prf:example}
:label: isd_ex_cs
Regarding consumer surplus, suppose that we have a single good and 10 consumers.
These 10 consumers have different preferences; in particular, the amount they would be willing to pay for one unit of the good differs.
Expand All @@ -79,6 +82,7 @@ Suppose that the willingness to pay for each of the 10 consumers is as follows:
| willing to pay | 98 | 72 | 41 | 38 | 29 | 21 | 17 | 12 | 11 | 10 |
(We have ordered consumers by willingness to pay, in descending order.)
```

If $p$ is the price of the good and $w_i$ is the amount that consumer $i$ is willing to pay, then $i$ buys when $w_i \geq p$.

Expand Down Expand Up @@ -253,6 +257,9 @@ Let $v_i$ be the price at which producer $i$ is willing to sell the good.

When the price is $p$, producer surplus for producer $i$ is $\max\{p - v_i, 0\}$.

```{prf:example}
:label: isd_ex_dc
For example, a producer willing to sell at \$10 and selling at price \$20 makes a surplus of \$10.
Total producer surplus is given by
Expand All @@ -273,6 +280,7 @@ p = 2 q^2
$$
The shaded area is the total producer surplus in this continuous model.
```

```{code-cell} ipython3
---
Expand Down

0 comments on commit 197eb55

Please sign in to comment.