# Graphing Rational Functions

Alignments to Content Standards: F-IF.C.7.d

In this task we are going to investigate the graphs of $\displaystyle{f(x) = \frac{1}{x+a}}$ and $\displaystyle{g(x) = \frac{1}{x^2+b}}.$ Move the sliders below to change the values of $a$ and $b$.

2. Connect the features you observed on the graphs to the structure of the expressions of the functions.

## IM Commentary

This task starts with an exploration of the graphs of two functions whose expressions look very similar but whose graphs behave completely differently. At first glance this is surprising but can be explained by a closer look at the functions' expressions.

Important features of rational functions are vertical asymptotes, which can be found by computing the zeros of the denominator of the function. Since one family of functions has a linear expression in the denominator, each representative has exactly one vertical asymptote. The other family of functions has a quadratic expression in the denominator, which can have 0, 1 or 2 zeros for different values of $b$, therefore the graphs have 0, 1, or 2 asymptotes.

Students can make many observations by playing with the sliders in the desmos app. It is up to the instructor to decide which observations they would like to pursue. The important point of the task is to connect features of the graph with corresponding features or properties of the formulas. As a follow-up exercise, the instructor might be asked to give a rough sketch of a specific such function, or use the techniques described in the solution to sketch the graph of something like $y=\frac{1}{x^2+x}$.

This task is an illustration of SMP 7 - Look for and make use of structure. It could be used as an in-class activity or as a homework problem leading up to a classroom discussion.

## Solution

1. As $a$ changes, the graph of the function $f(x)$ shifts horizontally. The function has a vertical asymptote at $x=-a$, otherwise the functions are exactly the same.

As $b$ changes the graph of $g(x)$ takes on three different shapes. It either has no vertical asymptote when $b\gt0$, 1 asymptote when $b=0$ or 2 asymptotes when $b\lt0$.

There are many more observations students can make, e.g.: If $b$ get large then $g(x)$ hugs the line $y = 0$, or if $a$ and $b$ are the same positive number, then the functions cross the y axis at the same point. There are many others.

2. The denominator of $\displaystyle{\frac{1}{x+a}}$ is zero when $x=-a$. This is true for all values of $a$. Therefore, the graph of $\displaystyle{\frac{1}{x+a}}$ has one vertical asymptote at $x=-a$. If $a=0$ we have $\displaystyle{f(x)=\frac{1}{x}}$. We can obtain all other functions by computing $f(x+a)$ which is is a horizontal shift of $\displaystyle{\frac{1}{x}}.$

Depending on the value of $b$, the denominator of $\displaystyle{g(x)=\frac{1}{x^2+b}}$ has 0, 1, or 2 zeros.

• When $b\gt 0$ we have $x^2+b\gt 0$, so the denominator is never zero and therefore, the graph of $g(x)$ does not have any vertical asymptotes. As $b$ approaches zero, the bump in the graph gets higher and higher since the denominator gets smaller and approaches zero for $x$-values close to zero. As $b$ gets larger, the entire denominator gets larger and therefore $g(x)$ has values close to zero for all values of $x$.Therefore, the bump disappears and $g(x)$ hugs the $x$-axis.
• When $b=0$ the graph of $g(x)$ has only vertical asymptote $x=0$.
• When $0\gt b$ we have $x^2+b = (x-\sqrt{-b})(x+\sqrt{-b})$. Therefore the graph of $\displaystyle{g(x) = \frac{1}{(x-\sqrt{-b})(x+\sqrt{-b})}}$ has vertical asymptotes $x=\sqrt{-b}$ and $x=-\sqrt{-b},$ which move farther and farther apart as $b$ moves towards minus infinity.

The $y$-intercept of $f(x)$ is $f(0)=\frac{1}{a}$. The $y$-intercept of $g(x)$ is $g(0)=\frac{1}{b}$. If $a=b$ then the two functions have the same $y$-intercepts.