Skip to main content
Logo image

Precalculus JumpStart

Section 6.5 Algebra of functions

Just as we can arithmetically combine numbers, we may also combine functions using basic arithmetic operations to create new functions.

Example 6.23. Dividing two functions.

Let \(f(x) = \sqrt{x}\) and let \(g(x) = x+4\text{.}\) We can divide these two expressions to obtain new function denote by \(f/g\text{.}\) Its value at \(x\) is
\begin{equation*} \left(f/g\right)(x) = \frac{f(x)}{g(x)} = \frac{\sqrt{x}}{x+4}. \end{equation*}
Note that \(f/g\) is simply the name I’ve given to this function and \(f(x)/g(x)\) is the expression I compute to evaluate \(f/g\text{.}\)
For example, when \(x=4\text{,}\)
\begin{equation*} \left(f/g\right)(4) = \frac{f(4)}{g(4)} = \frac{\sqrt{4}}{4+4} = \frac{2}{8} = \frac{1}{4}. \end{equation*}

Definition 6.24. Arithmetic of Functions.

Suppose \(f\) and \(g\) are functions. We define new functions \(f+g\text{,}\) \(f-g\text{,}\) \(fg\text{,}\) and \(f/g\) as follows
\begin{gather*} (f+g)(x) = f(x)+g(x)\\ (f-g)(x) = f(x)-g(x)\\ (fg)(x) = f(x)g(x)\\ (f/g)(x) = f(x)/g(x) \end{gather*}
defined for all \(x\) in the intersection of the domain of \(f\) and the domain of \(g\text{.}\) In addition, we require \(g(x) \neq 0\) for \(f/g\text{.}\)

Example 6.25. Combining Functions.

Let \(g(x) = \frac{1}{x}\) and \(h(x) = x^2-1\text{.}\) Find \(g+h\text{,}\) \(g-h\text{,}\) \(gh\text{,}\) and \(g/h\) at \(x\text{.}\) Find the domain of each.
Solution.
Adding,
\begin{equation*} (g+h)(x) = \frac{1}{x} + x^2-1. \end{equation*}
This is defined for all \(x\neq 0\text{.}\) The domain of \(g+h\) is \((-\infty,0)\cup(0,+\infty)\text{.}\) We can simplify, if desired, to a single term
\begin{align*} (g+h)(x) &= \frac{1}{x} + x^2-1\\ &= \frac{1}{x} + \frac{x^3-x}{x}\\ &= \frac{x^3-x+1}{x} \end{align*}
Subtracting,
\begin{equation*} (g-h)(x) = \frac{1}{x} - (x^2-1). \end{equation*}
Observe the parenthesis. Distributing,
\begin{equation*} (g-h)(x) = \frac{1}{x} - x^2+1. \end{equation*}
The domain of \(g-h\) is \((-\infty,0)\cup(0,+\infty)\text{.}\)
Multiplying,
\begin{equation*} (gh)(x) = \frac{1}{x} (x^2-1). \end{equation*}
The domain of \(gh\) is \((-\infty,0)\cup(0,+\infty)\text{.}\) We can distribute, if desired,
\begin{equation*} (gh)(x) = \frac{x^2}{x} - \frac{1}{x} = x-\frac{1}{x}. \end{equation*}
Dividing,
\begin{equation*} (g/h)(x) = \frac{\frac{1}{x}}{x^2-1}. \end{equation*}
We require \(x\neq 0\text{,}\) but additional must require \(x^2-1\neq 0\) since dividing by zero is not permitted. The second requirement excludes \(x=\pm 1\text{.}\) So the domain of \(g/h\) is all real numbers \(x \neq -1,0,1\text{.}\) In interval notation this is
\begin{equation*} (-\infty,-1)\cup(-1,0)\cup(0,1)\cup(1,+\infty). \end{equation*}
We prefer to simplify complex fractions:
\begin{align*} (g/h)(x) &= \frac{\frac{1}{x}}{x^2-1} \cdot \frac{x}{x}\\ &= \frac{1}{(x^2-1)x}\\ &= \frac{1}{x^3-x} \end{align*}

Example 6.26. Finding the Domain.

Let \(g(x) = \frac{1}{x}\) and \(h(x) = x^2-1\text{.}\) Find the domain of \(h/g\text{.}\)
Dividing in the opposite order as the previous example,
\begin{equation*} (h/g)(x) = \frac{x^2-1}{\frac{1}{x}}. \end{equation*}
We now only require \(x\neq 0\) because dividing into zero is perfectly fine. So the domain of \(h/g\) is all real numbers \(x \neq 0\text{.}\) Simplifying,
\begin{align*} (h/g)(x) &= \frac{x^2-1}{\frac{1}{x}} \cdot \frac{x}{x}\\ &= \frac{(x^2-1)x}{1}\\ &= x^3-x, \quad x\neq 0. \end{align*}
But be cautious here! The last expression \(x^3-x\) appears to be defined for all real numbers \(x\text{,}\) including zero. But in the context of the ratio of our two functions, \(x = 0 \) must be excluded from the domain. This is why I added this extra condition at the end.