What is a **function**? A function is a correspondence between two sets so there is **exactly** one element from the second set assigned to each element from the first set.

This sounds a bit complicated, so let’s simplify it. You have two sets of things.

Set A is a set of 4 triangles and the set B is a set of 3 squares.

A function f : A -> B (read function from A to B) is an operation in which every triangle joins exactly one square.

It would have also been a function even if two triangles would share one square, but not the other way around.

## Linear function

Before we define linear function let’s first define few terms. We all know what a number line is, but now we’ll have to go a step further and define a number plane. A **number plane** has two axis, horizontal and vertical. Vertical is called the y-axis, and horizontal x-axis. It is also known as __Cartesian plane__.

Their intersection will be marked with 0, on the x-axis, numbers on the left will be negative and on the right positive, and on y-axis, numbers below 0 will be negative and above positive.

A coordinate is an ordered pair of numbers which tells us where specific point is located. First number indicates where the point is located considering x- axis, and second considering y- axis. The plain is divided into quadrants. First is upper right, second upper left, third down left, and forth down right.

**Linear function** is a function given by a rule , where a is from a set of real numbers. In our examples f (x), placed on the bottom of this lessons, will be replaced with y. In this rule, x is the changeable variable. That means that you can take any numbers in the place of x and get yourself an ordered pair of numbers. Every function is represented by a graph. A graph is a set of all ordered pairs that satisfy rule of a function. For linear functions that graph is a straight line that goes trough the (0, 0) coordinate. There are two parts of every linear function, the dependent variable, or f (x) in this case, and independant variable, x. This only means that you take x arbitrarily, and your f (x) depends on your choice.

__Example 1:__ Draw a graph of:

First you have to make your dependant/independant variable table.

This is how it will usually looks like. You only need 2 points to make a line, but for precise in drawings, we’ll take 3. The usual values for x are -1, 0 and 1.

Now, how to get f(x). You have your function rule. In that rule you put you x to get f(x).

=> =>

Now you have your ordered pairs : (-1,-2), (0,0), (1,2) .All you have to do to make a graph is put them in the plane, and connect them with a straight line. So how do you put them in a plane?

(-1, -2): So, -1 is on the x – axis. So we put a straight vertical line trough -1, and -2 is on the y, so we put a straight horizontal line trough -2 on y-axis. Their intersection is the point we are looking for. Do to the same to remaining two points, and simply draw a line that goes trough those three points.

The number infront of x indicates **the slope of your line**.

## Slope

The slope of a line is a number that describes steepness and direction of the line. A slope (m) is calculated by the formula:

In this formula and are any two points on that line.

If it’s positive the line will go trough first and third quadrant, and if it’s negative trough second and forth.

If the slope is equal to 0, then the line will be paralel so x – axis. Y = c

If x is a constant x = c, that will represent a line paralel to y-axis.

When we’re comparing two lines, if their slopes are equal they are parallel, and if they are in a relation m1=-1/m2 they are perpendicular.

Example: Let’s say we know two points on our line: and . Calculate the slope.

Slope is usually marked with an ‘m’.

So, the slope of this line equals to . All lines paralel to this one will also have slope equal to , and all lines perpendicular – 5.

If you are given only a line in a coordinate plane, and you have to calculate the slope, you simply read off two points and put them in a formula.

__Example 2:__ Draw a graph of :

Again, first we draw the table:

(if the function is linear this will always be true)

Ordered pairs : (-1, 2), (0,0), (1,-2)

__Example 3:__ Draw a graph of :

When there is a fraction involved, it is easier to take his multiples so we can get whole numbers:

Since the number which multiplies x indicates slope of the line, the smaller he is, the smaller that slope is, in other words the smaller that number is, your line will be closer to x-axis. Same goes for negative one.

## Affine function

Affine function is a function given by a rule **f (x) = a * x + b** , where a and b are from the set of real numbers.

Let’s compare it with linear function : . The only thing different is that b. He indicates the shift on the y- axis. If it is positive, whole graph will go up on the y- axis, and if it is negative down.

__Example 1:__ Draw a graph of : .

There are two ways you can draw this graph, first one is that you draw f(x) = x and than move all point up for exactly 4. Second one is the same as we used to draw linear functions.

This form of functions is called the explicit form. You can also present it by implicit form: ax+by+c=0. You can easily turn int into explicit by turning all but by on the right side, and than dividing by b. Y is equivalent to f(x).

__Example 2:__ Draw a graph of:

__Example:__ If you know that the slope of your line is equal 2, and it goes through (1, 1) and (x2,2 ). Find X2 coordinates.

Analog for any other coordinate.

**Graph of linear inequality**

Graph of linear inequality will firstly be drawn exactly like linear or affine function, set of solutions here will be if:

- area above the graph (graph not included)
- – area under the graph (graph not included)
- – area above the graph (graph included)
- –area under the graph (graph included)

__Example:__ Draw the graph of

The solution set will be all points in area above the graph, with graph included.

First you solve it like , and then mark solutions.

## Worksheets

Linear function

**Linear functions - Point-slope form** (161.7 KiB, 276 hits)

**Linear function - Slope-intercept form** (208.7 KiB, 354 hits)

**Linear functions - Standard form** (972.7 KiB, 292 hits)

**Graphing linear functions** (2.0 MiB, 427 hits)

Slope

**Determine slope in slope-intercept form** (160.4 KiB, 283 hits)

**Determine slope from given graph** (2.1 MiB, 264 hits)

**Find the integer of unknown coordinate** (273.6 KiB, 244 hits)

**Find the fraction of unknown coordinate** (418.5 KiB, 374 hits)

Linear inequalities

**Graph of linear inequality** (2.8 MiB, 263 hits)