Justin recently drove to visit his parents who live 96 miles away. On his way there his average speed was 20 miles per hour faster than on his way home (he ran into some bad weather). If Justin spent a total of 4 hours driving, find the two rates.

To find the two rates, let's assign variables to the speeds.

Let's say the speed on the way to his parents' house is represented by "x" miles per hour.

Since the speed on the way back is 20 miles per hour slower than the speed on the way there, we can represent it as "x - 20" miles per hour.

Now, let's determine the time it took Justin to drive to his parents' house and back.

Since the distance to his parents' house is 96 miles, we can divide this distance by the speed on the way there (x miles per hour) to find the time it took Justin to drive there:

Time = Distance / Speed
Time = 96 miles / x miles per hour
Time = 96 / x

Similarly, the time it took Justin to drive back home can be found by dividing the distance (96 miles) by the speed on the way back (x - 20) miles per hour:

Time = Distance / Speed
Time = 96 miles / (x - 20) miles per hour
Time = 96 / (x - 20)

Now, we can set up an equation using the given total driving time of 4 hours:

Total Time = Time to Drive There + Time to Drive Back
4 = 96 / x + 96 / (x - 20)

To solve this equation, we can multiply both sides by x(x - 20) to eliminate the denominators:

4x(x - 20) = 96(x - 20) + 96x

Now, we simplify and solve for x:

4x^2 - 80x = 96x - 1920 + 96x
4x^2 - 80x - 96x + 1920 = 0
4x^2 - 176x + 1920 = 0

We can either factor this quadratic equation or use the quadratic formula to find the values of x (the speed on the way there). Once we have the speed on the way there, we can find the speed on the way back by subtracting 20.

By solving this equation, we find that x can be either 40 or 12. However, a speed of 12 miles per hour doesn't make sense since Justin would have taken longer than 4 hours to drive the 96-mile distance. Therefore, Justin's average speed on the way there was 40 miles per hour, and on the way back, it was 40 - 20 = 20 miles per hour.

[96 / (r + 20)] + (96 / r) = 4

24 r + 24(r + 20) = r(r + 20)

r^2 - 28 r - 480 = 0 ... factoring ... (r - 40)(r + 12) = 0