Find all intervals on which the given expressions are positive.

(x-1)(x+2)

I know the answer is : x<-2, x>1

please show me the steps on how to solve this math problem.

to have the product be positive, either both factors are negative, or both are positive.

Both negative:
x-1 < 0 AND x+2 < 0
x < 1 AND x < -2
==> x < -2

Both positive:
x-1 > 0 AND x+2 > 0
x > 1 AND x > -2
==> x > 1

or, you can consider what you know about polynomials. If there are no repeated roots, then the graph crosses the x-axis at various points. In between those points, the function does not change sign. When crossing the axis, the function changes sign.

So, consider x very large negative. Both factors are negative, so the product is positive. Each time it crosses the x-axis (at one of the roots), it changes sign. So, looking at the number line, and marking + or -, we start way out on the left with +, and change sign at each root:

++++++ -2 ----- 1 +++++++

Repeated roots modify this algorithm some, as the graph may just touch the axis and not change sign.

To find all intervals on which the given expression (x-1)(x+2) is positive, we need to determine the values of x for which the expression output a positive value.

Step 1: Factorize the expression.
(x-1)(x+2)

Step 2: Set each factor equal to zero and solve for x.
x - 1 = 0 --> x = 1
x + 2 = 0 --> x = -2

Step 3: Plot these points on a number line.
We mark -2 to the left of 1 on the number line.

Step 4: Pick a test point from each interval created by the points on the number line and substitute it into the original expression.

For the interval (-∞, -2):
Let's choose x = -3 as a test point.
(-3 - 1) (-3 + 2) = (-4)(-1) = 4, which is positive.

For the interval (-2, 1):
Let's choose x = 0 as a test point.
(0 - 1) (0 + 2) = (-1)(2) = -2, which is negative.

For the interval (1, +∞):
Let's choose x = 2 as a test point.
(2 - 1) (2 + 2) = (1)(4) = 4, which is positive.

Step 5: Determine the sign of the expression in each interval based on the test points.

For the interval (-∞, -2), the expression is positive.
For the interval (-2, 1), the expression is negative.
For the interval (1, +∞), the expression is positive.

Therefore, the intervals on which the expression (x-1)(x+2) is positive are x < -2 and x > 1.