calculus
posted by MEG .
A long rectangular sheet of metal, 12 inches wide, is to be made into a rain gutter by turning up two sides so that they are perpendicular to the sheet. How many inches should be turned up to give the gutter its greatest capacity?

All we have to consider is the area of the crosssection, since the length is a constant.
let the sides to be turned up at both ends be x inches long
let the remaining base be y inches
2x + y = 12
y = 122x
area = xy = x(122x) = 12x  2x^2
d(area)/dx = 12  4x = 0 for a max of area
4x = 12
x = 3
So the turnups should be 3 inches 
Greatest capacity will be achieved when the area of cross section will be maximum.
Let X be the base ,so (12X)/2 will be the height.
Area= Base x height= X(12X)/2
=(12XX^2)/2
Following the maximum theory, we differentiate the area w.r.t X and equate it to zero.
d/dX of(Area)=(122X)/2 =0
or 6X=0
or X=6 inches(base)
so, height= (126)/2 = 3 inches