Before revision:  We extend classical duality results for price-taking firms to a setup with rich heterogeneity, and with limited variation in prices.
After revision:  We extend classical duality results for price-taking firms to a setup with discrete heterogeneity, endogeneity, and limited variation in prices.