Question 1200122
<pre>
We can also do the problem without using calculus:

{{{drawing(400,300,-10,10,-5,10,
graph(400,300,-10,10,-5,10),

arc(0,0,12,12/sqrt(5)), line(-15,0,15,12) )}}}

We draw two lines tangent to the ellipse parallel to the given line.
Their points of tangency will be the closest and farthest points
on the ellipse from the given line. 

{{{drawing(400,300,-10,10,-5,10,
graph(400,300,-10,10,-5,10),green(line(-14,-2,16,10),line(-16,-10,14,2)),

arc(0,0,12,12/sqrt(5)), line(-15,0,15,12) )}}}

We put the given line in slope-intercept form

{{{2x − 5y + 30 = 0}}}
{{{-5y=-2x-30}}}
{{{(-5y)/(-5y)=expr((-2)/(-5))x-30/(-5)}}}
{{{y=expr(2/5)x+6}}}

The green tangent lines will have the same slope with a different
y-intercept b

So either green tangent line will have equation {{{y=expr(2/5)x+b}}}

When we solve the system by substitution

{{{system(x^2+5y^2=36,y=expr(2/5)x+b)}}}

There must be one and only one point of intersection.

{{{x^2+5(expr(2/5)x+b)^2=36)}}}
{{{x^2+5(expr(4/25)x^2+expr(4/5)bx+b^2)=36)}}}
{{{x^2+expr(4/5)x^2+4bx+5b^2=36)}}}
{{{5x^2+4x^2+20bx+25b^2=180)}}}
{{{9x^2+20bx+25b^2-180=0)}}}

For there to be only one solution for the point of tangency, the
discriminant must = 0
{{{Discriminant = (20b)^2-4(9)(25b^2-180)=0}}}
{{{400b^2-4(9)(25b^2-180)=0}}}
{{{100b^2-9(25b^2-180)=0}}}
{{{100b^2-225b^2+1620=0}}}
{{{-125b^2+1620=0}}}
{{{-125b^2=-1620}}}
{{{b^2=expr((-1620)/(-125))
{{{b^2=324/25}}}
{{{b= "" +- 18/5}}}

Substituting {{{b=18/5}}}
{{{9x^2+20bx+25b^2-180=0)}}}
{{{9x^2+20(18/5)x+25(18/5)^2-180=0)}}}
{{{9x^2+72x+324-180=0)}}}
{{{9x^2+72x+144=0)}}}
{{{x^2+8x+16=0}}}
{{{(x+4)(x+4)=0}}}
x=-4
Substituting in the equation of the line:
{{{y=expr(2/5)x+b)}}}
{{{y=(2/5)(-4)+18/5)}}}
{{{y=2}}}

So one point is (-4,2), that's the closest point.

Substituting {{{b=-18/5}}}
{{{9x^2+20bx+25b^2-180=0)}}}
{{{9x^2+20(-18/5)x+25(18/5)^2-180=0)}}}
{{{9x^2-72x+324-180=0)}}}
{{{9x^2-72x+144=0)}}}
{{{x^2-8x+16=0}}}
{{{(x-4)(x-4)=0}}}
x=4
Substituting in the equation of the line:
{{{y=expr(2/5)x+b)}}}
{{{y=(2/5)(4)-18/5)}}}
{{{y=-2}}}

So the other point is (4,-2), that's the farthest point.

Edwin</pre>