When graphing rational functions, how do I know which directions the graphs go?

Example, for equation y = 9/x - x, how would you graph this?

Also, why is the horizontal asymptote for f(x)= 2+x / x-7 is 1 instead of 0?

When graphing rational functions, there are several steps you can follow to determine the direction of the graph:

1. Identify the vertical asymptotes: Vertical asymptotes occur where the denominator of the rational function becomes zero, causing the function to be undefined. To find them, set the denominator equal to zero and solve for x. In your example y = 9/x - x, since there is no denominator, there are no vertical asymptotes.

2. Determine the horizontal asymptotes: Horizontal asymptotes can be found by comparing the degrees of the numerator and the denominator of the rational function.
- If the degree of the numerator is greater than the degree of the denominator, there is no horizontal asymptote.
- If the degree of the denominator is greater than the degree of the numerator, the horizontal asymptote is y = 0 (the x-axis).
- If the degrees are equal, divide the coefficients of the highest degree terms to find the horizontal asymptote. In your example y = 9/x - x, the degrees of the numerator and denominator are both 1, so you divide the coefficients: 9/1 = 9. Therefore, y = 9 is the horizontal asymptote.

3. Observe the behavior for x-values approaching infinity and negative infinity:
- As x approaches positive infinity, if there is a horizontal asymptote, the graph gets close to that line.
- As x approaches negative infinity, if there is a horizontal asymptote, the graph gets close to that line.

Now, let's graph the equation y = 9/x - x:

1. Identify any vertical asymptotes: There are none in this case.

2. Determine the horizontal asymptote: You found that y = 9 is the horizontal asymptote.

3. Find the x and y-intercepts:
- To find the x-intercepts (where the graph crosses the x-axis), set y = 0 and solve for x. In this case, 9/x - x = 0. Solving for x, you get x^2 = 9, which gives x = -3 and x = 3 as the x-intercepts.
- To find the y-intercept (where the graph crosses the y-axis), set x = 0. Substituting x = 0 into the equation, you get y = 9/0 - 0, which is undefined. Therefore, there is no y-intercept.

4. Plot these points and additional points for different x-values. You can choose values before, between, and after the x-intercepts to get a good sense of the shape of the graph.

Regarding the second part of your question, for the function f(x) = (2 + x) / (x - 7), the horizontal asymptote is 1 instead of 0 because the degrees of the numerator and denominator are equal (both 1). When the degrees are equal, you divide the coefficients of the highest degree terms to find the horizontal asymptote. In this case, it is (2/1) = 2/1 = 2. Therefore, y = 2 is the horizontal asymptote, not 0.