#### A metal box with a square base and vertical sides is to contain $1024 cm^3$. The material for the top and bottom costs Rs $5/cm^2$ and the material for the sides costs Rs $2.50/cm^2$. Find the least cost of the box.

Given: A metal box with a square base and vertical sides is to contain $1024 cm^3$. The material for the top and bottom costs Rs $5/cm^2$ and the material for the sides costs Rs $2.50/cm^2$

To find: the minimum cost of the box

.

Take x cm as the side of the square

Take y cm as the vertical side of the metal box

According to the given information in the question, the formula used volume for square base is

V=base × height

Due to its square base, the formula of the volume is

$V=x^2y$
This is equal to $1024 \mathrm{~cm}^{3}$ . So, volume becomes
$\\1024 \mathrm{~cm}^{3}=\mathrm{x}^{2} \mathrm{y}\\ \mathrm{y}=\frac{1024}{\mathrm{x}^{2}} \ldots \ldots (i)$

Then we need to calculate the total area of the metal box.

Area of top and bottom $= 2x\textsuperscript{2}cm\textsuperscript{2}$

The mentioned material for the top and bottom costs Rs $5/cm\textsuperscript{2}$, thus, the material cost for top and bottom becomes

Cost of top and bottom =Rs. 5($2x^2$)

Area of one side of the metal box = xy cm

The total sides present in the metal box are 4, so

Thus, the total area of all the sides of the metal box = 4xy

The cost of the material for sides is Rs $2.50/cm^2$

∴ Cost of all the sides of the metal box =Rs. 2.50(4xy)

The overall area of the metal box will be

$A=2x\textsuperscript{2}+4xy$

This will make the cost of the box to be

$C=5(2x\textsuperscript{2}) + 2.50(4xy)$

Putting the value of y from equation (i) in the above equation,

$\\C=5\left(2 x^{2}\right)+2.50\left(4 x\left(\frac{1024}{x^{2}}\right)\right)\\ \Rightarrow C=10 x^{2}+\frac{10240}{x}$
Both the sides are differentiated with respect to x
$\Rightarrow C^{\prime}=\frac{d\left(10 x^{2}+\frac{10240}{x}\right)}{d x}$
Using differentiation rule of sum, we get
$\Rightarrow C^{\prime}=\frac{d\left(10 x^{2}\right)}{d x}+\frac{d\left(\frac{10240}{x}\right)}{d x}$

$\Rightarrow C^{\prime}=10 \frac{d\left(x^{2}\right)}{d x}+10240 \frac{d\left(x^{-1}\right)}{d x}$
Then using the derivative, we get
$\\\Rightarrow C^{\prime}=10 \times 2 x+10240 \times\left(-x^{-2}\right) \\\Rightarrow C^{\prime}=20 x-\frac{10240}{x^{2}} \ldots (ii)$
Take c=0 to find the minimum value of x by apply second derivative test, so the above equation is equated with 0
$\\20 x-\frac{10240}{x^{2}}=0 \\\\\Rightarrow 20 \mathrm{x}=\frac{10240}{\mathrm{x}^{2}} \\\\\Rightarrow \mathrm{x}^{3}=\frac{10240}{20}$
$\Rightarrow x^{3}=512$
Solving this we get
$\Rightarrow x=8$
Again, differentiating equation (ii) with respect to x,
$\Rightarrow C^{\prime \prime}=\frac{d\left(20 x-\frac{10240}{x^{2}}\right)}{d x}$
Using the differentiation rule of sum,
$\\\Rightarrow C^{\prime \prime}=\frac{d(20 x)}{d x}-\frac{d\left(\frac{10240}{x^{2}}\right)}{d x} \\\Rightarrow \mathrm{C}^{\prime \prime}=20 \frac{\mathrm{d}(\mathrm{x})}{\mathrm{dx}}-10240 \frac{\mathrm{d}\left(\mathrm{x}^{-2}\right)}{\mathrm{dx}} \\\Rightarrow \mathrm{C}^{\prime \prime}=20+20480 \times\left(-\mathrm{x}^{-3}\right) \\\Rightarrow C^{\prime \prime}=20+\frac{20480}{x^{3}}$

At x=8, the above equation becomes,

$\\\Rightarrow\left(C^{\prime \prime}\right)_{x=8}=20+\frac{20480}{(8)^{3}} \\\Rightarrow\left(C^{\prime \prime}\right)_{x=8}=20+\frac{20480}{512}>0$
Now at x=8, $C^{\prime}(8)=0 and C^{\prime \prime}(8)>0$, so as per the second derivative test, x is a point of local minima and $\mathrm{C}(8)$ will be minimum value of C.
Hence least cost becomes
$\\C_{x=8}=10(8)^{2}+\frac{10240}{8} \\\Rightarrow C_{y=8}=640+1280=RS.1920$
Hence the least cost of the metal box is Rs. 1920