hyunjoopark
← Back to Notes

Energy System Modeling / Concepts

Market Clearing

Created

The market operator matches supply and demand bids so that social welfare is maximal.

  • Supplier ii offers up to Q‾is\overline{Q}^s_i at price PisP^s_i; consumer jj bids up to Q‾jd\overline{Q}^d_j at willingness to pay PjdP^d_j
  • Variables qisq^s_i, qjdq^d_j = accepted quantities

max⁡∑jPjdqjd−∑iPisqiss.t.∑jqjd−∑iqis=0  (λ),0≤qis≤Q‾is  (μ‾i,μ‾i),0≤qjd≤Q‾jd  (ν‾j,ν‾j)\max \sum_j P^d_j q^d_j - \sum_i P^s_i q^s_i \quad \text{s.t.} \quad \sum_j q^d_j - \sum_i q^s_i = 0 \;(\lambda), \quad 0 \le q^s_i \le \overline{Q}^s_i \;(\underline{\mu}_i, \overline{\mu}_i), \quad 0 \le q^d_j \le \overline{Q}^d_j \;(\underline{\nu}_j, \overline{\nu}_j)

  • Social welfare = value for consumers − cost of suppliers = consumer surplus + producer surplus
  • λ\lambda (dual of the balance) = clearing price
  • Inelastic (fixed) demand → qdq^d is a parameter → only min⁡∑iPisqis\min \sum_i P^s_i q^s_i is left = economic dispatch (Shadow Price mini dispatch is this case)

What the KKT says (supplier ii)

Pis−λ−μ‾i+μ‾i=0P^s_i - \lambda - \underline{\mu}_i + \overline{\mu}_i = 0

Price vs bidMultipliersResult
λ<Pis\lambda < P^s_iμ‾i=Pis−λ>0\underline{\mu}_i = P^s_i - \lambda > 0qis=0q^s_i = 0 (out of the money)
λ=Pis\lambda = P^s_iboth 00≤qis≤Q‾is0 \le q^s_i \le \overline{Q}^s_i (marginal supplier)
λ>Pis\lambda > P^s_iμ‾i=λ−Pis>0\overline{\mu}_i = \lambda - P^s_i > 0qis=Q‾isq^s_i = \overline{Q}^s_i (fully accepted)

→ this is the Merit Order: cheapest bids fully accepted, the marginal bid sets λ\lambda, the rest stay out.

Why λ\lambda has no sign condition and no CS

An equality is always binding → λ⋅h=0\lambda \cdot h = 0 holds automatically. Changing its RHS can make the result better or worse → λ\lambda can be negative (negative prices with too much renewable supply).

Links: Mixed Complementarity Problem, KKT Conditions, Shadow Price, Merit Order, Perfect Competition