Untitled

mail@pastecode.io avatar
unknown
plain_text
a year ago
674 B
1
Indexable
Never
graph{
    label="Market with Imports"
    d=2

    x_axis {
        label= "Quantity"
    }

    y_axis {
        label= "Price"
    }

    -- Supply Curve
    S(x) = 30 + 0.5x
    plot(S, 0, 80, color=red)

    -- Demand Curve
    D(x) = 100 - x
    plot(D, 0, 80, color=blue)

    -- Supply + Imports Curve
    M = 20
    SplusM(x) = 30 + 0.5x + M
    plot(SplusM, 0, 80, color=green)

    -- Equilibrium Price
    P2 = 55
    dot((0, P2), red)
    dot((0, P2), L="$P_2$")

    -- Equilibrium Quantity
    Q2 = 45
    dot((Q2, 0), blue)
    dot((Q2, 0), L="$Q_2$")

    -- Imports Label
    label.urt("$M$", (45, 80), color=green)
}