Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

When I solve for the point in $y = \sqrt{x}$ closest to the origin using calculus, I get $x = -1/2$. And this is the case for ALL functions $y = \sqrt{x + c}$ using the distance formula $d^2 = x^2 + y^2$.

Why is it that the extreme point is somewhere the function is not even defined? Obviously (at least to me), isn't the closest point to the origin (0, 0)?

EDIT:

Solution:

We want the nearest distance from the origin to some point P in the function $y = \sqrt{x}$. We can use $d^2 = (x2 - x1)^2 + (y2 - y1)^2$ as the optimization function with the constraint that the other point (say, (x2, y2)) be on the curve $y = \sqrt{x}$. We set the other point, say (x1, y1), to the origin and be (0, 0).

When you put them all together, you get $d^2 = (x - 0)^2 + (\sqrt{x} - 0)^2 = x^2 + x$. You get the derivative of that and set it to zero to optimize. $d(d^2)/dx = 2x + 1 = 0$ and so $x = -1/2$.

My question is why is this the case? Is there a way to end up with x = 0 using calculus? Without necessarily JUST looking at the graph.

share|improve this question
4  
Given that $(0,0)$ is itself a solution to $y=\sqrt{x}$, the closest point to $(0,0)$ on the curve defined by $y=\sqrt{x}$ is of course itself, not any other point. Can you post the steps you were using to conclude this $x=-1/2$, so that people are able to see where the wrong step is? –  Zev Chonoles Jun 2 '13 at 7:47
    
I actually don't 'know' the solution for (0, 0). I'm asking why optimizing this problem yields x = -1/2 even though this isn't even defined for $y = \sqrt{x}$. It was just the most obvious conclusion (to me). –  user56833 Jun 2 '13 at 7:50
    
Well, your intuition is correct :) The only way people will be able to tell you why you are getting $x=-1/2$ is if you post your work so that people can look at it, though. –  Zev Chonoles Jun 2 '13 at 7:51

3 Answers 3

up vote 8 down vote accepted

The square of the distance from the origin is as follows:

$$d^2=x^2+y^2$$

$$d^2=x^2+x$$

$$\frac{d}{dx}(x^2+x)=2x+1$$

In optimizing this, make sure you're considering all the critical points, including the endpoints of the domain (in this case $x=0$), not just the points where the derivative equals $0$.

share|improve this answer

I'm assuming you're saying that each point can be written as $(x, \sqrt{x})$ and hence the square of the distance from the origin is $d^2=x^2+(\sqrt{x})^2=x^2+x$ which is a parabola with a minimum at $x=-\frac{1}{2}$. The problem with this is that you are neglecting the domain of the function. The original function can not take negative x-values and similarly the square of the distance can't be negative. So you have to solve for the minimum distance subject to these constraints and the solution (as should be intuitively obvious) is then the point $(0,0)$

share|improve this answer

The reason your method doesn't work is because if you allow $x$ to be negative, then $y$ is allowed to be complex, and the distance to the origin is no longer $x^2+y^2$, it is $x^2+|y|^2$. In this case then the distance to the origin is $x^2+|x|$, and since $x^2+|x|\ge 0$, the minimum distance is $0$ when $x=0$.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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