Adding and subtracting functions

See how we can add or subtract two functions to create a new function.
Just like we can add and subtract numbers, we can add and subtract functions. For example, if we had functions ff and gg, we could create two new functions: f+gf+g and fgf-g.

Adding two functions


Let's look at an example to see how this works.
Given that f(x)=x+1f(x)=x+1 and g(x)=x22x+5g(x)=x^2-2x+5, find (f+g)(x)(f+g)(x).


The most difficult part of combining functions is understanding the notation. What does (f+g)(x)(f+g)(x) mean?
Well, (f+g)(x)(f+g)(x) just means to find the sum of f(x)f(x) and g(x) g(x). Mathematically, this means that (f+g)(x)=f(x)+g(x)(f+g)(x)=f(x)+g(x).
Now, this becomes a familiar problem.
(f+g)(x)=f(x)+g(x)                             Define.=(x+1)+(x22x+5)        Substitute.=x+1+x22x+5                Remove parentheses.=x2x+6                                Combine like terms.\begin{aligned} (f+g)(x) &= f(x)+g(x) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\small{\gray{\text{Define.}}}\\\\ &= \left(x+1\right)+\left(x^2-2x+5\right) ~~~~~~~~\small{\gray{\text{Substitute.}}}\\\\ &= x+1+x^2-2x+5~~~~~~~~~~~~~~~~\small{\gray{\text{Remove parentheses.}}}\\\\ &=x^2-x+6~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\small{\gray{\text{Combine like terms.}}} \end{aligned}

We can also see this graphically:

The images below show the graphs of y=f(x)y=f(x), y=g(x)y=g(x), and y=(f+g)(x)y=(f+g)(x).
From the first graph, we can see that f(2)=3f(2)=\greenD 3 and that g(2)=5g(2)=\blueD 5. From the second graph, we can see that (f+g)(2)=8(f+g)(2)=\goldD 8.
So f(2)+g(2)=(f+g)(2)f(2)+g(2)=(f+g)(2) because 3+5=8\greenD{3}+\blueD{5}=\goldD{8}.
Now you try it. Convince yourself that f(1)+g(1)=(f+g)(1)f(1)+g(1)=(f+g)(1).

Let's try some practice problems.

In problems 1 and 2, let a(x)=3x25x+2a(x)=3x^2-5x+2 and b(x)=x2+8x10b(x)=x^2+8x-10.

Opgave 1

Opgave 2

Subtracting two functions

Subtracting two functions works in a similar way. Here's an example:


p(t)=2t1p(t)=2t-1 and q(t)=t24t1q(t)=-t^2-4t-1.
Let's find (qp)(t)(q-p)(t).


Again, the most complicated part here is understanding the notation. But after working through the addition example, (qp)(t)(q-p)(t) means just what you'd think!
By definition, (qp)(t)=q(t)p(t)(q-p)(t)=q(t)-p(t). We can now solve the problem.
=(qp)(t)=q(t)p(t)Define.=(t24t1)(2t1)Substitute.=t24t12t+1Distribute negative sign.=t26tCombine like terms.\begin{aligned} &\phantom{=}(q-p)(t) \\\\ &=q(t)-p(t)\quad\small{\gray{\text{Define.}}} \\\\ &= (-t^2-4t-1)-(2t-1)\quad\small{\gray{\text{Substitute.}}}\\\\ &=-t^2-4t-1-2t+1\quad\small{\gray{\text{Distribute negative sign.}}}\\\\ &=-t^2-6t \quad\small{\gray{\text{Combine like terms.}}}\end{aligned}
So (qp)(t)=t26t.(q-p)(t)=-t^2-6t.

Let's try some practice problems.

Opgave 3


Opgave 4


An application

One college states that the number of men, MM, and the number of women, WW, receiving bachelor degrees tt years since 1980 can be modeled by the functions M(t)=526tM(t)=526-t and W(t)=474+2tW(t)=474+2t, respectively.
Let NN be the total number of students receiving bachelors degrees at that college tt years since 1980.

Udfordrende opgave