6.2 Examples of functions of a real variable
This section gives examples of important classes of functions whose domain is a subset of . Even if these are familiar from previous studies, you should make sure you understand these definitions in the context of the formal definition of a function in Definition 6.1.
6.2.1 Polynomials
Definition 6.8 (Polynomial, polynomial function).
Suppose are real numbers, with . The expression
is called a polynomial with real coefficients. The numbers are called coefficients. The integer is called the degree of the polynomial. The special polynomial has degree .
We can use this algebraic expression to define a polynomial function given by the formula
If a polynomial has degree , we call the coefficient in front of the leading coefficient of the polynomial.
Note that there is a subtle difference between a polynomial and a polynomial function. Polynomials (i.e. expressions of the form as above) can be treated as mathematical objects in their own right and are studied in the field of abstract algebra. Whereas, polynomial functions must also have a domain and codomain. In practice, mathematicians are often informal about the difference between a polynomial and polynomial function. This informality rarely causes problems, especially when the domain and codomain are , but it is good to keep clear in your mind what sort of mathematical object you are working with.
-
•
A polynomial of degree defines a constant function.
-
•
A polynomial of degree defines an affine function. For example, where defines an affine function.
-
•
A polynomial of degree defines a quadratic function. For example, with defines a quadratic function.
-
•
Polynomials of degree , and are respectively known as cubics, quartics and quintics.
The graph of an affine function is a straight line in the plane. However, since these lines need not go through the origin, they do not define what mathematicians call “linear functions” in many other areas (e.g. “linear maps” in linear algebra.) Hence, we use the word “affine” to avoid future confusion.
6.2.2 Manipulating and combining polynomials
Polynomials can be added, subtracted, multiplied and manipulated in general using elementary algebra. For example, to multiply the polynomials and you could expand and then collect together terms of the same degree, as follows:
Exercise 6.9.
Write in the form , for constants , and . [This manipulation is known as ‘completing the square’.]
Solution (please try for yourself before looking)
First observe that
By comparing this with and equating corresponding coefficients, we see that . Then which means . Finally, . So, after substituting our values for and , we obtain . Therefore,
[Expand out the right hand side of this equation to check that it does indeed give you ].
In Block 1, we were introduced to the notion of a divisor within the set of real numbers. This notion of a divisor can also be applied to polynomials.
Definition 6.10 (Polynomial divisor).
Let and be polynomials, where .
We say the polynomial is a divisor of if
can be written as a polynomial.
Exercise 6.11.
Given that is a divisor of , factorise completely as a product of polynomials of degree 1.
Solution (please try for yourself before looking)
First we divide by , and then factorise to get
Hence .
Polynomial expressions have many written forms. for example,
| Expanded | |||
| Factored | |||
| Completed square | |||
| Nested form | |||
A significant goal of elementary algebra is to transform an expression from one form into an equivalent expression in another form. We can show all of the above forms are equivalent to the expanded form by multiplying out the brackets. More work is needed to re-write an expanded polynomial into one of the other forms.
6.2.3 Rational functions
Definition 6.12 (Rational function).
A rational expression is defined as the ratio of two polynomials, e.g.
A rational function is a function defined by a formula that is the ratio of two polynomials. That is is a rational function if
where and are polynomial functions, and .
Note that the implied domain of a rational function is all real numbers except for those where the denominator is zero (in symbols, ). The codomain of a rational function is usually .
-
•
Zeros of are the values where . Equivalently, these are the values where and .
-
•
Poles (or singularities) of are the values where denominator .
-
•
If the same factor appears in both the numerator and the denominator, it can cancel out algebraically. This algebraic cancellation might remove values of for which , in which case the graph has a removable discontinuity (a hole) at that point.
What happens to the rational function when its input is large depends on the degrees of and . Using and to denote the degree of and respectively, we have the following:
-
•
If , then approaches 0 as approaches or .
-
•
If , then approaches the ratio of the leading coefficients as approaches or .
-
•
If and the leading coefficient of is positive then grows to as approaches . Otherwise, if the leading coefficient of is negative, then descends towards as approaches . In both cases, the graph of looks like a polynomial when is large (this can be made precise by long division).
This describes the horizontal or oblique asymptotes.
Example 6.13.
Consider
The denominator vanishes at , giving a vertical asymptote there.
To better understand the behaviour of we perform division of by :
Hence
As approaches or , the term gets very close to 0, and hence the graph behaves like the line for large positive and large negative .
Our discussion of the behaviour of a function as its input approaches or is very informal here. You will learn about this more rigorously when you study “limits” in the course Introduction to Mathematical Analysis (IMA).
6.2.4 Equivalent Expressions vs Equivalent Functions
In algebra, two expressions are called equivalent if they can be transformed into one another using the rules of algebraic manipulation; for example,
are algebraically equivalent because
However, when creating functions from these expressions we need to be more careful: a function is defined by its domain, codomain and graph (defined by the expression) and two functions are equal only when their domains, codomains and graphs are the same. The expression defines a function whose domain excludes , while the expression defines a function on all real numbers. So although the formulas agree everywhere else, if their corresponding functions are defined on their implied domains, they are technically different functions, because these implied domains are not the same. In abstract algebra we often focus on equivalence of expressions, while in calculus (and later analysis) we distinguish functions by their graph (defined by their rule, expression or formula), domain and codomain.
The following example illustrates the dangers of algebraic cancelling without carefully considering the domains.
Example 6.14.
Consider the following two functions and where
and
Let’s try to find the point(s) (if any) at which the graphs of these functions cross, that is, we want to find all for which .
Sketching the graphs of (red, solid line) and (blue, dashed line) we see that the graphs appear to cross once. So we expect one solution to .
However, if we try to solve the equation , we get:
What went wrong? Can you try to correct it to find the solution to ?
Exercise 6.15.
Identify the error in the above example and correct it to find the solution to .
Solution (please try for yourself before looking)
It is important to note that, since we are looking for solutions to , we must only consider those that lie in BOTH the domain of and the domain of . This means our possible options for solutions are those elements of .
In the attempt above, we perform the step
by dividing both sides of the equation by . But this is 0 when and . So we must consider as a separate case.
Indeed, if ,
and
So is a solution to .
Are there any more solutions? Well now, if we consider the case where , we are permitted to divide both sides of our equation by and we end up with the working given in the above example, resulting in the false statement . Thus, there are no solutions except for to the equation , which matches what we see in the graphs of these functions.
6.2.5 Symmetry properties
Definition 6.16 (Periodic function).
Let be a subset of and be a function. Suppose there is a real number such that for all . Then the function is said to be -periodic or periodic with period .
For example, the function is -periodic because for all . Note that is also periodic with period , , , and so on.
The graph of a periodic function has translational symmetry in the direction of the -axis. This means that the shifting the graph along the -axis by its period produces the same graph. [Check that you understand why from the definition of a periodic function.]
Exercise 6.17.
Is the constant function defined by periodic? If so, what period does it have?
Solution (please try for yourself before looking)
The function is -periodic for any real number . This is because for every . In fact this is true for every constant function.
Definition 6.18 (Even function).
Let be a subset of . A function is said to be even if for all .
Example 6.19.
Some examples of even functions are:
-
•
because for all .
-
•
where because for all .
The graph of an even function has reflectional symmetry about the -axis. This means that the part of the graph that lies to the left of the -axis is the same as the part of the graph that lies to the right of the -axis, causing the -axis to act as a mirror. [Check that you understand why this is true from the definition of an even function.]
Definition 6.20 (Odd function).
Let be a subset of . A function is said to be odd if for all .
Example 6.21.
Some examples of odd functions are:
-
•
because for all ;
-
•
because for all in its domain.
-
•
where since for all .
The graph of an odd function has half-turn rotational symmetry about the origin. This means that we can take any straight line through the origin, take the part of the graph that lies on one side of and rotate it by around the origin to match the part of the graph that lies on the other side of .
6.2.6 Quadratic polynomials, completed square form and symmetry
Any quadratic polynomial can be written in completed-square form:
Completed-square form makes the parabola’s symmetry immediate: the square depends only on the distance from the vertical line .
Now suppose . At any point the value of is and at the mirror point the value of is
So, because the and enter only through the same squared term, we get . This shows that points in the graph that are equidistant from have the same height (or coordinate). Thus the line is the axis of (reflectional) symmetry for our quadratic and is known as the unique vertex (highest or lowest point on the graph of , depending on the sign of ).
Example 6.22.
Take and complete the square:
Therefore the unique vertex is and the axis of symmetry is . Notice that and , so and are symmetric about the line .
6.2.7 The symmetry of cubic polynomials
Consider a general cubic polynomial with :
If we translate this horizontally by some we get
and thus
Then, since , it follows that
Notice, in passing, that the complicated looking coefficients can be calculated using differential calculus
This holds for any value of .
Now choose so that i.e. . Then the coefficient becomes zero and we have
where .
This form has no term, and is called the reduced cubic. The point is called the point of inflexion11 1 A point of inflection is a point on a smooth plane curve at which the curvature changes sign. Such points are typically studied in a calculus class. of the cubic.
We performed a horizontal translation by . Now we perform a vertical translation by subtracting the constant term. If we translate vertically and horizontally in this particular way, then every cubic polynomial can be written in the form
for some . This defines an odd function since
This shows that every cubic has half-turn rotational symmetry about the point of inflexion.