From: Carla F. on
I was trying to solve the system of equations just to get the real solutions:
[x, y]=solve('-sqrt(x^2+y^2)+5*y+4' , '-3*sqrt(x^2+y^2)')

which solutions are:
x =
(4*i)/5
-(4*i)/5

y =
-4/5
-4/5

The solutions are imaginary and there are no real solutions.. How can I get the real solutions (empty in this case) of this system using the func arrayfun?

Thank you for help.
From: Walter Roberson on
Carla F. wrote:
> I was trying to solve the system of equations just to get the real
> solutions:
> [x, y]=solve('-sqrt(x^2+y^2)+5*y+4' , '-3*sqrt(x^2+y^2)')
>
> which solutions are:
> x =
> (4*i)/5
> -(4*i)/5
>
> y = -4/5
> -4/5
>
> The solutions are imaginary and there are no real solutions.. How can I
> get the real solutions (empty in this case) of this system using the
> func arrayfun?

realsolutions = imag(x) == 0 & imag(y) == 0;
newx = x(realsolutions);
newy = y(realsolutions);
From: Carla F. on
Thank you very much.