# Lagrange multiplers question

1. Jul 21, 2010

### Gekko

f(x,y,z)=4x^2+4y^2+z^2 subject to x^2+y^2+z^z=1

So I have:

F(x,y,z,c) = 4x^2+4y^2+z^2+L(x^2+y^2+z^2-1)

dF/dx = 8x+2xL
dF/dy = 8y+2yL
dF/dz=2z+2zL

Either x=y=0 and L=-1 OR z=0 and L=-4

For first case, z^2=1 therefore z=+/- 1 giving f(0,0,1)=1
For second case, x^2+y^2=1 2x^2=1 x=y=+/-sqrt(1/2) giving f(sqrt(1/2),sqrt(1/2),0)=4

Is this correct?
The minimum is therefore the first case giving f(0,0,1)=1?

Last edited: Jul 21, 2010
2. Jul 21, 2010

### rhit2013

Yup, it all looks right to me.

3. Jul 21, 2010

### Gekko

Does that mean both cases are valid? One is the maximum and one is the minimum?

4. Jul 21, 2010

### epenguin

I'm assuming
is typo for
x^2+y^2+z^2 = 1.

Without using Lagrange you could subtract x^2+y^2+z^2=1 from f(x,y,z)=4x^2+4y^2+z^2 giving you 3(x2 + y2) = f - 1. As this LHS contains only squares it cannot be less than 0. Which is f=1. That is your minimum.

For the maximum looking at the form of f and your constraint you see that so to speak, x, y and z contribute indifferently to your constraint, but taking stuff away from z and investing it in x or y yields you more f. So z=0 will maximise f. The constraint is a sphere round the origin, but the the maximum of f is along a circle z=0, x2 + y2 = 1.
I think it is everywhere along that circle. From this you still get the maximum of f=4, but if I am not mistaken :uhh: your answer is not unique but all points satisfying this x2 + y2 = 1 are solutions to the maximum problem.

It is necessary to know the Lagrange method but surprisingly often you can solve problems without it - use the constraint to solve or simplify your problem and use symmetry between variables.

5. Jul 21, 2010