# Keep only positive and real solutions from Solve?

Posted 3 years ago
18449 Views
|
4 Replies
|
2 Total Likes
|
 Hi people,I have a problem where I get four solutions to an equation system. Two imaginary, one negative and one positive. Can I somehow automatically tell Mathematica to only keep the real and positive answer?Sort of: Solve[equation1==equation2, x]//Real//Positive Thanks! //Freddy, Sweden
4 Replies
Sort By:
Posted 3 years ago
 It would be useful to have a complete self-contained example. Anyway, could try equation1==equation2 && x>0 as first argument to Solve.
Posted 3 years ago
 Try: Solve[equation1==equation2&& x > 0, x, Reals] or:  Solve[{equation1==equation2, x > 0}, x, Reals] Regards,MI
 Hi everybody, I have the same question, but I have hundreds of variables in my system of equations.In my large system of equations including numerous variables, I use the following structure: Solve[eq1==eq2&& eq3==eq4&& ....] and I do not specify any variable, so the solver tries to solve the system for all the variables.Now the question is instead of this format: Solve[eq1==eq2&& eq3==eq4&& ....&&, x1>0,x2>0,..., Reals] How can I ask the solver to return a non-zero positive solution for all the variables? Thanks