The supply and demand function in a market economy