Graph of a function is a graphical representation of such function.
Before we draw our first graph of a function we need to know some basics. We need a coordinate system. It’s quite simple, we draw two straight lines intersecting at right angle. We will call one of the line horizontal axis and the second one vertical axis. See example:
It’s not much, so far. We can label both the axes by real numbers so we can measure distances there.
The intersection point is call the origin. Now we are able to define a coordinates for each point on the place. For example, let’s suppose a point A placed right there:
We can see that its horizontal coordinate is 1 and its vertical coordinate is 3. We can draw a simple segments that helps us determine the coordinates. Now we can write that the coordinates of the point A are (1, 3). Actually each pair (a, b) of real numbers are coordinates of a single point on such coordinate system. Let’s say we write down coordinates B = ( − 2, − 1). We can easily find them: we find − 2 on the horizontal axis and − 1 on the vertical axis. Then the point B lays right there:
In the previous chapter we used notation (a, b) for coordinates. We’ll call the (a, b) an ordered pair. What does it mean, ordered? Well it means that (a, b) is a different pair than the pair (b, a). For example: the ordered pair (2, 3) differs from ordered pair (3, 2). We can see it on the graph:
We could say that two ordered pair (a, b) and (c, d) equals when
How to Draw a Graph of a Function
A function has defined certain outputs for its inputs. For example, for a function f(x) = 2x we have for input x = 3 the output f(3) = 6. For an input x = 1 we have the output f(1) = 2. We can see all inputs as a first coordinate and all outputs as a second coordinate of an ordered pair.
Basically we can say that the function is set of ordered pairs in the form (x, f(x)) and in this way we can draw the graph of the function. So we know that f(3) = 6. It means that the point (3, 6) is part of the graph of the function. If we want to draw the whole graph we just need to draw all such points. We can start from the two points we already know, (1, 2) and (3, 6):
These two points are part of the graph. We can add a few more points, just a few examples:
- Because f(0) = 0, then (0, 0) is part of the graph,
- f(0.5) = 1, then (0.5, 1) is part of the graph,
- f(2) = 4, then (2, 4) is part of the graph.
We can add those three points to the graph:
We can kind of see the pattern: all the points lays on the same line. In the end we can draw the graph of the function f(x) = 2x as a simple line:
This red line represents all the points in the form (x, f(x)) for all x.
More Examples of Function Graphs
Let’s take a function f(x) = x + 1. We can compute some of its values:
- f(0) = 1 thus we get coordinates (0, 1),
- f(2) = 3 thus we get coordinates (2, 3),
- f(3) = 4 thus we get coordinates (3, 4),
- f( − 2) = − 1 thus we get coordinates ( − 2, − 1),
Now we’ll draw these points:
We can see that all point are on the same line, again. The whole graph looks like this:
But not all graphs are formed by a straight line. Let’s take another example: f(x) = x2.
- f(0) = 0 thus we get coordinates (0, 0),
- f(1) = 1 thus we get coordinates (1, 1),
- f(2) = 4 thus we get coordinates (2, 4),
- f(3) = 9 thus we get coordinates (3, 9),
- f( − 1) = 1 thus we get coordinates ( − 1, 1),
- f( − 2) = 4 thus we get coordinates ( − 2, 4),
- f( − 3) = 9 thus we get coordinates ( − 3, 9),
We can clearly see that these points doesn’t form any line. If we add all remaining point of function f we’ll get this graph:
This curve is also known as parabola.
What Can We Read From a Graph
We can go the other way around and we determine the function definition from a graph. Let’s take this graph:
What is the output for the input x = 1? We can determine it by looking at the graph. We found x = 1 on the horizontal axis and then we’ll find appropriate coordinate on the vertical axis that gives us the full coordinates:
The graph includes point (1, 3) which means that f(1) = 3. We can see that the graph contains also these points:
- (0, 2) meaning f(0) = 2,
- ( − 1, 1) meaning f( − 1) = 1,
- ( − 2, 0) meaning f( − 2) = 0,
The graph clearly expresses the function f(x) = x + 2.
Is Every Curve a Graph of Some Function?
What do you think? Is this a graph of some function?
What is the output for input x = 1? I. e. what is f(1)? Let’s take a look in the graph:
Clearly, we can see that there are two output for a single input. The outputs are denoted by the points A and B. This graph cannot represent a graph of a function since there are more outputs for a single input which violates the most fundamental part of being a function.
Remember: a curve in the plane represents a function if and only if any vertical line intersects the graph in at most one point. In can intersect the graph in zero points, meaning it doesn’t intersect the graph at all, but it cannot intersect the graph at two or more points.