Maximisation and minimisation of sum of squares, if sum is equal to 15

94 Views Asked by At

Find the numbers whose sum is $15$ and sum of squares is minimum My answer:

Let the numbers be $x$ and $15-x$. Then $$y=x^2+625-30x+x^2$$ $$=2x^2-30x+625$$ $$dy/dx=0$$ $$4x-30=0$$ $$X=7.5$$ Did I go wrong?

2

There are 2 best solutions below

0
On

Okay, so the two numbers would be $x$ and $15-x$.
Now we want to minimize the sum of squares, so lets make a function $$f(x)=x^2+(15-x)^2$$ We take the derivative of it, $$f'(x)=2x-2(15-x)$$ Lets equate it to $0$, $$2x=2(15-x)$$ $$x=\frac{15}2=7.5$$ You are right till here. You forgot to do the second derivative test.
At $x=7.5$, $$f''(7.5)=2+2=4$$ It means that it is a minimum. Thus, $7.5$ and $7.5$ are the required numbers.

0
On

Approach without using calculus:

Geometric viewpoint. This is the same as finding the point on the line $x+y=15$ which is closest to the origin/farthest from the origin. If you draw the picture, you can see that the point with coordinates $x=y=15/2$ is closest to the origin. (It lies on the perpendicular line $x=y$.) The distance from the origin can be arbitrarily large, so there is no maximum. If you have restriction that $x,y\ge0$, then the maximum is attained for $(x,y)=(0,15)$ and $(x,y)=(15,0)$.

Inequalities. We know from the inequality between quadratic mean and arithmetic mean that for $x,y\ge0$ we have $$\sqrt{\frac{x^2+y^2}2}\ge\frac{x+y}2$$ which can be simplified to $$x^2+y^2\ge 2\left(\frac{x+y}2\right)^2.$$

For two variables this can be derived even easier: $$ \begin{align*} (x-y)^2&\ge0\\ x^2-2xy+y^2\ge0\\ x^2+y^2&\ge2xy\\ 2x^2+2y^2 &\ge x^2+2xy+y^2\\ 2x^2+2y^2 &\ge (x+y)^2\\ x^2+y^2 &\ge \frac12(x+y)^2\\ \end{align*} $$