Functions and Inverse Functions

Functions


Functions have inputs and outputs, lets see some examples. To understand this page you need to know how to substitute and rearrange equations, please check those pages first.
f(x), is the notation for a function with input x.
Lets say f(x) = x + 2, the letter x represents the input, we would substitute a value for x for a number to gain an output.
If x = 2, what does the function f(x) equal?
f(2) = (2) + 2 = 4
So we inputted 2 into the function which gave us an output of 4.
If x = 10, what does the function equal?
f(10) = (10) + 2 = 12
So we inputted 10 into the function which gave us an output of 12.
What we are essentially doing is JUST SUBSTITUTING X WITH NUMBERS. Lets look at some questions below.
Question 1: Find the values of f(x) = 2x + 3 when x = 0, 1, 2, 3, 4 and 5
So the question gives us 6 inputs, this means we have to substitute x with the 6 given numbers and one by one attain an output from the function. This is shown below.
f(0) = 2(0) + 3 = (2 x 0) + 3 = 0 + 3 = 3f(1) = 2(1) + 3 = 2 + 3 = 5f(2) = 2(2) + 3 = 4 + 3 = 7f(3) = 2(3) + 3 = 6 + 3 = 9f(4) = 2(4) + 3 = 8 + 3 = 11
Question 2: Find the values of f(x) = x2 + 2x + 3, when x = -3, -2, -1, 0, 1, 2, 3
So the question gives us 7 inputs, this means we have to substitute x with the 7 given numbers and one by one attain an output from the function. This is shown below.
f(-3) = (-3)2 + 2(-3) + 3 = 9 – 6 + 3 = 6f(-2) = (-2)2 + 2(-2) + 3 = 4 – 4 + 3 = 3f(-1) = (-1)2 + 2(-1) + 3 = 1 – 2 + 3 = 2f(0) = (0)2 + 2(0) + 3 = 0 + 0 + 3 = 3f(1) = (1)2 + 2(1) + 3 = 1 + 2 + 3 = 6f(2) = (2)2 + 2(2) + 3 = 4 + 4 + 3 = 11f(3) = (3)2 + 2(3) + 3 = 9 + 6 + 3 = 18

Inverse Functions


If you understood the above questions and you know how to rearrange equations, as discussed in the changing the subject page, you will understand inverse functions. THEY ARE NOT HARD.
Lets take the function f(x) = 2x + 3,
When we input x = 5 into the function, the output we attain is 2(5) + 3 = 10 + 3 = 13
The input in the function is 5 and the output is 13.
What if we had the output, 13, and we wanted to know the input. In other words, how would we work out the value of x which gives the output of 13, without knowing the value of x.
We could create a linear equation and solve for x, as shown below
2x + 3 = 13
Subtract 3 from both sides
2x + 3 - 3 = 13 -3
2x = 10
Divide both sides by 2
x = 5
So from using our knowledge on solving for x, if we are given an output and we need to find the input value we could work out the input using the above way.
OR WE COULD USE THE INVERSE FUNCTION
The above way is good if we needed to find the input value, given 1 or 2 output values. If we have been given 5 output values, and we need to find the input values, then creating 5 equations and then solving them would take too long, so we can use the inverse function instead.
LETS FIRST LEARN HOW TO FIND THE INVERSE FUNCTION
If we have f(x) = 2x + 3, instead of writing f(x), write a letter which is different to x. Like below, we have chosen the letter y.
So
y = 2x + 3 (We have replaced f(x) with the letter y)
Now we must rearrange the equation to make x the subject.
y = 2x + 3
Subtract 3 from both sides
y - 3 = 2x + 3 - 3
y - 3 = 2x
(Divide both sides by 2)
(y - 3)/2 = 2x/2
(y - 3)/2 = x
So now we have x = (y - 3)/2
Lets replace the x with f-1(x) and y with x, as shown below.
f-1(x) = (x - 3)/2 (This is our inverse function) What does this mean though?
The function f(x) = 2x + 3, gives us an output when we substitute x with a number. The question we are trying to answer is how do we find x, given an output. So our question was, if the output was 13, what would x equal.
By using the inverse function f-1(x) = (x - 3)/2, we are able to attain the value of the input. So if we wanted to find the input value in the function f(x) which would return an output value of 13, we would substitute x in the inverse function f-1(x) = (x - 3)/2 with 13, as shown below.
f-1(13) = (13 - 3)/2 = (10)/2 = 5
The notation f-1(x) represents the inverse function of f(x).
Lets say we wanted to know what f(2) equals. f(2) equals 2(2) + 3 = 72 is the input and 7 is the output.
If we knew what the output of f(x) is and we wanted to know the value of x that causes the output to be that value, then we would use the inverse function f-1(x).
For example, we know that when the function output is 7, the input is 2, but lets show this using the inverse function.
f-1(7) = (7 - 3)/2 = (4)/2 = 2
This might be a little confusing because the letter x in the function f(x) represents the input number, however in the inverse function f-1(x) the letter x represents the output value. BUT REMEMBER
IN f(x), the letter x is the input number which we use to get THE OUTPUT.
IN f-1(x), the letter x is the output number which we use to get THE INPUT.
Let's answer the below question:
If f(x) = -32 + 5x, find the inverse function of f(x).
Lets first replace f(x) with y, as shown below.
y = -32 + 5x
Rearrange to make x the subject.
y = -32 + 5x
Add 32 to both sides
y + 32 = -32 + 5x + 32
y + 32 = 5x
Divide both sides by 5
(y + 32)/5 = (5x)/5
(y + 32)/5 = x
Thus we have x = (y + 32)/5
Now replace the y with x and replace the x with the inverse function notation which is f-1(x), as shown below.
f-1(x) = (x + 32)/5 (THIS IS OUR INVERSE FUNCTION)