Skip to main content
added 357 characters in body
Source Link
kglr
  • 400.5k
  • 18
  • 488
  • 929

You can use your conditions directly with ConditionalExpression without going through Reduce:

  Plot[ConditionalExpression[(x^2 + 1)/ x,
    ((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64], {x, -3, 3}]

gives

enter image description here

Similarly, you get the same result using Piecewise:

 Plot[Piecewise[{{(x^2 + 1)/x,  ((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64}}, 
       Indeterminate], {x, -3, 3}]

If have to use Reduce, it can be used with ConditionalExpression and Piecewise as follows:

  Plot[Evaluate@ConditionalExpression[(x^2 + 1)/x, 
     Reduce[((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64, x, Reals]], {x, -3, 3}]
  Plot[Evaluate@Piecewise[{{(x^2 + 1)/x,
    Reduce[((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64, x, Reals]}},
     Indeterminate], {x, -3, 3}]

This givesBoth give the same output as above.

You can use your conditions directly with ConditionalExpression without going through Reduce:

  Plot[ConditionalExpression[(x^2 + 1)/ x,
    ((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64], {x, -3, 3}]

gives

enter image description here

If have to use Reduce, it can be used with ConditionalExpression as follows:

  Plot[Evaluate@ConditionalExpression[(x^2 + 1)/x, 
     Reduce[((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64, x, Reals]], {x, -3, 3}]

This gives the same output as above.

You can use your conditions directly with ConditionalExpression without going through Reduce:

  Plot[ConditionalExpression[(x^2 + 1)/ x,
    ((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64], {x, -3, 3}]

gives

enter image description here

Similarly, you get the same result using Piecewise:

 Plot[Piecewise[{{(x^2 + 1)/x,  ((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64}}, 
       Indeterminate], {x, -3, 3}]

If have to use Reduce, it can be used with ConditionalExpression and Piecewise as follows:

  Plot[Evaluate@ConditionalExpression[(x^2 + 1)/x, 
     Reduce[((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64, x, Reals]], {x, -3, 3}]
  Plot[Evaluate@Piecewise[{{(x^2 + 1)/x,
    Reduce[((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64, x, Reals]}},
     Indeterminate], {x, -3, 3}]

Both give the same output as above.

Source Link
kglr
  • 400.5k
  • 18
  • 488
  • 929

You can use your conditions directly with ConditionalExpression without going through Reduce:

  Plot[ConditionalExpression[(x^2 + 1)/ x,
    ((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64], {x, -3, 3}]

gives

enter image description here

If have to use Reduce, it can be used with ConditionalExpression as follows:

  Plot[Evaluate@ConditionalExpression[(x^2 + 1)/x, 
     Reduce[((x^2 + 1)/x)^2 > 4 && ((x^2 + 1)/x)^3 < 64, x, Reals]], {x, -3, 3}]

This gives the same output as above.