Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
$\begingroup$The solution is empty because $y$ is not guaranteed to be a positive real number. Solve[x^2 == y && (2 < x < 3 || x > 5) && y > 0, x] is what you want, isn't it? Or, tryReduce[x^2 == y && (2 < x < 3 || x > 5), x].$\endgroup$
$\begingroup$@A.Kato That gives the same result with this Solve[x^2 == y && (2 < x < 3 || x > 5), x, Reals] but I don't want specify y>0 as that is still unknown. Just use Reals seems work well.$\endgroup$
Solve[x^2 == y && (2 < x < 3 || x > 5) && y > 0, x]is what you want, isn't it? Or, tryReduce[x^2 == y && (2 < x < 3 || x > 5), x]. $\endgroup$Solve[x^2 == y && (2 < x < 3 || x > 5), x, Reals]but I don't want specifyy>0as that is still unknown. Just useRealsseems work well. $\endgroup$Reduce[x^2 == y && (2 < x < 3 || x > 5), x]seems more appropriate for something like this. $\endgroup$