This Demonstration graphs the standard perfect competition model and displays the numerical price, cost per unit, optimal quantity, and total profit or loss. You can adjust the price, fixed cost, and marginal cost.

The average total cost is and the marginal cost is (set to the price for optimal quantity ). Price and the cost per unit (based on average total cost) are displayed numerically along the axis.

Total profit or loss—price per unit minus cost per unit times quantity sold—appears as a green (profit) or red (loss) rectangle. Its value is shown on the right.