Mathematical programming and economic analysis of the firm an