Functions
A function relates an input to an output.
Input, Relationship, Output
We will see many ways to think about functions, but there are always three
main parts:
The input
The relationship
The output
Example: "Multiply by 2" is a very simple function.
Here are the three parts:
Input Relationship Output
0 ×2 0
1 ×2 2
7 ×2 14
10 ×2 20
... ... ...
For an input of 50, what is the output?
Names
First, it is useful to give a function a name.
The most common name is "f", but we can have other names like "g" ... or even
"peanut butter" if we want.
But let's use "f":
what goes into the function is put inside parentheses () after the name of the
function:
So f(x) shows us the function is called "f", and "x" goes in
And we usually see what a function does with the input:
f(x) = x2 shows us that function "f" takes "x" and squares it.
Example: with f(x) = x2:
an input of 4
becomes an output of 16.
In fact we can write f(4) = 16.
Sometimes There is No Function
Name
Sometimes a function has no name, and we see something like:
y = x2
But there is still:
an input (x)
a relationship (squaring)
and an output (y)
A Function is Special
But a function has special rules:
It must work for every possible input value
And it has only one relationship for each input value