3
$\begingroup$

The question is: Using Lagrange multipliers, which point on the sphere, $x^2+y^2+(z-4)^2=1$, is closest to the origin, $(0,0,0)$?

I decided to minimize the distance function squared: $$f(x,y,z)=x^2+y^2+z^2$$

I determined the constraint to be $$g(x,y,z)=x^2+y^2+(z-4)^2-1=0$$ I found that $$\nabla f = 2x\hat{i} + 2y\hat{j}+ 2z\hat{k}$$ $$\nabla g = 2x\hat{i} + 2y\hat{j}+ 2(z-4)\hat{k}$$ Plugging these into $\nabla f=\lambda\nabla g$, I found these relationships: $$2x=2\lambda x$$ $$2y=2\lambda y$$ $$2z=2\lambda (z-4)$$

Simplifying these relationships, I get $$1=\lambda$$ $$1=\lambda$$ $$z=\lambda (z-4)$$ These relationships don't work out, since plugging $\lambda =1$ into $z=\lambda z-4$ yields $0=-4$ which simply isn't true.

I know conceptually that I have a sphere of radius $1$ that is $4$ units above the $z$-axis which means that the closest distance should be at a point where $z=3$. I have also entered “minimize $f(x,y,z)=x^{2}+y^{2}+z^{2}$ with constraint $x^{2}+y^{2}+(z-4)^{2}-1=0$” into WolframAlpha, and this proved my conceptualization. However, I can’t seem to figure out how to mathematically prove this. Any help is appreciated. Thank you!

[Edit] Simplifying these relationships, I get

$$1=\lambda \text{ or } x = 0$$ $$1=\lambda \text{ or } y = 0$$ $$z=\lambda (z-4)$$

$\endgroup$
  • $\begingroup$ Without LM it's much more easier. $\endgroup$ – Michael Rozenberg Oct 12 '18 at 6:07
  • $\begingroup$ I understand that...This was a question given by a math professor who specifically requires the use of LM $\endgroup$ – Nold Oct 12 '18 at 6:07
  • $\begingroup$ Hint: Find another solution of $2x=2\lambda x$. $\endgroup$ – amd Oct 12 '18 at 6:11
  • $\begingroup$ @amd Hi, how do I find another solution? $\endgroup$ – Nold Oct 12 '18 at 6:16
  • $\begingroup$ Suppose $\lambda=2$. Is there some value of $x$ that satisfies the equation? $\endgroup$ – amd Oct 12 '18 at 6:17
1
$\begingroup$

Your simplifications are wrong. From the equality $2x=2\lambda x$, what you get is that $\lambda=1$ or that $x=0$. For the same reason, $\lambda=1$ or $y=0$.

$\endgroup$
  • $\begingroup$ Ah ok that makes sense, but if I deduce that $x=0$ and $y=0$, how would that be useful for determining $z$? $\endgroup$ – Nold Oct 12 '18 at 6:24
  • 1
    $\begingroup$ You already know that $\lambda=1$ is not a possibility. Therefore, $x=y=0$. And so $(x,y,z)=(0,0,5)$ or $(x,y,z)=(0,0,3)$. Which of these points is closest to the origin? $\endgroup$ – José Carlos Santos Oct 12 '18 at 6:35
  • $\begingroup$ Thanks! In my head I was thinking that I have to use the last relationship, but that's totally not the case. $\endgroup$ – Nold Oct 12 '18 at 6:38
1
$\begingroup$

Alternative solution:

In spherical coordinates around the origin $(0,0,4)$, you minimize

$$\sqrt{\cos^2\phi\sin^2\theta+\sin^2\phi\sin^2\theta+(\cos\theta+4)^2}=\sqrt{8\cos\theta+17}.$$

The minimum is $3$ (and the maximum $5$).

$\endgroup$
0
$\begingroup$

You could also have avoided this confusion - indeed, Lagrange multipliers altogether - by noting that minimising $x^2+y^2+z^2$ subject to minimising $x^2+y^2+z^2-8z+15=0$ is equivalent to minimising $8z-15$ (or, indeed, $z$) subject to that constraint. Since $$x^2+y^2+(z-4)^2=1\implies (z-4)^2\le1\implies z\ge 3,$$the solution must use $z=3$ so $x=y=0$.

$\endgroup$
0
$\begingroup$

If $\lambda=1$, the last relationship would yield $0=-4$, so we will deduce $x=0$ and $y=0$ instead. Since we don't know what lambda is, we will have to use the constraint to solve for z.
Rearraging the constraint to find z, we get $$z=\sqrt{1-x^2-y^2}+4$$ Plugging in $x=0$ and $y=0$, we get $$z=\pm\sqrt{1}+4$$ $$z=3,5$$ So, the possible solutions are $$(0,0,3) \text{ or } (0,0,5)$$ $(0,0,3)$ is correct since it is closest to the origin.

$\endgroup$
  • $\begingroup$ Thank you everyone for helping me out here! $\endgroup$ – Nold Oct 12 '18 at 6:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.