Smallest distance between parabola and line

188 Views Asked by At

Probably a noobish question, but I've got this problem:

Two graphs: $y=0.5x^2$ and $y=-2+x$. A vertical lines goes through these graphs in points A and B. What's the shortest possible distance between A and B?

2

There are 2 best solutions below

0
On BEST ANSWER

You want to minimise $\frac{1}{2}x^2-x+2=\frac{1}{2}(x-1)^2+\frac{3}{2}$. So the answer is $\frac{3}{2}$ achieved when the vertical line is $x=1$.

0
On

The distance between two graphs can be denoted by $g(x)=|0.5x^2-(-2+x)|=|0.5x^2-x+2|$.

Now we need to minimize the function $g(x)$.

We can do this by taking the derivative of g(x):

$g'(x)=x-1$

Set this to zero:

$x-1=0 \Rightarrow x=1$

So the shortest distance appear at x=1.

And the shortest distance would be: $0.5*1^2-(-2+1)=1.5$