03Afunctions

toc = Function Notation =

Functions
A ** function ** takes an input, performs some process on it, then outputs a result.

Eg: ** y = sin(x) ** is a function that takes an angle(x) as input and outputs a decimal number (y) as a result.

Eg: ** y = 2x + 3 ** is a function that takes x as an input and outputs y (twice x then add 3) as the result.

A different way to write ** y = 2x + 3 **, is to write it using ** function notation **: ** f(x) = 2x + 3 **


 * f(x) = 2x + 3 **
 * the __name__ of the function is ** f ** (it could have been **g** or **h** or ...)
 * the ** x ** in the brackets after the f, tells us the variable used in the function is ** x **.
 * The ** 2x + 3 ** tells us what the function does to the variable.

The following are examples of functions
 * f(x) = sin(x)
 * g(y) = 3y 2
 * h(x, y) = 3x + 2y {functions with 2 inputs not studied this year}

Substituting Values
Given a function: ** f(x) = 2x + 3 **


 * f(4) ** is shorthand for "input ** x = 4 ** into the function"
 * it results in the ** x ** being replaced by ** 4 **

math \\ . \qquad f(4) = 2 \times 4 + 3 \\ \\ . \qquad \qquad = 11 math


 * f(a) ** results in the ** x ** being replaced with **a**

math . \qquad f(a) = 2a + 3 math


 * f(a + 4) ** results in the **x** being replaced with ** (a + 4) **

math \\ . \qquad f(a+4) = 2(a+4) + 3 \\ \\ . \qquad \qquad \quad \;\; = 2a + 8 + 3 \\ \\ . \qquad \qquad \quad \;\; = 2a + 11 math

Equations and Functions
Given a function: ** f(x) = 2x + 3 **


 * Solve f(x) = 7 ** means "find the value of x which makes f(x) = 7" :

math \\ . \qquad f(x) = 7 \\ \\ . \qquad 2x + 3 = 7 \qquad \{ -3 \} \\ \\ . \qquad 2x = 4 \qquad \quad \;\; \{ \div 2 \} \\ \\ . \qquad x = 2 math

Arithmetic with Functions
Given the functions:
 * f(x) = 2x + 3
 * g(x) = x 2

We can perform basic arithmetic with the results of functions

math \\ \textbf{(a)} \quad 2f(3) = 2 \times f(3) \\ \\ . \qquad \qquad \; = 2 \times 9 \\ \\ . \qquad \qquad \; = 18 math

math \\ \textbf{(b)} \quad f(4) + g(4) = 11 + 16 \\ \\ . \qquad \qquad \qquad \quad = 27 math

math \\ \textbf{(c)} \quad f(2a) - g(a) = \big( 2 \times 2a + 3 \big) - \big( a^2 \big) \\ \\ . \qquad \qquad \qquad \quad \;\; = \big( 4a+3 \big) - \big( a^2 \big) \\ \\ . \qquad \qquad \qquad \quad \;\; = 4a + 3 - a^2 math

Sketching functions
We sketch the function ** f(x) = 2x + 3 **, exactly the same way as we sketch ** y = 2x + 3 ** {they are both the same thing, written in different notation}

math . \qquad f(0) = 3 \qquad \textit{so y-intercept at } (0, \; 3) math
 * The y-intercept is where x = 0, ie y = f(0) **

math \\ . \qquad f(x) = 0 \\ \\ . \qquad 2x + 3 = 0 \qquad \{-3 \} \\ \\ . \qquad 2x = -3 \qquad \quad \{ \div 2 \} \\ \\ . \qquad x = -1.5 \qquad \textit{so x-intercept at } (-1.5, \; 0) math
 * The x-intercept is where y = 0, ie f(x) = 0 **

Naming Conventions
{not in course}

Mathematicians traditionally use different parts of the alphabet for naming different types of things {this isn't a rule but you will notice it is very common}
 * a, b, c are used for constants
 * x, y, z are used for variables that can be any real number
 * f, g, h are used for functions
 * n, p, q are used for variables that can only be whole numbers (integers)
 * Capital Letters are used for names of sets __**or**__ names of vertices in shapes
 * Greek letters are also often frequently used ( a, b, q for angles, etc)

In situations where we want to use more than 3 of a particular type, we tend to resort to using subscript numbers attached to (usually) the first letter of each list above Eg: a 1, a 2 , a 3 , a 4 would be suitable names for 4 different constants.

Some letters are widely used for a particular purpose and therefore we avoid using them for other things. Eg: p is so widely used for 3.1415 ... that it would be confusing to use it for anything else. Eg: q is so widely used for a variable angle that it is rarely used for anything else.

Go to top of page flat

.