I have an error in a Python Gekko program that says there is a problem with an equation. I know that there are two solutions to this problem where the unit circle intersects the line.
from gekko import GEKKO
m = GEKKO()
x = m.Var()
y = m.Var()
m.Equation(x**2+y**2=1)
m.Equation(x=y)
m.solve()
When I put the equations together, it gives a different error SyntaxError: invalid syntax.
from gekko import GEKKO
m = GEKKO()
x = m.Var()
y = m.Var()
m.Equations([x**2+y**2=1,x=y])
m.solve()
I can get a solution by including the equations as an objective function but the solver IPOPT reports x=0, y=0 if I give that initial guess. When I guess x=1, y=1 it gives one of the correct solutions as x=0.707, y=0.707. I would like to have the solver enforce those as hard (not soft) constraints.
m.Obj((x**2+y**2-1)**2)
m.Obj((x-y)**2)
What can I do to solve this problem with Python Gekko?

==everywhere? - Davis Herring