Assuming that rent will always be constant.
C= 250×S+ 7500 for S>0
So 1st, divide the shape into multiple other shapes.
BTW, sorry if I take long I'm trying to draw the lines on the picture.
Then, the area of a triangle in a=bh(1/2) and for trapezoids, it's (1/2(length of base 1+ length of base 2))height, so, do that for the 2 trapeziods, and do that for the triangles. I got 42.
2 x(3 + 2 x x ) = 54
2(3 + 2x)
6+4x=54
4x = 54-6
4x = 48
4x/4 = 48/4
x = 12