Piecewise[{{1200, x<40}, {(x-40)*40, 40<=x<55}, {1200 ((x-40)*40) 250, 55<=x}}]