A Lagrange Mulipliers Problem My problem is this: Find the min and max values of $f(x,y)=x^2+3xy+y^2$ on the domain $(x-1)^2+y^2=1$. 

I used lagrange multipliers to find that the $y$ coordinate satisfies $f\left(x\right)=8y+(46y^2)/3-16y^3-24y^4=0$ for any critical point $(x,y)$, and $x=2y^2+(2/3)y$
Using Wolfram Alpha, I found that this has roots (aprox.),

$y=-0.97110$

$y=-0.45311$

$y=0.75755$

$y=0$

Wolfram alpha tells me that the function is optimized at the first and third points. However, it is unable to get them in exact form that is not horrendous(multiple radicals involving i). But my professor is expecting an exact answer-and certainly not the exact answer I have. 


Am I missing something?
 A: The Lagrange system
$$2x + y = 2\lambda(x-1)$$
$$2y + x = 2\lambda y$$
is linear in $x$,$y$. For $\lambda = 1/2,3/2$ the system has no solution. For $\lambda\ne 1/2,3/2$ the solution is unique: 
$$(x,y) = ((4\lambda^2 - 4\lambda)/(4\lambda^2-8\lambda+3),2\lambda/(4\lambda^2-8\lambda+3))$$
and you must check that the restriction is satisfied. This implies
$$\lambda(4\lambda^3 - 16\lambda^2 + 17\lambda - 6) = 0.$$
This equation has two real solutions: $\lambda = 0,2.576\dots$ and two complex solutions.
Alternative solution: parametrizing $(x-1)^2 + y^2 = 1$ as $x = 1 + \cos t$, $y = \sin t$, we have reduced the problem to the study of $g(t) = f(x(t),y(t)) = (1 + \cos t)^2 + (1 + \cos t)\sin t + \sin^2 t$.
A: $f(x,y,\lambda) = x^2 + y^2 + xy + \lambda (x^2 - 2x + y^2)\\
\frac {\partial f}{\partial x} = 2(1+\lambda) x + y - 2\lambda = 0\\
\frac {\partial f}{\partial y} = x + 2(1+\lambda) y = 0\\
\frac {\partial f}{\partial \lambda} = x^2 - 2x + y^2 = 0\\
$ 
$x,y,\lambda = 0$ is one solution (and is the min)
$2\lambda = -\frac {x+2y}{y}\\ 
2(1+\lambda) = -\frac{x}{y}$
$-\frac {x^2}{y} + y + \frac {x+2y}{y} = 0\\
-x^2 + y^2 + x+2y = 0\\
x^2 + y^2 - 2x = 0\\
2y^2 -x + 2y = 0\\
x = \sqrt {1-y^2}+1\\
2y^2 +2y-\sqrt{1-y^2} -1 = 0\\
2y^2 +2y-1 = \sqrt{1-y^2}\\
4y^4 + 8y^3  - 4y + 1 = 1-y^2\\
4y^4 + 8y^3 +y^2 - 4y = 0\\
y(4y^3 + 8y^2 + y - 4)= 0\\
$
And now we need the cubic formula:
$y = \sqrt[3]{\frac {31}{108}- \sqrt{(\frac {31}{108})^2-(\frac {13}{36})^3}}+\sqrt[3]{\frac {31}{108}+ \sqrt{(\frac {31}{108})^2-(\frac {13}{36})^3}}-\frac 23\approx 0.57638\\
x = \sqrt{1-y^2}+1 \approx 1.81718\\
f(x,y) = 4.68175$
A: Another approach that sidesteps the Lagrange multipliers:
Shift the origin to $(1,0)$ so the problem becomes
one of extremising $x^2+xy+y^2+y+2x+1$ subject to $x^2+y^2 = 1$.
Now replace $x,y$ by $\cos t, \sin t$ to reduce to extremising
$(1+\cos t) (2+ \sin t)$, with $t \in \mathbb{R}$.
It is immediate that the $\min$ is $0$ (take $t= \pi$, for example, noting that
the cost is always non negative).
The $\max$ is a little more painful. The derivative of the cost
is $\cos t +2 \cos^2 t -\sin t -1$, we can look for solutions of
$\cos t +2 \cos^2 t  -1 = \sin t$ by squaring both sides, letting $z=\cos t$ and
utilising the fact that $\cos^2 t + \sin^2 t  =1$ to get
$4z^4+4z^3+z^2−2z−3 = 0$, and since we know that $t=\pi$ is a solution,
we can factor $z-\cos \pi$ to get $r(z)=4z^3+z−3 = 0$. We note
that $r$ is strictly increasing and $r(-1) <0, r(1) >0$, hence there
is exactly one root $z^* \in [-1,1]$. A little bisection shows that
$z^* \approx 0.817$ from which we get a $\max$ of
$(1+z)(2+\sqrt{1-z^2}) \approx 4.682$.
