# How can I isolate a variable?

I'm new to Mathematica. I'm having trouble using Reduce to isolate the variable hab in the inequality below (Mathematica has been running for 5 days now).

I am trying to obtain the limits of an integration.

Is there any other way I could approach this issue? I'm aware that the expression involved is not simple, and maybe Mathematica will not be able to find an analytical expression. When do I know that Reduce won't return a closed-form expression?

Reduce[
(1 + (hab^2 q^2)/(1 + gpa p + hae q)^2 + (hrb^2 r^2)/(1 + gpr p + hre r)^2)
(1 -
(Cx^2 (hrb (1 + gpa p + hae q) r + hab q (1 + gpr p + 2 hrb r + hre r))^2) /
((1 + gpa p + (hab + hae) q)^2 (1 + gpr p + (hrb + hre) r)^2)) < 2^Rs &&
Rs > 0 && p > 0 && q > 0 && r > 0 && hab > 0 && hae > 0 && gpa > 0 &&
gpr > 0 && hrb > 0 && Cx >= 0 && Cx <= 1,
hab, Reals]


Two possibele workarounds:

1. With "CoefficientList" you can show that this equation is of the form

(c0 + c1 hab + c2 hab^2 + c3 hab^3 + c4 hab^4)/(cd0 + cd1 hab + cd2 hab^2) < 2^Rs


where the parameters c0,c1,c2,c3,c4,cd0,cd1,cd2 depend in a complex form on your parameters p,q,r,hre,hae, ...

In general you can get conditons for hab with

Reduce[Flatten[{(c0 + c1 hab + c2 hab^2 + c3 hab^3 + c4 hab^4)/(
cd0 + cd1 hab + cd2 hab^2) < 2^Rs, {cd0 >= 0, cd1 >= 0,
cd2 >= 0}, {c0 >= 0, c1 >= 0, c2 >= 0, c3 >= 0, c4 >= 0, Rs > 0,
hab > 0}}], hab, Reals]


but my pc run out of memory.

It works with definite values for at least 4 or 5 parameters.

1. A better way is to reduce the number of variables and directly inserting definite values for your p,q,r, hae, ... and then apply Reduce.

Here an example, where only hre and Rs are free variables:

    eq = (1 + (hab^2 q^2)/(1 + gpa p + hae q)^2 + (hrb^2 r^2)/(1 + gpr p +
hre r)^2) (1 - (Cx^2 (hrb (1 + gpa p + hae q) r +
hab q (1 + gpr p + 2 hrb r + hre r))^2)/((1 +
gpa p + (hab + hae) q)^2 (1 +
gpr p + (hrb + hre) r)^2)) < 2^Rs /. {p -> 1, q -> 2,
r -> 3, Cx -> 1/2, gpr -> 1/2, gpa -> 1/3, hae -> 1/4,
hrb -> 1/5} // Simplify

red[hre_, hab_, Rs_] =
Simplify[Reduce[eq && hab > 0 && Rs > 0 && hre > 0, hab, Reals],
hab > 0 && Rs > 0 && hre > 0];

Manipulate[
RegionPlot[red[hre, hab, Rs], {hre, 0, 5}, {hab, 0, 7},
FrameLabel -> {hre, hab}], {{Rs, 5}, 0, 5}] • Thanks for your answer. I realize that the second approach has a higher probability of working. However, the first is more suited for what i need to do, which is find an expression for an integral limit. Since "hab" is a random variable, i want to integrate its PDF, from 0 to the limit i would get from the reduce i introduced in the Stack Exchange question. I am not sure how to properly work with CoefficientList yet, but thanks anyway – Guilherme Schunemann Jun 30 '17 at 11:52

I set

 a = (hrb^2 r^2)/(1 + gpr p + hre r)^2; b = (q^2) /(1 + gpa p +
hae q)^2; c =  Cx^2 (hrb (1 + gpa p + hae q) r; d = (1 + gpr p + 2 hrb r + hre r);
e = (1 + gpr p + (hrb + hre) r)^2 ; f = 1 + gpa p + hae q;


The as denominator is positive inequality becomes

-2^Rs e f^2 X^2 + (1 + a + b X^2) (1 - c - d^2 q X^2)<0


Now expanding and substituting X^2->Z you get

1 + a - c - a c + b Z - b c Z - 2^Rs e f^2 Z - d^2 q Z - a d^2 q Z -
b d^2 q Z^2<0


that is

b d^2 q Z^2 - (b - b c - 2^Rs e f^2 - d^2 q - a d^2 q) Z - (1 + a -
c - a c) > 0


Now set

A = b d^2 q; B = b - b c - 2^Rs e f^2 - d^2 q - a d^2 q; C =
1 + a - c - a c;


solve

A Z^2 - B Z - C > 0


it's a nightmare, anyway...

• Thanks for answering. Nonetheless, the issue is that i'm not trying to solve the inequality, but to express it with only the variable "hab" in one side of it. something like: hab < ETC. However, i am starting to think that this path is unfeasible... – Guilherme Schunemann Jun 28 '17 at 18:23