Let the side of the box be b, and the height be h, then the volume is:

V = b^2 h,

and the cost is:

C = 4 (b^2) + 3 (4 b h) = 4 b^2 +12 b h = 48

divide through by 4:

b^2 + 3 b h = 12.

So:

h = (12 - b^2)/(3 b)

Hence:

V = b^2 (12 - b^2)/(3 b) = b (12 - b^2)/3 = 4 b - b^3/3

The maximum volule will occur when dV/db=0, or:

dV/db = 4 - b^2 = 0

which has roots b=+/-2. The second derivative test tells us that b=+2

gives a maxima (that is d^2V/db^2<0 at b=2).

So b=2, then as h = (12 - b^2)/(3 b), h = 4/3

RonL