Suppose, to build a box (a rectangular solid) of fixed volume and square base, the cost per square inch of the base and top is twice that of the four sides. Choose dimensions for the box that minimize the cost of building it, if the volume is (say) $2000$ cubic inches.
Here is what I have:
Let $x$ be the length (in.) of a side of the base. Let $h$ be the height (in.). Volume is given by $$V = x^2h = 2000\;.$$ Furthermore let $m$ be the cost (per square in.) of the base and top, and $n$ the cost (per square in.) of the sides. Then total cost, $C$, is given by $$C = m(2x^2) + n(4xh)\;.$$
We also know $$m = 2n\;.$$
To do: Express $C$ in terms of one variable, then use standard elementary calculus techniques to minimize $C$. I am stuck at this point: How do I get $C$ in terms of a single variable? I can substitute $h = 2000/x^2$, and either $m = 2n$ or $n = m/2$, but this leaves $C$ in terms of $x$ and $n$ or $m$.