Problem involving many squares and several variables.

Solution 1:

Since this is labeled pre-calculus here is a solution not involving calculus:

\begin{eqnarray} (a+b)^2+(c+d)^2+(e+f)^2&=&a^2+2ab+b^2+c^2+2cd+d^2+e^2+2ef+f^2\\ &=&6+2(3)\\&=&12 \end{eqnarray}

Because of symmetry the maximum will occur when each of $(a+b),\,(c+d)$ and $(e+f)$ equals $2$ so the maximum value of $a+b+c+d+e+f$ is $6$.

Addendum: The symmetry argument.

Suppose we have $p>0$ and

$$ p^2+p^2+p^2=3p^2$$

and for $\alpha\beta\gamma\ne0$

$$ (p+\alpha)^2+(p+\beta)^2+(p+\gamma)^2=3p^2\tag{1}$$

Then we will show that $$ (p+\alpha)+(p+\beta)+(p+\gamma)< p+p+p$$

With a bit of algebra equation (1) becomes$$ \alpha+\beta+\gamma=-\dfrac{\alpha^2+\beta^2+\gamma^2}{2p} $$

So we have that $$ (p+\alpha)+(p+\beta)+(p+\gamma)=3p-\dfrac{\alpha^2+\beta^2+\gamma^2}{2p}<p+p+p $$

Solution 2:

First we can set up the problem as $$\max_{a, b, \dots, f} a+ b +c + d+ e + f $$ s.t. $$ a^2 + b^2 + c^2 + d^2 + e^2 + f^2 + ab + cd + ef = 9$$ and then form the Lagrangian:$$\mathcal{L} = a+ b +c + d+ e + f - \lambda(a^2 + b^2 + c^2 + d^2 + e^2 + f^2 + ab + cd + ef - 9)$$

Which yields the following first order conditions:

$$1 = \lambda(2a + b)$$$$1 = \lambda(2b + a)$$$$1 = \lambda(2c + d)$$$$1 = \lambda(2d + c)$$$$1 = \lambda(2e + f)$$$$1 = \lambda(2f + e)$$

Taking the first two as an example and dividing through yields $$1 = \frac{2a+b}{2b+a} \Rightarrow 2b + a = 2a + b\Rightarrow b = a$$

The same procedure for the others yeilds $c=d$ and $e=f$.

Now, since all the variables are nonnegative and $ab + cd + ef = 3$, it must be that $a=b=c=d=e=f=1$ must be the max. This is the only way to get $x^2 + y^2 + z^2 = 3$ for any nonnegative variables $x,y,z$

Solution 3:

I would formulate the problem as follows:

$\max_{a,b, \cdots, f} a+b+c+d+e+f$ s.t. $a^2+b^2+c^2+d^2+e^2+f^2 = 6$ and $ab+cd+ef = 3$

Then form the Lagrangian $\mathcal{L} = a+b+c+d+e+f -\lambda_1(a^2+b^2+c^2+d^2+e^2+f^2 - 6) -\lambda_2(ab+cd+ef - 3)$

Next set $\frac{\partial \mathcal{L}}{\partial a} = \frac{\partial \mathcal{L}}{\partial b} = \cdots = \frac{\partial \mathcal{L}}{\partial f} = 0$

You will get three identical pairs of equations: one for $a,b$, one for $c,d$ and one for $e,f$.

Just solve one pair (say for $a,b$) and conclude that $a=b$

Then $a=b=c=d=e=f$ follows and the maximum value is $6$