Find the maximum value of $ax+ by$ $$ x^2 + xy + y^2 = t^2 $$
Find the maximum value of $ax + by$
One way of doing this is substituting
$ x = r \cos w $  and  $ y= r \sin w $
Then using calculus we can find the maximum value but this is a very lengthy process
So I wanted to know if there is a shorter way of doing this

$$(ax+by)^2\leq\frac{4}{3}(a^2-ab+b^2)(x^2+xy+y^2)$$ it's
$$((a-2b)x+(2a-b)y)^2\geq0.$$
The equality occurs for $(a-2b)x+(2a-b)^2y=0$ and $x^2+xy+y^2=t^2.$
Thus, $$\max\limits_{x^2+xy+y^2=t^2}(ax+by)=\frac{2}{\sqrt3}|t|\sqrt{a^2-ab+b^2}.$$
