Professional Documents
Culture Documents
Module Manual
Module Manual
This manual enjoys copyright under the Berne Convention. In terms of the Copyright
Act, no 98 of 1978, no part of this manual may be reproduced or transmitted in any
form or by any means, electronic or mechanical, including photocopying, recording or
by any other information storage and retrieval system without permission in writing
from the proprietor.
Table of Contents
Using this Manual.........................................................................................................4
Introduction ..................................................................................................................5
Module Resources .......................................................................................................6
Module Purpose ...........................................................................................................6
Module Outcomes ........................................................................................................6
Glossary of Key Terms for this Module ........................................................................7
Learning Unit 1: An Introduction to Arithmetic ..............................................................8
1 Whole Numbers ....................................................................................................9
2 Order of Operations ............................................................................................20
3 Real Numbers .....................................................................................................24
4 Integers ...............................................................................................................42
5 Rational Numbers and Real Numbers ................................................................50
6 Exponents and Square Roots .............................................................................55
7 Scientific Notation ...............................................................................................72
8 Recommended Additional Reading ....................................................................77
9 Activities ..............................................................................................................77
10 Exercises .........................................................................................................77
11 Glossary of Terms ...........................................................................................78
Learning Unit 2: Equations and Expressions .............................................................86
1 Equations, Equality, and Inequality .....................................................................87
2 Equations, Inequalities and Absolute Value ......................................................125
3 Introduction to Rational Expressions ................................................................131
4 Factoring ...........................................................................................................146
5 Roots.................................................................................................................175
6 Rational Exponents ...........................................................................................193
7 Complex Numbers ............................................................................................214
8 Recommended Additional Reading ..................................................................222
9 Activities ............................................................................................................223
10 Exercises .......................................................................................................223
11 Glossary of Terms .........................................................................................223
Learning Unit 3: Sets, Sequences and Functions ....................................................228
1 Introduction to Preliminaries .............................................................................228
2 Sets ...................................................................................................................239
3 Sequences ........................................................................................................249
4 Functions ..........................................................................................................255
5 Recommended Additional Reading ..................................................................263
6 Activities ............................................................................................................263
7 Exercises ..........................................................................................................263
Learning Unit 4: Counting ........................................................................................264
1 Introduction to Counting ....................................................................................264
2 Additive and Multiplicative Principles ................................................................265
3 Counting with Sets ............................................................................................268
4 Principle of Inclusion/Exclusion .........................................................................271
5 Counting Functions ...........................................................................................274
6 Counting and Data Representation ...................................................................277
7 Text ...................................................................................................................293
8 Images and Colours ..........................................................................................300
9 Recommended Additional Reading ..................................................................305
10 Activities ........................................................................................................305
11 Exercises .......................................................................................................305
Learning Unit 5: Introduction to Symbolic Logic and Proofs ....................................306
1 Symbolic Logic and Proofs ...............................................................................306
2 Proofs................................................................................................................315
3 Recommended Additional Reading ..................................................................326
4 Activities ............................................................................................................326
5 Exercises ..........................................................................................................326
Bibliography .............................................................................................................327
Intellectual Property .................................................................................................329
Various activities and revision questions are included in the learning units of this
manual. These are designed to help you to engage with the subject matter as well as
to help you prepare for your assessments.
Introduction
This course provides a broad overview of the mathematical principles of computer
science. You will examine basic arithmetic, number systems, data representation,
proof, and number systems. These concepts are necessary for the understanding of
how computers work. Equipped with this knowledge, you are expected to build a solid
foundation upon which more complex concepts in the discipline, such as programming,
may be built.
This module has been prepared for students pursuing studies in any field of computer
science and mathematics. It endeavours to help you grasp the essential concepts of
mathematics relevant to computer science. The module has an ample amount of both
theory and mathematics. It does not assume any prior understanding of elementary
algebra and arithmetic.
Module Resources
Prescribed Book The IIE. 2021. Mathematical Principles for Computer Science
for this Module Module Manual. Independent Institute of Education: Sandton.
Software None
Requirement
Recommended Tom Leighton, and Marten Dijk. 6.042J Mathematics for
Additional Computer Science. Fall 2010. Massachusetts Institute of
Reading Technology: MIT OpenCourseWare, https://ocw.mit.edu.
Module Purpose
The purpose of this module is to provide students with a foundational knowledge of
the basic mathematical principles and logical skills to solve Application
Development and Networking problems.
Module Outcomes
MO1 Demonstrate knowledge and understanding of the basic mathematical
calculations and principles.
MO2 Demonstrate knowledge and understanding of logical operations, logical
gates and relevant calculations.
MO3 Apply mathematical problem solving skills to given hypothetical
scenarios.
MO4 Demonstrate knowledge and understanding of the application of the
different number conversions and skills that apply to programming and
networking.
1 Whole Numbers
Whole numbers that are greater than nine consist of multiple digits. Each digit in a
given number has a place value. To better understand place value, numbers can be
put in a place-value chart so that the value of each digit can be identified. Numbers
with more than three digits can be separated into groups of three digits, known as
periods. Any whole number can be expressed in standard form, expanded form, or as
a word name.
In situations when you don’t need an exact answer, you can round numbers. When
you round numbers, you are always rounding to a particular place value, such as the
nearest thousand or the nearest 10. Whether you round up or round down usually
depends on which number is closest to your original number. When a number is
halfway between the two possible numbers, round up to the larger number.
There will be times when it’s helpful to compare two numbers and determine which
number is greater, and which one is less. This is a useful way to compare quantities
such as travel time, income, or expenses. The symbols < and > are used to indicate
which number is greater, and which is less than the other.
Mathematics involves solving problems that involve numbers. We will work with whole
numbers, which are any of the numbers 0, 1, 2, 3, and so on. We first need to have a
thorough understanding of the number system we use. Suppose the scientists
preparing a lunar command module know it must travel 382,564 kilometres to get to
the moon. How well would they do if they didn’t understand this number? Would it
make more of a difference if the 8 was off by 1 or if the 4 was off by 1?
In this section, you will look at digits and place value. You will also learn how to write
whole numbers in words, standard form, and expanded form based on the place values
of their digits.
The position of each digit in a number tells its value, or place value. We can use a
place-value chart like the one below to easily see the place value for each digit. The
place values for the digits in 1,456 are shown in this chart.
Place-Value Chart
Trillions Billions Millions Thousands Ones
1 4 5 6
Hundreds
Hundreds
Hundreds
Hundreds
Hundreds
Ones
Ones
Ones
Ones
Ones
Tens
Tens
Tens
Tens
Tens
In the number 1,456, the digit 1 is in the thousands place. The digit 4 is in the hundreds
place. The digit 5 is in the tens place, and the digit 6 is in the ones place.
As you see above, you can tell a digit’s value by looking at its position. Look at the
number of digits to the right of the digit, or write your number into a place-value chart,
with the last digit in the ones column. Both these methods are shown in the example
below.
The standard form of a number refers to a type of notation in which digits are separated
into groups of three by commas. These groups of three digits are known as periods.
For example, 893,450,243 has three periods with three digits in each period, as shown
below.
Place-Value Chart
Trillions Billions Millions Thousands Ones
8 9 3 4 5 0 2 4 3
Hundreds
Hundreds
Hundreds
Hundreds
Hundreds
Ones
Ones
Ones
Ones
Ones
Tens
Tens
Tens
Tens
Tens
Let’s examine the number of digits and periods in a greater number. The number of
body cells in an average adult human is about one hundred trillion. This number is
written as 100,000,000,000,000. Notice that there are 15 digits and five periods. Here
is how the number would look in a place-value chart.
Place-Value Chart
Trillions Billions Millions Thousands Ones
1 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Hundreds
Hundreds
Hundreds
Hundreds
Hundreds
Ones
Ones
Ones
Ones
Ones
Tens
Tens
Tens
Tens
Tens
You are now familiar with the place values of greater numbers, so let’s examine a
problem that involves converting from standard form to a word name.
Example
Problem During the week, Mike drives a total of
264 miles. Write 264 in expanded form.
In numerical form:
264 200
264 60
264 4
In word form:
264 2 hundreds
264 6 tens
264 4 ones
Then, write the numbers as a sum.
Answer 264 written in expanded form is
200 + 60 + 4, or
2 hundreds + 6 tens + 4 ones, or
(2 • 100) + (6 • 10) + (4 • 1)
You can also use a place-value chart to help write a number in expanded form.
Suppose the number of cars and pick-up trucks at this very moment is 251,834,697.
Place this number in a place-value chart.
Place-Value Chart
Trillions Billions Millions Thousands Ones
2 5 1 8 3 4 6 9 7
Hundreds
Hundreds
Hundreds
Hundreds
Hundreds
Ones
Ones
Ones
Ones
Ones
Tens
Tens
Tens
Tens
Tens
Inequalities
An inequality is a mathematical sentence that compares two numbers that aren’t equal.
Instead of an equal sign (=), inequalities use greater than (>) or less than (<) symbols.
The important thing to remember about these symbols is that the small end points
towards the lesser number, and the larger (open) end is always on the side of the
greater number.
There are other ways to remember this. For example, the wider part of the symbol
represents the jaws of an alligator, which “gobbles up” the greater number. So “35 is
greater than 28” can be written as 35 > 28, and “52 is less than 109” can be written as
52 < 109.
To compare two values that are not the same, you can write an inequality. You can
use a number line or place value to determine which number is greater than another
number. Inequalities can be expressed using greater than (>) or less than (<) symbols.
Estimation
An estimate is an answer to a problem that is close to the solution, but not necessarily
exact. Estimating can come in handy in a variety of situations, such as buying a
computer. You may have to purchase numerous devices: a computer tower and
keyboard for R1,295, a monitor for R679, the printer for R486, the warranty for R196,
and software for R374. Estimating can help you know about how much you’ll spend
without actually adding those numbers exactly.
Estimation usually requires rounding. When you round a number, you find a new
number that’s close to the original one. A rounded number uses zeros for some of the
place values. If you round to the nearest 10, you will have a zero in the ones place. If
you round to the nearest hundred, you will have zeros in the ones and tens places.
Because these place values are zero, adding or subtracting is easier, so you can find
an estimate to an exact answer quickly.
It is often helpful to estimate answers before calculating them. Then if your answer is
not close to your estimate, you know something in your problem-solving process is
wrong.
Estimation is very useful when an exact answer is not required. You can use estimation
for problems related to travel, finances, and data analysis. Estimating is often done
before adding or subtracting by rounding to numbers that are easier to think about.
Following the rules of rounding is essential to the practice of accurate estimation.
Mathematics often involves simplifying numerical expressions. When doing so, you
can use laws and properties that apply to particular operations. The multiplication
property of 1 states that any number multiplied by 1 equals the same number, and the
addition property of zero states that any number added to zero is the same number.
Two important laws are the (1) commutative laws, which state that the order in which
you add two numbers or multiply two numbers does not affect the answer, and (2)
associative laws which allow you to place numbers in different groups using
parentheses. You can remember this because if you commute to work you go the same
distance driving to work and driving home as you do driving home and driving to work.
`You can move numbers around in addition and multiplication expressions because
the order in these expressions does not matter.
You will also learn how to simplify addition and multiplication expressions using the
associative laws. As with the commutative laws, there are associative laws for addition
and multiplication. Just like people may associate with people in different groups, a
number may associate with other numbers in one group or another. The associative
laws allow you to place numbers in different groups using parentheses.
The addition property of 0 states that for any number being added to 0, the sum equals
that number. Remember that you do not end up with zero as an answer – that only
happens when you multiply. Your answer is simply the same as your original number.
According to the multiplication property of 1, the product of 1 and any number results
in that number. The answer is simply identical to the original number.
The commutative law of addition states that you can change the position of numbers
in an addition expression without changing the sum. For example, 3 + 2 is the same
as 2 + 3.
You likely encounter daily routines in which the order can be switched. For example,
when you get ready for work in the morning, putting on your left glove and right glove
is commutative. You could put the right glove on before the left glove, or the left glove
on before the right glove. Likewise, brushing your teeth and combing your hair is
commutative, because it does not matter which one you do first.
Remember that this law only applies to addition, and not subtraction. For example:
Below, you will find examples of expressions that have been changed with the
commutative law. Note that expressions involving subtraction cannot be changed.
You also will likely encounter real life routines that are not commutative. When
preparing to go to work, putting on our clothes has to occur before putting on a coat.
Likewise, getting in the car has to occur before putting the key in the ignition. In a store,
you would need to pick up the items you are buying before proceeding to the cash
register for checkout.
Multiplication also has a commutative law. The commutative law of multiplication states
that when two or more numbers are being multiplied, their order can be changed
without affecting the answer. In the example below, note that 5 multiplied by 4 yields
the same result as 4 multiplied by 5. In both cases, the answer is 20.
5 • 4 = 20
4 • 5 = 20
Keep in mind that when you are using the commutative law, only the order is affected.
The grouping remains unchanged.
The associative law of addition states that numbers in an addition expression can be
regrouped using parentheses. You can remember the meaning of the associative law
by remembering that when you associate with family members, friends, and co-
workers, you end up forming groups with them. In the following expression,
parentheses are used to group numbers together so that you know what to add first.
Note that when parentheses are present, any numbers within parentheses are
numbers you will add first. The expression can be re-written with different groups using
the associative law.
(4 + 5) + 6 = 9 + 6 = 15
4 + (5 + 6) = 4 + 11 = 15
Here, it is clear that the parentheses do not affect the final answer; the answer is the
same regardless of where the parentheses are.
Example
Problem Rewrite (5 + 8) + 3 using the associative
law of addition. Show that the rewritten
expression yields the same answer.
When rewriting an expression using the associative law, remember that you are
regrouping the numbers and not reversing the order, as in the commutative law.
Multiplication has an associative law that works exactly the same as the one for
addition. The associative law of multiplication states that numbers in a multiplication
expression can be regrouped using parentheses. The following expression can be
rewritten in a different way using the associative law.
(2 • 3) • 4 = 2 • (3 • 4).
Here, it is clear that the parentheses do not affect the final answer, the answer is the
same regardless of where the parentheses are.
Example
Problem Rewrite (10 • 200) • 24 using the associative law of
multiplication, and show that the rewritten
expression yields the same answer.
When rewriting an expression using the associative law, remember that you are
regrouping the numbers and not changing the order. Changing the order uses the
commutative law.
When an expression is being rewritten, you can tell whether it is being rewritten using
the commutative or associative laws based on whether the order of the numbers
change or the numbers are being regrouped using parentheses.
Example
Problem 10 • 2 = 20 is rewritten as 2 • 10 = 20. Was this
expression rewritten using the commutative law
or the associative law?
Remember that when you associate with friends and family, typically you are grouping
yourself with other people. So, if numbers in an expression are regrouped using
parentheses and the order of numbers remains the same, then the associative law is
being used.
Example
Problem 2 • (4 • 6) = 48 is rewritten as
(2 • 4) • 6 = 48. Was this expression rewritten
using the commutative law or the associative
law?
The distributive property of multiplication is a very useful property that lets you simplify
expressions in which you are multiplying a number by a sum or difference. The property
states that the product of a sum or difference, such as 6(5 – 2), is equal to the sum or
difference of the products – in this case, 6(5) – 6(2).
3 x 6 = 3(6) = 3 • 6.
3 • (2 + 4) = 3 • 6 = 18.
The distributive property of multiplication over addition can be used when you multiply
a number by a sum. For example, suppose you want to multiply 3 by the sum of
10 + 2.
3(10 + 2) = ?
According to this property, you can add the numbers and then multiply by 3.
3(10 + 2) = 3(12) = 36. Or, you can first multiply each addend by the 3. (This is called
distributing the 3.) Then, you can add the products.
The multiplication of 3(10) and 3(2) will each be done before you add.
3(10) + 3(2) = 30 + 6 = 36. Note that the answer is the same as before.
You probably use this property without knowing that you are using it. When a group
(let’s say five of you) order food, and order the same thing (let’s say you each order a
hamburger for R3 each and a coke for R1 each), you can compute the bill (without tax)
in two ways. You can figure out how much each of you needs to pay and multiply the
sum times the number of you. So, you each pay (3 + 1) and then multiply times 5.
That’s 5(3 + 1) = 5(4) = 20. Or, you can figure out how much the five hamburgers will
cost and the five cokes and then find the total. That’s 5(3) + 5(1) = 15 + 5 = 20. Either
way, the answer is the same, R20.
The two methods are represented by the equations below. On the left side, we add 10
and 2, and then multiply by 3. The expression is rewritten using the distributive property
on the right side, where we distribute the 3, then multiply each by 3 and add the results.
Notice that the result is the same in each case.
The same process works if the 3 is on the other side of the parentheses, as in the
example below.
Example
Problem Rewrite the expression 5(8 + 4)
using the distributive property of
multiplication over addition.
Then simplify the result.
The same number works if the 5 is on the other side of the parentheses, as in the
example below.
In both cases, you can then simplify the distributed expression to arrive at your answer.
The example below, in which 5 is the outside multiplier, demonstrates that this is true.
The expression on the right, which is simplified using the distributive property, is shown
to be equal to 15, which is the resulting value on the left as well.
Example
Problem Rewrite the expression
20(9 – 2) using the
distributive property of
multiplication over
subtraction. Then simplify.
2 Order of Operations
People need a common set of rules for performing computation. Many years ago,
mathematicians developed a standard order of operations that tells you which
calculations to make first in an expression with more than one operation. Without a
standard procedure for making calculations, two people could get two different
answers to the same problem. For example, 3 + 5 • 2 has only one correct answer. Is
it 13 or 16?
First, consider expressions that include one or more of the arithmetic operations:
addition, subtraction, multiplication, and division. The order of operations requires that
all multiplication and division be performed first, going from left to right in the
expression. The order in which you compute multiplication and division is determined
by which one comes first, reading from left to right.
After multiplication and division has been completed, add or subtract in order from left
to right. The order of addition and subtraction is also determined by which one comes
first when reading from left to right.
Below, are three examples showing the proper order of operations for expressions with
addition, subtraction, multiplication, and/ or division.
Example
Problem Simplify 3 + 5 • 2.
3 + 10 Then add.
Answer 3 + 5 • 2 = 13
Example
Problem Simplify 20 – 16 ÷ 4.
20 – 4 Then subtract.
16
Answer 20 – 16 ÷ 4 = 16
Example
Problem Simplify 60 – 30 ÷ 3 • 5 + 7.
60 – 10 • 5 + 7 Continue to perform
60 – 50 + 7 multiplication and division from
left to right.
10 + 7 Next, add and subtract from left
17 to right. (Note that addition is not
necessarily performed before
subtraction.)
Answer 60 – 30 ÷ 3 • 5 + 7 = 17
Example
Problem Simplify 900 ÷ (6 + 3 • 8) – 10.
When there are grouping symbols within grouping symbols, compute from the inside
to the outside. That is, begin simplifying the innermost grouping symbols first. Two
examples are shown.
Example
Problem Simplify 4 – 3[20 – 3 • 4 – (2 + 4)] ÷ 2.
4 – 3 Subtract.
1
Answer 4 – 3[20 – 3 • 4 – (2 + 4)] ÷ 2 = 1
Remember that parentheses can also be used to show multiplication. In the example
that follows, the parentheses are not a grouping symbol; they are a multiplication
symbol. In this case, since the problem only has multiplication and division, we
compute from left to right. Be careful to determine what parentheses mean in any given
problem. Are they a grouping symbol or a multiplication sign?
Example
Problem Simplify 6 ÷ (3)(2).
Consider what happens if braces are added to the problem above: 6 ÷ {(3)(2)}. The
parentheses still mean multiplication; the additional braces are a grouping symbol.
According to the order of operations, compute what is inside the braces first. This
problem is now evaluated as 6 ÷ 6 = 1. Notice that the braces caused the answer to
change from 1 to 4.
1) Perform all operations within grouping symbols first. Grouping symbols include:
parentheses ( ), braces { }, brackets [ ], and fraction bars.
2) Evaluate exponents and roots of numbers, such as square roots.
3) Multiply and Divide, from left to right.
4) Add and Subtract, from left to right.
Some people use a saying to help them remember the order of operations. This saying
is called PEMDAS or “Please Excuse My Dear Aunt Sally.” The first letter of each word
begins with the same letter of an arithmetic operation.
3 Real Numbers
Algebra involves the solution of problems using variables, expressions, and equations.
This topic focuses on variables and expressions and you will learn about the types of
expressions used in algebra.
One thing that separates algebra from arithmetic is the variable. A variable is a letter
or symbol used to represent a quantity that can change. Any letter can be used, but x
and y are common. You may have seen variables used in formulas, like the area of a
rectangle. To find the area of a rectangle, you multiply length times width, written using
the two variables l and w.
l•w
Here, the variable l represents the length of the rectangle. The variable w represents
the width of the rectangle.
1
You may be familiar with the formula for the area of a triangle. It is b•h.
2
Here, the variable b represents the base of the triangle, and the variable h represents
1
the height of the triangle. The in this formula is a constant. A constant, unlike a
2
variable, is a quantity that does not change. A constant is often a number.
Example
Problem Identify the constant and variable in the expression
24 – x.
Answer 24 is the constant. Since 24 cannot
x is the variable. change its value, it is a
constant. The variable
is x, because it could
be 0, or 2, or many
other numbers.
12 3 1
3 • 25 + 4 25 5 142 − − 2.45 + 13
4 4 4
1
a + 10 48 • c 100 – x l•w b•h
2
To evaluate an expression means to find its value. If there are variables in the
expression, you will be asked to evaluate the expression for a specified value for the
variable.
The first step in evaluating an expression is to substitute the given value of a variable
into the expression. Then you can finish evaluating the expression using arithmetic.
Example
Problem Evaluate 24 – x when x = 3.
24 – x Substitute 3 for the x
24 – 3 in the expression.
24 – 3 = 21 Subtract to complete
the evaluation.
Answer 21
When you have two variables, you substitute each given value for each variable.
Example
Problem Evaluate l • w when l = 3 and w = 8.
l•w Substitute 3 for l in
3•8 the expression and
8 for w.
3 • 8 = 24 Multiply.
Answer 24
When you multiply a variable by a constant number, you don’t need to write the
multiplication sign or use parentheses. For example, 3a is the same as 3 • a.
Notice that the sign • is used to represent multiplication. This is because the
multiplication sign × looks a lot like the letter x, especially when handwritten. Because
of this, it’s best to use parentheses or the • sign to indicate multiplication of numbers.
Example
Problem Evaluate 4x – 4 when x = 10.
4x – 4 Substitute 10 for x in
the expression.
4(10) – 4
Answer 36
Since the variables are allowed to vary, there are times when you want to evaluate the
same expression for different values for the variable.
Example
Problem John is planning a rectangular garden that is 2 feet
wide. He hasn’t decided how long to make it, but he’s
considering 4 feet, 5 feet, and 6 feet. He wants to put a
short fence around the garden. Using x to represent
the length of the rectangular garden, he will need x + x
+ 2 + 2, or 2x + 4, feet of fencing.
2x + 4 For x = 4, substitute 4
2(4) + 4 for x in the expression.
Evaluating expressions for many different values for the variable is one of the powers
of algebra. Computer programs are written to evaluate the same expression (usually a
very complicated expression) for millions of different values for the variable(s).
Adding real numbers follows the same rules as adding integers. The number 0 has
some special attributes that are very important in algebra. Knowing how to add these
numbers can be helpful in real-world situations as well as algebraic situations.
The rules for adding integers apply to other real numbers, including rational numbers.
To add two numbers with the same sign (both positive or both negative)
• Add their absolute values.
• Give the sum the same sign.
To add two numbers with different signs (one positive and one negative)
• Find the difference of their absolute values. (Note that when you find the
difference of the absolute values, you always subtract the lesser absolute
value from the greater one.)
• Give the sum the same sign as the number with the greater absolute value.
Remember—to add fractions, you need them to have the same denominator. This is
still true when one or more of the fractions are negative.
Example
Problem 3 6 2
Find − +− +
7 7 7
9 2 7 9 2
− + =− Since − , the
7 7 7 7 7
sign of the final sum is
the same as the sign
9
of − .
7
Answer 3 6 2 7
− + − + = −
7 7 7 7
Example
Problem 3 7
Find −2 +
4 8
3 7
2 −
4 8
3
First rewrite 2 as an
3 2(4) + 3 11 4
2 = =
4 4 4 improper fraction, then
rewrite the fraction
11 11 • 2 22 using a common
= =
4 4•2 8 denominator.
22 7
−
8 8
22 7 15 Subtract the
− =
8 8 8 numerators and keep
the same denominator.
Simplify to lowest
terms, if possible.
3 7
Answer 3 7 15 Since −2 , the
−2 + = − 4 8
4 8 8
sign of the final sum is
the same as the sign of
3
−2 .
4
When you add decimals, remember to line up the decimal points so you are adding
tenths to tenths, hundredths to hundredths, and so on.
Example
Problem Find 27.832 + (−3.06).
27.832
− 3.06 |−3.06| = 3.06
24.772
Subtraction and addition are closely related. They are called inverse operations,
because one “undoes” the other. So, just as with integers, you can rewrite subtraction
as addition to subtract real numbers.
Additive Inverses
Inverse operations, such as addition and subtraction, are a key idea in algebra.
Suppose you have R10 and you loan a friend R5. An hour later, she pays you back the
R5 she borrowed. You are back to having R10. You could represent the transaction
like this:
10 – 5 + 5 = 10.
So, adding a number and then subtracting the same number is like adding 0.
Thinking about this idea in terms of opposite numbers, you can also say that a number
plus its opposite is also 0. Notice that each example below consists of a positive and
a negative number pair added together.
Two numbers are additive inverses if their sum is 0. Since this means the numbers are
opposites (same absolute value but different signs), "additive inverse" is another, more
formal term for the opposite of a number. (Note that 0 is its own additive inverse.)
You can use the additive inverses or opposites to rewrite subtraction as addition. If you
are adding two numbers with different signs, you find the difference between their
absolute values and keep the sign of the number with the greater absolute value.
When the greater number is positive, it's easy to see the connection.
13 + (−7) = 13 – 7
Both equal 6.
Let’s see how this works. When you add positive numbers, you are moving forward,
facing in a positive direction.
When you subtract positive numbers, you can imagine moving backward, but still
facing in a positive direction.
Now let's see what this means when one or more of the numbers is negative.
Recall that when you add a negative number, you move forward, but face in a negative
direction (to the left).
How do you subtract a negative number? First face and move forward in a negative
direction to the first number, −2. Then continue facing in a negative direction (to the
left), but move backward to subtract −3.
But isn’t this the same result as if you had added positive 3 to −2? −2 + 3 = 1.
In each addition problem, you face one direction and move some distance forward. In
the paired subtraction problem, you face the opposite direction and then move the
same distance backward. Each gives the same result!
To subtract a real number, you can rewrite the problem as adding the opposite
(additive inverse).
Note, that while this always works, whole number subtraction is still the same. You can
subtract 38 – 23 just as you have always done. Or, you could also rewrite it as
38 + (−23). Both ways you will get the same answer.
38 – 23 = 38 + (−23) = 15.
Example
Problem Find 23 – 73.
Example
Problem Find 382 – (−93).
Another way to think about subtracting is to think about the distance between the two
numbers on the number line. In the example above, 382 is to the right of 0 by 382 units,
and −93 is to the left of 0 by 93 units. The distance between them is the sum of their
distances to 0: 382 + 93.
Example
Problem 1 3
Find 22 − x , when x = −
3 5
1 3 Substitute −
3
− −
3 5
22 5
for x in the
expression.
1 3 Rewrite the
22 +
3 5 subtraction as
adding the
opposite. The
3
opposite of −
5
3
is .
5
numerator!)
before adding.
Answer 14
22
15
When you have more than two real numbers to add or subtract, work from left to right
as you would when adding more than two whole numbers. Be sure to change
subtraction to addition of the opposite when needed.
Example
Problem Find −23 + 16 – (−32) – 4 + 6.
−23 + 16 – (−32) – 4 Start with −23 + 16. The
+6 addends have different
−7 – (−32) – 4 + 6 signs, so find the
difference and use the
sign of the addend with
the greater absolute
value. −23 + 16 = −7.
−7 – (−32) – 4 + 6 Now you have −7 –
−7 + 32 – 4 + 6 (−32). Rewrite this
subtraction as addition
of the opposite. The
opposite of −32 is 32, so
this becomes −7 + 32,
which equals 25.
25 – 4 + 6 You now have 25 – 4.
You could rewrite this as
an addition problem, but
you don't need to.
21 + 6
Complete the final
addition of 21 + 6.
After addition and subtraction, the next operations you learned how to do were
multiplication and division. You may recall that multiplication is a way of computing
“repeated addition,” and this is true for negative numbers as well.
Multiplication and division are inverse operations, just as addition and subtraction are.
You may recall that when you divide fractions, you multiply by the reciprocal.
Multiplying real numbers is not that different from multiplying whole numbers and
positive fractions. However, you haven't learned what effect a negative sign has on the
product.
With whole numbers, you can think of multiplication as repeated addition. Using the
number line, you can make multiple jumps of a given size. For example, the following
picture shows the product 3 • 4 as 3 jumps of 4 units each.
So, to multiply 3 (−4), you can face left (toward the negative side) and make three
“jumps” forward (in a negative direction).
The product of a positive number and a negative number (or a negative and a positive)
is negative. You can also see this by using patterns. In the following list of products,
the first number is always 3. The second number decreases by 1 with each row (3, 2,
1, 0, −1, −2). Look for a pattern in the products of these numbers. What numbers would
fit the pattern for the last two products?
3(3) = 9
3(2) = 6
3(1) = 3
3(0) = 0
3(−1) = ?
3(−2) = ?
Notice that the pattern is the same if the order of the factors is switched:
3(3) = 9
2(3) = 6
1(3) = 3
0(3) = 0
−1(3) = ?
−2(3) = ?
Take a moment to think about that pattern before you read on.
If you continue the pattern further, you see that multiplying 3 by a negative integer
gives a negative number. This is true in general.
You can use the pattern idea to see how to multiply two negative numbers. Think about
how you would complete this list of products.
−3(3) = −9
−3(2) = −6
−3(1) = −3
−3(0) = 0
−3(−1) = ?
−3(−2) = ?
Example
Problem Find −3.8(0.6).
Example
Problem 3 2
Find − −
4 5
Example
Problem Find 43y when y = –3.
To summarise:
You can see that the product of two negative numbers is a positive number. So, if you
are multiplying more than two numbers, you can count the number of negative factors.
Example
Problem Find 3(−6)(2)( −3)( −1).
Answer 3(−6)(2)( −3)( −1) = −108 Since there are an odd number
of negative factors, the product is
negative.
There is a number that can be added, again and again, without ever changing the sum.
That number, 0, is called the additive identity.
There is also a number that can be included as a factor as many times as you want,
and it will never change the value of the product. That number, 1, is called the
multiplicative identity.
7(1) = 7 −7(1) = −7
2 2
1(3.6) = 3.6 − (1) = −
23 23
x(1) = x (1)x = x
You can think of it in this way: Multiplying by 1 lets the other number keep its identity.
Multiplicative Inverses
You might recall that two numbers are additive inverses if their sum is 0, the additive
identity.
Two numbers are multiplicative inverses if their product is 1, the multiplicative identity.
2 3 23 6
and are multiplicative inverses because = = 1.
3 2 32 6
You may remember that when you divided fractions, you multiplied by the reciprocal.
Reciprocal is another name for the multiplicative inverse (just as opposite is another
name for additive inverse).
An easy way to find the multiplicative inverse is to just “flip” the numerator and
denominator as you did to find the reciprocal. Here are some examples:
4 9 4 9 36
The reciprocal of is because = = 1.
9 4 9 4 36
1 3 1 3
The reciprocal of 3 is because = = 1.
3 1 3 3
5 6 5 6 30
The reciprocal of − is − because − − = = 1.
6 5 6 5 30
When you divided by positive fractions, you learned to multiply by the reciprocal. You
also do this to divide real numbers.
Think about dividing a bag of 26 marbles into two smaller bags with the same number
of marbles in each. You can also say each smaller bag has one half of the marbles.
1
26 2 = 26 = 13
2
1
Notice that 2 and are reciprocals.
2
Dividing by
Number of bags Multiplying by reciprocal
number of bags
36 1 36 12(3)
3 = 12 36 = = = 12
3 3 3 3
36 1 36 9(4)
4 =9 36 = = =9
4 4 4 4
36 1 36 6(6)
6 =6 36 = = =6
6 6 6 6
Dividing by a number is the same as multiplying by its reciprocal. (That is, you use the
reciprocal of the divisor, the second number in the division problem.)
Example
Problem 4
Find 28 ÷
3
Now let's see what this means when one or more of the numbers is negative. A number
and its reciprocal have the same sign. Since division is rewritten as multiplication using
the reciprocal of the divisor, and taking the reciprocal doesn’t change any of the signs,
division follows the same rules as multiplication.
Rules of Division
When dividing, rewrite the problem as multiplication using the reciprocal of the
divisor as the second factor.
When one number is positive and the other is negative, the quotient is negative.
Example
Problem 5
Find 24 ÷ −
6
Example
2 2
4 − ( − 6) Substitute −
3
for x in the
3
expression.
Remember that a fraction bar also indicates division. So, a negative sign in front of a
fraction goes with the numerator, the denominator, or the whole fraction:
3 −3 3
− = = . In each case, the overall fraction is negative because there's only
4 4 −4
one negative in the division.
4 Integers
You've worked with numbers on a number line. You know how to graph numbers like
0, 1, 2, 3, etc. on the number line. There are other kinds of numbers that can be
graphed on the number line, too. Let's see what they look like and where they are
located on the number line.
In mathematics, it's sometimes helpful to talk about groups of things, which are called
sets. Numbers can be grouped into sets, and a particular number can belong to more
than one set.
You probably are familiar with the set of natural numbers, which are also called the
counting numbers. These are the numbers 1, 2, 3, and so on—the numbers we use
when counting.
The following illustration shows the natural numbers graphed on a number line.
The number line continues in both directions. The set of natural numbers only
continues to the right, so you can include 6, 7, and so on, all the way up into the
hundreds, thousands, and beyond. You can only show so much on one picture!
When 0 is added to the set of 1, 2, 3, and so on, it forms the set of whole numbers.
These are called “whole” because they have no fractional parts. (A trick to help you
remember which are natural numbers and which are whole numbers is to think of a
“hole,” which can be represented by 0. The whole ("hole") numbers include 0, the
natural numbers do not.)
The following illustration shows the whole numbers graphed on the number line.
When you work with something like temperature, you sometimes want to use numbers
that are less than zero, which are called negative numbers. Negative numbers are
written using a negative sign in front, such as −1, −5, and −30. These are read
"negative one," "negative five," and "negative thirty." (The negative sign should not be
read as "minus"; minus means subtraction.)
The numbers greater than 0 are called positive numbers and can be written with or
without the “+” sign. Notice that 0 is neither positive nor negative!
Integers are the numbers: …, −3, −2, −1, 0, 1, 2, 3, …. Notice that all of the whole
numbers are also integers. The following illustration shows the integers graphed on
the number line. The integers include zero and continue to the right and to the left.
The number line below shows all the integers between and including −5 and 5. Notice
that the positive integers go to the right: 1, 2, 3, and so on. The negative integers go
to the left: −1, −2, −3, and so on.
The distance between a number’s place on the number line and 0 is called the
number’s absolute value. To write the absolute value of a number, use short vertical
lines (|) on either side of the number. For example, the absolute value of −3 is written
|−3|.
|−23| = 23
|6| = 6
|817| = 817
|−3,000| = 3,000
Example
Problem Find |x| when x = −7.
|x| Substitute −7 for x in
|−7| the expression.
Answer |−7|= 7 Since −7 is 7 units from
0, the absolute value is
7.
To locate an integer on the number line, imagine standing on the number line at 0. If
the number is 0, you’re there. If the number is positive, face to the right—numbers
greater than 0. If the number is negative, face to the left—numbers less than 0. Then,
move forward the number of units equal to the absolute value of the number.
Example
Problem Find −4 on the number line. Then determine |−4|.
Opposites
You may have noticed that, except for 0, the integers come in pairs of positive and
negative numbers: 1 and −1, 3 and −3, 72 and −72, and so on. Each number is the
opposite of the other number in the pair: 72 is the opposite of −72, and −72 is the
opposite of 72.
A number and its opposite are the same distance from 0, so they have the same
absolute value.
The set of integers are all the whole numbers and their opposites.
Adding Integers
On an extremely cold day, the temperature may be −10. If the temperature rises 8
degrees, how will you find the new temperature? Knowing how to add integers is
important here and in much of algebra.
Since positive integers are the same as natural numbers, adding two positive integers
is the same as adding two natural numbers.
To add integers on the number line, you move forward, and you face right (the positive
direction) when you add a positive number.
As with positive numbers, to add negative integers on the number line, you move
forward, but you face left (the negative direction) when you add a negative number.
In both cases, the total number of units moved is the total distance moved. Since the
distance of a number from 0 is the absolute value of that number, then the absolute
value of the sum of the integers is the sum of the absolute values of the addends.
When both numbers are negative, you move left in a negative direction, and the sum
is negative. When both numbers are positive, you move right in a positive direction,
and the sum is positive.
To add two numbers with the same sign (both positive or both negative):
• Add their absolute values and give the sum the same sign.
Example
Problem Find −23 + (−16).
With more than two addends that have the same sign, use the same process with all
addends.
Example
Problem Find −27 + (−138) + (−55).
Consider what happens when the addends have different signs, like in the temperature
problem in the introduction. If it’s −10 degrees, and then the temperature rises 8
degrees, the new temperature is −10 + 8. How can you calculate the new temperature?
Using the number line below, you move forward to add, just as before. Face and move
in a positive direction (right) to add a positive number, and move forward in a negative
direction (left) to add a negative number.
See if you can find a rule for adding numbers without using the number line. Notice
that when you add a positive integer and a negative integer, you move forward in the
positive (right) direction to the first number, and then move forward in the negative (left)
direction to add the negative integer.
Since the distances overlap, the absolute value of the sum is the difference of their
distances. So, to add a positive number and a negative number, you subtract their
absolute values (their distances from 0.)
What is the sign of the sum? It’s pretty easy to figure out. If you moved further to the
right than you did to the left, you ended to the right of 0, and the answer is positive;
and if you move further to the left, the answer is negative. Let’s look at the illustration
below and determine the sign of the sum.
If you didn’t have the number line to refer to, you can find the sum of −1 + 4 by:
• Subtracting the distances from zero (the absolute values) 4 – 1 = 3; and then
• Applying the sign of the one furthest from zero (the largest absolute value). In
this case, 4 is further from 0 than −1, so the answer is positive: −1 + 4 = 3
If you didn’t have the number line to refer to, you can find the sum of −3 + 2 by:
• Subtracting the distances from zero (the absolute values) 3 – 2 = 1; and then
• Applying the sign of the one furthest from zero (the largest absolute value). In
this case, |−3| > |2|, so the answer is negative: −3 + 2 = −1
To add two numbers with different signs (one positive and one negative):
• Find the difference of their absolute values.
• Give the sum the same sign as the number with the greater absolute value.
Note that when you find the difference of the absolute values, you always subtract the
lesser absolute value from the greater one. The example below shows you how to
solve the temperature question that you considered earlier.
Example
Problem Find 8 + (−10).
Example
Problem Evaluate x + 37 when x = −22.
x + 37 Substitute −22 for x in the
−22 + 37 expression.
|−22| = 22 and |37| = The addends have different
37 signs. So find the
With more than two addends, you can add the first two, then the next one, and so on.
Example
Problem Find −27 + (−138) + 55.
Add two at a time, starting
with −27 + (−138).
−165 + 55 = −110
Since 165 > 55, the sign of
the final sum is the same
as the sign of −165.
Answer −27 + (−138) + 55 = −110
There are two cases to consider when adding integers. When the signs are the same,
you add the absolute values of the addends and use the same sign. When the signs
are different, you find the difference of the absolute values and use the same sign as
the addend with the greater absolute value.
The rules for adding real numbers refer to the addends being positive or negative. But
0 is neither positive nor negative.
It should be no surprise that you add 0 the way you always have—adding 0 doesn’t
change the value.
7+0=7 −7 + 0 = −7
2 2
0 + 3.6 = 3.6 − +0 = −
23 23
x+0=x 0+x=x
Notice that x + 0 = x and 0 + x = x. This means that it doesn’t matter which addend
comes first.
The number 0 is called the additive identity. The identity property of 0 states that adding
0 to other numbers doesn’t change their value. You can think of it in this way: adding
0 lets the other number keep its identity.
Rational Numbers
16 1
The fraction , mixed number 5 , and decimal 5.33… (or 5.3 ) all represent the
3 3
same number. This number belongs to a set of numbers that mathematicians call
rational numbers. Rational numbers are numbers that can be written as a ratio of two
integers. Regardless of the form used, 5.3 is rational because this number can be
16
written as the ratio of 16 over 3, or .
3
3 11
2 , as it can be written as
4 4
6 −16
−1.6, as it can be written as −1 =
10 10
4
4, as it can be written as
1
−10
-10, as it can be written as
1
1 3 11
In the following illustration, points are shown for 0.5 or , and for 2.75 or 2 = .
2 4 4
As you have seen, rational numbers can be negative. Each positive rational number
has an opposite. The opposite of 5.3 is −5.3 , for example.
Be careful when placing negative numbers on a number line. The negative sign means
the number is to the left of 0, and the absolute value of the number is the distance from
0. So to place −1.6 on a number line, you would find a point that is |−1.6| or 1.6 units
to the left of 0. This is more than 1 unit away, but less than 2.
Example
23
Problem Place − on a number line.
5
Answer
When two whole numbers are graphed on a number line, the number to the right on
the number line is always greater than the number on the left.
The same is true when comparing two integers or rational numbers. The number to the
right on the number line is always greater than the one on the left.
Numbers to Symbolic
Comparison
Compare Expression
−2 is greater than −3 because −2 is to the right
−2 and −3 −2 > −3 or −3 < −2
of −3
−3.1 is greater than −3.5 because −3.1 is to the −3.1 > −3.5 or
−3.5 and −3.1
right of −3.5 (see below) −3.5 < −3.1
There are also numbers that are not rational. Irrational numbers cannot be written as
the ratio of two integers.
Any square root of a number that is not a perfect square, for example 2 , is irrational.
Irrational numbers are most commonly written in one of three ways: as a root (such as
a square root), using a special symbol (such as ), or as a nonrepeating,
nonterminating decimal.
Nonterminating decimals have digits (other than 0) that continue forever. For example,
1
consider the decimal form of , which is 0.3333…. The 3s continue indefinitely. Or
3
1
the decimal form of , which is 0.090909…: the sequence “09” continues forever.
11
In addition to being nonterminating, these two numbers are also repeating decimals.
Their decimal parts are made of a number or sequence of numbers that repeats again
and again. A nonrepeating decimal has digits that never form a repeating pattern. The
value of 2 , for example, is 1.414213562…. No matter how far you carry out the
numbers, the digits will never repeat a previous sequence.
1
0.25 (or )
4
Terminating Rational
13
1.3 (or )
10
2
0.66… (or )
Nonterminating 3
Rational
and Repeating 321 107
3.242424… (or) =
99 33
Example
Problem Is −82.91 rational or
irrational?
The set of real numbers is made by combining the set of rational numbers and the set
of irrational numbers. The real numbers include natural numbers or counting numbers,
whole numbers, integers, rational numbers (fractions and repeating or terminating
decimals), and irrational numbers. The set of real numbers is all the numbers that have
a location on the number line.
Sets of Numbers
Natural numbers 1, 2, 3, …
Whole numbers 0, 1, 2, 3, …
Example
Problem What sets of numbers does 32 belong to?
Answer The number 32 belongs Every natural or
to all these sets of counting number
numbers: belongs to all of
these sets!
Natural numbers
Whole numbers
Integers
Rational numbers
Real numbers
Example
Problem What sets of numbers does 382.3 belong
to?
Answer 382.3 belongs to The number is
these sets of rational because it's
numbers: a repeating decimal.
1
It's equal to 382
3
1,147
or , or 382.3 .
3
Rational numbers
Real numbers
Example
Problem
What sets of numbers does − 5 belong to?
Real numbers
Exponential Vocabulary
←exponent
base → 103
103 is read as “10 to the third power” or “10 cubed.”
It means 10 • 10 • 10, or 1,000.
The exponent applies only to the number that it is next to. So in the expression xy4,
only the y is affected by the 4. xy4 means x • y • y • y • y.
You can see that there is quite a difference, so you have to be very careful.
Exponential Notation
72 = 7 • 7 = 49
You can read 72 as “seven squared.” This is because multiplying a number by itself is
called “squaring a number.” Similarly, raising a number to a power of 3 is called “cubing
the number.” You can read 73 as “seven cubed.”
You can read 25 as “two to the fifth power” or “two to the power of five.” Read 84 as
“eight to the fourth power” or “eight to the power of four.” This format can be used to
read any number written in exponential notation. In fact, while 63 is most commonly
read “six cubed,” it can also be read “six to the third power” or “six to the power of
three.”
To find the value of a number written in exponential form, rewrite the number as
repeated multiplication and perform the multiplication. Two examples are shown below.
Example
Problem Find the value of 42.
42 = 4 • 4 Rewrite as repeated
multiplication.
4 • 4 = 16 Multiply.
Answer 42 = 16
Example
Problem Find the value of 25.
2 • 2 • 2 • 2 • 2 Rewrite 25 as repeated
multiplication.
The base is 2, the number
being multiplied.
The exponent is 5, the
number of times to use 2
in the multiplication.
2 • 2 • 2 • 2 • 2 Perform multiplication.
4• 2 • 2 •2
8• 2 • 2
16 • 2
32
Answer 25 = 32
Writing repeated multiplication in exponential notation can save time and space.
Consider the example 5 • 5 • 5 • 5. We can use exponential notation to write this
repeated multiplication as 54. Since 5 is being multiplied, it is written as the base. Since
the base is used four times in the multiplication, the exponent is 4. The expression 5 •
5 • 5 • 5 can be rewritten in shorthand exponential notation as 5 4 and is read, “five to
the fourth power” or “five to the power of 4.”
To write repeated multiplication of the same number in exponential notation, first write
the number being multiplied as the base. Then count how many times that number is
used in the multiplication, and write that number as the exponent. Be sure to count the
numbers, not the multiplication signs, to determine the exponent.
Example
Problem Write 7 • 7 • 7 in exponential notation.
Shape number 1 2 3 4 5 6
Number of small squares 1x1=1 2x2=4 3x3=9 4x4=16 5x5=25 6x6=36
1 squared 12 1•1 1
2 squared 22 2•2 4
3 squared 32 3•3 9
4 squared 42 4•4 16
5 squared 52 5•5 25
6 squared 62 6•6 36
7 squared 72 7•7 49
8 squared 82 8•8 64
9 squared 92 9•9 81
The inverse operation of squaring a number is called finding the square root of a
number. Finding a square root is like asking, “what number multiplied by itself will give
me this number?” The square root of 25 is 5, because 5 multiplied by itself is equal to
25. Square roots are written with the mathematical symbol, called a radical sign, that
Example
Problem
Find 81 .
81 =9
Answer
81 =9
So far, our rules allow us to simplify expressions that have multiplication, division,
addition, subtraction or grouping symbols in them. What happens if a problem has
exponents or square roots in it? We need to expand our order of operation rules to
include exponents and square roots.
If the expression has exponents or square roots, they are to be performed after
parentheses and other grouping symbols have been simplified and before any
multiplication, division, subtraction, and addition that are outside the parentheses or
other grouping symbols.
Note that you compute from more complex operations to more basic operations.
Addition and subtraction are the most basic of the operations. You probably learned
these first. Multiplication and division, often thought of as repeated addition and
subtraction, are more complex and come before addition and subtraction in the order
of operations. Exponents and square roots are repeated multiplication and division,
and because they’re even more complex, they are performed before multiplication and
division. Some examples that show the order of operations involving exponents and
square roots are shown below.
Example
Problem Simplify 14 + 28 ÷ 22.
Example
Problem Simplify 32 • 23.
Example
Problem Simplify (3 + 4)2 + (8)(4).
49 + 32 Perform multiplication.
81 Add.
Answer (3 + 4)2 + (8)(4) = 81
You can use PEMDAS to remember the order in which you should evaluate the
expression. First, evaluate anything in Parentheses or grouping symbols. Next, look
for Exponents, followed by Multiplication and Division (reading from left to right), and
lastly, Addition and Subtraction (again, reading from left to right).
So, when you evaluate the expression 5x3 if x = 4, first substitute the value 4 for the
variable x. Then evaluate, using order of operations.
Example
Evaluate.
Problem 5x3 if x = 4
320 Multiply.
Notice the difference between the example above and the one below.
Example
Evaluate.
Problem (5x)3 if x = 4
203 Multiply.
Example
Evaluate.
Problem x3 if x = −4
−4 • −4 • −4 Evaluate.
−4 • −4 • −4 = −64 Multiply.
What does it mean when an exponent is 0 or 1? Let’s consider 251. Any value raised
to the power of 1 is just the value itself. This makes sense, because the exponent of 1
means the base is used as a factor only once. So the base stands alone, and 251 is
simply 25.
But what about a value raised to the power of 0? Use what you know about powers of
10 to find out what the power of 0 means. Below is a list of powers of 10 and their
equivalent values. Look at how the numbers change going down the left and right
columns. There’s a pattern there—see it?
Exponential
Expanded Form Value
Form
105 10 • 10 • 10 • 10 • 10 100,000
104 10 • 10 • 10 • 10 10,000
103 10 • 10 • 10 1,000
102 10 • 10 100
101 10 10
Moving down the table, each row drops one factor of 10 from the one above it. From
row 1 to row 2, the exponential form goes from 105 to 104. The value drops from
100,000 to 10,000. Another way to put this is that each value is divided by 10 to
produce the next value down the column.
Exponential
Expanded Form Value
Form
105 10 • 10 • 10 • 10 • 10 100,000
104 10 • 10 • 10 • 10 10,000
103 10 • 10 • 10 1,000
102 10 • 10 100
101 10 10
100 1 1
Following the pattern, you see that 100 is equal to 1. Would the pattern hold for a
different base? Say a base of 3?
35 3• 3 • 3 • 3 • 3 243
34 3• 3 • 3 • 3 81
33 3•3•3 27
32 3• 3 9
31 3 3
30 1 1
Yes! And the same pattern would hold true for any non-zero number or variable raised
to a power of 0, n0 = 1.
There is a conflict when the base is 0. You know that 03 = 0, 02 = 0, and 01 = 0, so you
would expect 00 to also be equal to 0. However, the above pattern says that any base
raised to the power of 0 is 1, so this leads you to believe that 0 0 = 1. Notice the
competing patterns—00 cannot be both 0 and 1! In this case, mathematicians say that
the value of 00 is undefined. (And remember that undefined is not the same as 0!)
Exponents of 0 or 1
Example
Evaluate.
Problem 2x0 if x = 9
Negative Exponents
What does it mean when an exponent is a negative integer? Let’s use the powers of
10 pattern from earlier to find out. If you continue this pattern to add some more rows,
beyond 100, you find the following:
Following the pattern, you see that 100 is equal to 1. Then you get into negative
1 1
exponents: 10-1 is equal to 1
, and 10-2 is the same as .
10 10 2
Following this pattern, a number with a negative exponent can be rewritten as the
reciprocal of the original number, with a positive exponent.
1 1
For example, 10-3 = 3
and 10-7= 7 .
10 10
To see if these patterns hold true for numbers other than 10, check out this table with
powers of 3.
3 -1 1 1
3 3
3 -2 1
or
1 1
3 2
3•3 9
The numbers are different, but the patterns are the same. We are now ready to state
the definition of a negative exponent.
Negative Exponent
1
For any non-zero number n and any integer x, n-x= . For
nx
1
example, 5-2= .
52
Note that the definition above states that the base, n must be a “non-zero number.”
exponent is the number of times the factor is used in the multiplication. The basic rules
of exponents are as follows:
Recall that exponents are a way of representing repeated multiplication. For example,
the notation 54 can be expanded and written as 5 • 5 • 5 • 5, or 625. And don’t forget,
the exponent only applies to the number immediately to its left, unless there are
parentheses.
What happens if you multiply two numbers in exponential form with the same base?
Consider the expression (23)(24). Expanding each exponent, this can be rewritten as
(2 • 2 • 2) (2 • 2 • 2 • 2) or 2 • 2 • 2 • 2 • 2 • 2 • 2. In exponential form, you would
write the product as 27. Notice, 7 is the sum of the original two exponents, 3 and 4.
To multiply exponential terms with the same base, simply add the exponents.
Example
Problem Simplify.
(a3)(a7)
When multiplying more complicated terms, multiply the coefficients and then multiply
the variables.
Example
Simplify.
Problem 5a4 • 7a6
Let’s simplify (52)4. In this case, the base is 52 and the exponent is 4, so you multiply
52 four times: (52)4 = 52 • 52 • 52 • 52 = 58 (using the Product Rule – add the exponents).
(52)4 is a power of a power. It is the fourth power of 5 to the second power. And we saw
above that the answer is 58. Notice that the new exponent is the same as the product
of the original exponents: 2 • 4 = 8.
This leads to another rule for exponents—the Power Rule for Exponents. To simplify
a power of a power, you multiply the exponents, keeping the base the same. For
example, (23)5 = 215.
Example
Problem Simplify.
6(c4)2
Example
Problem Simplify.
a2(a5)3
a 2+15
Let’s look at dividing terms containing exponential expressions. What happens if you
divide two numbers in exponential form with the same base? Consider the following
expression.
45
42
44444
You can rewrite the expression as: . Then you can cancel the common
44
4 4 444 444
factors of 4 in the numerator and denominator: =
44 1
Finally, this expression can be rewritten as 43 using exponential notation. Notice that
the exponent, 3, is the difference between the two exponents in the original expression,
5 and 2.
45
So, 2 = 45-2 = 43.
4
Be careful that you subtract the exponent in the denominator from the exponent in the
numerator.
x7 xxxxxxx 1 1
= = = 2 = x −2
x 9
x x x x x x x xx xx x
or
x7
= x7−9 = x-2
x9
So, to divide two exponential terms with the same base, subtract the exponents.
42 0
42 16
Notice that 2 = 4 . And we know that 2 = = 1. So this may help to explain
4 4 16
why 40 = 1.
Example
Problem 49
Evaluate.
44
49−4 These two exponents have the
same base, 4. According to the
Quotient Rule, you can subtract
the power in the denominator
from the power in the numerator.
Answer 49
= 45
44
When dividing terms that also contain coefficients, divide the coefficients and then
divide variable powers with the same base by subtracting the exponents.
Example
Problem 12x 4
Simplify.
2x
2 x variable factors.
There are rules that help when multiplying and dividing exponential expressions with
the same base. To multiply two exponential terms with the same base, add their
exponents. To raise a power to a power, multiply the exponents. To divide two
exponential terms with the same base, subtract the exponents.
Once the rules of exponents are understood, you can begin solving more complicated
expressions more easily. Recall that when you take a power to a power, you multiply
the exponents, (xa)b= xa•b.
What happens when you raise an entire expression inside parentheses to a power?
You can use the techniques you already know to simplify this expression.
Notice that the exponent is applied to each factor of 2a. So, we can eliminate the middle
steps.
For any nonzero numbers a and b and any integer x, (ab)x = ax • bx.
Caution! Do not try to apply this rule to sums. Think about the expression (2 + 3) 2.
Does (2 + 3)2 equal 22 + 32 ? No, it does not—(2 + 3)2 = 52 = 25 and 22 + 32 = 4 + 9 =
13. So, you can only use this rule when the numbers inside the parentheses are being
multiplied (or divided, as we will see next).
Example
Problem Simplify. (2yz)6
If the variable has an exponent with it, use the Power Rule: multiply the
exponents.
Example
Problem Simplify. (−7a4b)2
Now let’s look at what happens if you raise a quotient to a power. Suppose you have
3
and raise it to the 3rd power.
4
3
3 3 3 3 3 3 3 3
3
4 = 4 4 4 = 4 4 4 = 43
You can see that raising the quotient to the power of 3 can also be written as the
numerator (3) to the power of 3, and the denominator (4) to the power of 3.
Similarly, if you are using variables, the quotient raised to a power is equal to the
numerator raised to the power over the denominator raised to power.
4
a a a a a a a a a a
4
b = = =
b b b b b b b b b 4
When a quotient is raised to a power, you can apply the power to the numerator and
denominator individually, as shown below.
4 4
a a
b = b4
Example
Problem 3
2xy
Simplify.
x
Answer 2xy
3
3
x = 8y
7 Scientific Notation
When working with very large or very small numbers, scientists, mathematicians, and
engineers often use scientific notation to express those quantities. Scientific notation
uses exponential notation. The following are examples of scientific notation.
Light year: number of miles light travels in one year, about 5,880,000,000,000
Scientific notation is 5.88 x 1012 miles.
Computation with very large numbers is made easier with scientific notation.
When a number is written in scientific notation, the exponent tells you if the term is a
large or a small number. A positive exponent indicates a large number and a negative
exponent indicates a small number that is between 0 and 1.
Since it’s so useful, let’s look more closely at the details of scientific notation format.
Scientific Notation
Look at the numbers below. Which of the numbers is written in scientific notation?
1 ≤1.85 < 10
1.85 x 10-2 yes
-2 is an integer
1 1
no is not an integer
1.083 10 2 2
Now let’s compare some numbers expressed in both scientific notation and standard
decimal notation in order to understand how to convert from one form to the other.
Take a look at the tables below. Pay close attention to the exponent in the scientific
notation and the position of the decimal point in the decimal notation.
Scientific Scientific
Decimal Notation Decimal Notation
Notation Notation
To write a large number in scientific notation, move the decimal point to the left to
obtain a number between 1 and 10. Since moving the decimal point changes the value,
you have to multiply the decimal by a power of 10 so that the expression has the same
value.
1,800.00 x 102
180.000 x 103
18.0000 x 104
1.80000 x 105
To write a small number (between 0 and 1) in scientific notation, you move the decimal
to the right and the exponent will have to be negative.
000.004 x 10-2
0000.04 x 10-3
00000.4 x 10-4
000004. x 10-5
0.00004 = 4 x 10-5
You may notice that the decimal point was moved five places to the right until you got
the number 4, which is between 1 and 10. The exponent is −5.
You can also write scientific notation as decimal notation. For example, the number of
miles that light travels in a year is 5.88 x 1012, and a hydrogen atom has a diameter of
5 x 10-8 mm. To write each of these numbers in decimal notation, you move the decimal
point the same number of places as the exponent. If the exponent is positive, move
the decimal point to the right. If the exponent is negative, move the decimal point to
the left.
For each power of 10, you move the decimal point one place. Be careful here and don’t
get carried away with the zeros—the number of zeros after the decimal point will
always be 1 less than the exponent because it takes one power of 10 to shift that first
number to the left of the decimal.
Numbers that are written in scientific notation can be multiplied and divided rather
simply by taking advantage of the properties of numbers and the rules of exponents
that you may recall. To multiply numbers in scientific notation, first multiply the numbers
that aren’t powers of 10 (the a in a x 10n). Then multiply the powers of ten by adding
the exponents.
This will produce a new number times a different power of 10. All you have to do is
check to make sure this new value is in scientific notation. If it isn’t, you convert it.
Example
Problem (3 x 108)(6.8 x 10-13)
In order to divide numbers in scientific notation, you once again apply the properties of
numbers and the rules of exponents. You begin by dividing the numbers that aren’t
powers of 10 (the a in a x 10n). Then you divide the powers of ten by subtracting the
exponents.
This will produce a new number times a different power of 10. If it isn’t already in
scientific notation, you convert it, and then you’re done.
Example
Problem 2.829×10-9
3.45×10-3
Regroup, using the associative
2.829 10
−9
3.45 10 −3 property.
10 −9
(0.82) −3 Divide the coefficients.
10
Notice that when you divide exponential terms, you subtract the exponent in the
denominator from the exponent in the numerator.
To multiply or divide numbers in scientific notation, you can use the commutative and
associative properties to group the exponential terms together and apply the rules of
exponents.
Grossman, P. 2009. Discrete mathematics for computing. (3rd ed) New York (NY):
Palgrave Macmillian.
Bogart, K, Drysdale, S, Stein, C and Kenneth Bogart, P. 2004. Discrete Math for
Computer Science Students.
9 Activities
Complete the activities on IIELearn.
10 Exercises
Refer to the workbook for exercises.
11 Glossary of Terms
addend A number added to one or more numbers to form a sum.
addition The sum of any number and 0 is equal to that number. The
property of 0 number 0 is often called the additive identity.
associative law For three or more numbers, the sum is the same regardless of
of addition how you group the numbers. For example, (6 + 2) + 1 = 6 + (2 +
1).
commutative Two numbers can be added in any order without changing the
law of addition sum. For example, 6 + 4 = 4 + 6.
difference The quantity that results from subtracting one number from
another, or from subtracting the subtrahend from the minuend.
distributive The product of a number and a sum is the same as the sum of
property of the product of the number and each of the addends making up
multiplication the sum. For example, 3(4 + 2) = 3(4) + 3(2).
over addition
divisor The number that is being divided into the dividend in a division
problem. In the problem 8 ÷ 2 = 4, 2 is the divisor.
expanded form A way to write a number as a sum of the value of its digits. For
example, thirty-two is written in expanded form as 30 + 2, or 3
tens + 2 ones, or (3 • 10) + (2 • 1).
exponent The number that indicates how many times the base is used as
a factor. In the example of 53, 3 is the exponent and means that
5 is used three times as a factor: 5 • 5 • 5.
multiplication The product of any number and 1 is equal to that number. The
property of 1 number 1 is often called the multiplicative identity.
place value The value of a digit based on its position within a number.
product The result when two numbers are multiplied. For example, the
product of 4 • 5 is 20.
radical sign The symbol used for square root and other roots. It looks like
and the number is written under it. For example, the square
raised to the When a base has an exponent, it can be said that the base is
power “raised to the power” of the exponent. For example, 35 is read
as “3 raised to the 5th power.”
remainder The amount left over after dividing a number. In the problem 11
÷ 4 = 2 R3, 3 is the remainder.
square root A value that can be multiplied by itself to give the original
number. For example, if the original number is 9, then 3 is its
square root because 3 multiplied by itself (32, pronounced "3
squared") equals 9. The symbol used for a square root is called
a radical sign and goes on top of the number. The square root
of 9 is written as 9.
standard form A way to write a number using digits. For example, thirty-two is
written in standard form as 32.
sum The result when two or more numbers are added; the quantity
that results from addition.
additive inverse Any two numbers whose sum is zero, such as 3 and -3,
because 3 + (-3) = 0.
associative For three or more real numbers, the sum is the same
property of addition regardless of how you group the numbers. For example,
(6 + 2) + 1 = 6 + (2 + 1).
associative For three or more real numbers, the product is the same
property of regardless of how you group the numbers. For example,
multiplication (3 • 5) • 7 = 3 • (5 • 7).
identity property of When you add 0 to any number, the sum is the same as
0 the original number. For example, 55 + 0 = 55.
identity property of When you multiply any number by 1, the product is the
quotient 8
The result of a division problem. In the problem =4,4
2
is the quotient.
rational numbers Numbers that can be written as the ratio of two integers,
where the denominator is not zero.
2 7
product of 1. For example, and are reciprocals of
7 2
each other.
associative For three or more real numbers, the sum is the same
property of regardless of how you group the numbers. For example, (6 +
addition 2) + 1 = 6 + (2 + 1).
like terms Terms that contain the same variables raised to the same
powers. For example, 3x and −8x are like terms, as are 8xy2
and 0.5xy2.
power rule for To raise a power to a power, multiply the exponents. (xa)b =
exponents
xa•b
product rule for To multiply two exponential terms with the same base, add
exponents their exponents. (xa)(xb) = xa+b
quotient rule for For any non-zero number x and any integers a and b:
exponents x a a −b
=x
xb
Equations are mathematical statements that combine two expressions of equal value.
An algebraic equation can be solved by isolating the variable on one side of the
equation using the properties of equality. To check the solution of an algebraic
equation, substitute the value of the variable into the original equation.
Complex, multi-step equations often require multi-step solutions. Before you can begin
to isolate a variable, you may need to simplify the equation first. This may mean using
the distributive property to remove parentheses, or multiplying both sides of an
equation by a common denominator to get rid of fractions. Sometimes it requires both
techniques.
Solving inequalities is very similar to solving equations, except you have to reverse the
inequality symbols when you multiply or divide both sides of an inequality by a negative
number. Since inequalities can have multiple solutions, it is customary to represent the
solution to an inequality graphically as well as algebraically. Because there is usually
more than one solution to an inequality, when you check your answer you should check
the end point and one other value to check the direction of the inequality.
Algebraic equations contain variables, symbols that stand for an unknown quantity.
Variables are often represented with letters, like x, y, or z. Sometimes a variable is
multiplied by a number. This number is called the coefficient of the variable. For
example, the coefficient of 3x is 3.
An important property of equations is one that states that you can add the same
quantity to both sides of an equation and still maintain an equivalent equation.
Sometimes people refer to this as keeping the equation “balanced.” If you think of an
equation as being like a balance scale, the quantities on each side of the equation are
equal, or balanced.
Let’s look at a simple numeric equation, 3 + 7 =10, to explore the idea of an equation
as being balanced.
The expressions on each side of the equal sign are equal, so you can add the same
value to each side and maintain the equality. Let’s see what happens when 5 is added
to each side.
3 + 7 + 5 = 10 + 5
Since each expression is equal to 15, you can see that adding 5 to each side of the
original equation resulted in a true equation. The equation is still “balanced.”
On the other hand, let’s look at what would happen if you added 5 to only one side of
the equation.
3 + 7 = 10
3 + 7 + 5 = 10
15 ≠ 10
Adding 5 to only one side of the equation resulted in an equation that is false. The
equation is no longer “balanced”, and it is no longer a true equation!
If two expressions are equal to each other, and you add the same value to both
sides of the equation, the equation will remain equal.
When you solve an equation, you find the value of the variable that makes the equation
true. In order to solve the equation, you isolate the variable. Isolating the variable
means rewriting an equivalent equation in which the variable is on one side of the
equation and everything else is on the other side of the equation.
When the equation involves addition or subtraction, use the inverse operation to “undo”
the operation in order to isolate the variable. For addition and subtraction, your goal is
to change any value being added or subtracted to 0, the additive identity.
Example
Problem Solve x – 6 = 8.
Since subtraction can be written as addition (adding the opposite), the addition
property of equality can be used for subtraction as well. So just as you can add the
same value to each side of an equation without changing the meaning of the equation,
you can subtract the same value from each side of an equation.
Example
Problem Solve x + 7 = 42.
Answer x = 35
Example (Advanced)
Problem Solve 12.5 + x = -7.5.
The examples above are sometimes called one-step equations because they require
only one step to solve. In these examples, you either added or subtracted a constant
from both sides of the equation to isolate the variable and solve the equation.
With any equation, you can check your solution by substituting the value for the
variable in the original equation. In other words, you evaluate the original equation
using your solution. If you get a true statement, then your solution is correct.
Example
Problem Solve x + 10 = –65. Check your solution.
Just as you can add or subtract the same exact quantity on both sides of an equation,
you can also multiply both sides of an equation by the same quantity to write an
equivalent equation. Let’s look at a numeric equation, 5 • 3 = 15, to start. If you multiply
both sides of this equation by 2, you will still have a true equation.
5 • 3 = 15
5 • 3 • 2 = 15 • 2
30 = 30
If two expressions are equal to each other and you multiply both sides by the same
number, the resulting expressions will also be equivalent.
When the equation involves multiplication or division, you can “undo” these operations
by using the inverse operation to isolate the variable. When the operation is
multiplication or division, your goal is to change the coefficient to 1, the multiplicative
identity.
Example
Problem Solve 3x = 24. Check your solution.
You can also multiply the coefficient by the multiplicative inverse (reciprocal) in order
to change the coefficient to 1.
Example
Problem 1
Solve x = 8 . Check your solution.
2
1 1 1
x =8 The coefficient of x is
2 2 2
. Since the multiplicative
1
1 inverse of is 2, you can
2 x = 2(8) 2
2 multiply both sides of the
equation by 2 to get a
2 coefficient of 1 for the
x = 16 variable.
2
x = 16
Multiply.
Check 1 Check by substituting your
(16) = 8 solution into the original
2
equation.
16
=8
2
8=8
The solution is correct!
Answer x = 16
Example
Problem 1
Solve − x = 2 . Check your solution.
4
1
( −4) − x = ( −4)2 Multiply.
4
Answer x = −8
Example (Advanced)
Problem 7 x
Solve − = . Check your solution.
2 10
There are some equations that you can solve in your head quickly. For example – what
is the value of y in the equation 2y = 6? Chances are you didn’t need to get out a pencil
and paper to calculate that y = 3. You only needed to do one thing to get the answer,
divide 6 by 2.
1 1
Other equations are more complicated. Solving 4 t + = 6 without writing
3 2
anything down is difficult! That’s because this equation contains not just a variable but
also fractions and terms inside parentheses. This is a multi-step equation, one that
takes several steps to solve. Although multi-step equations take more time and more
operations, they can still be simplified and solved by applying basic algebraic rules.
Remember that you can think of an equation as a balance scale, with the goal being
to rewrite the equation so that it is easier to solve but still balanced. The addition
property of equality and the multiplication property of equality explain how you can
keep the scale, or the equation, balanced. Whenever you perform an operation to one
side of the equation, if you perform the same exact operation to the other side, you’ll
keep both sides of the equation equal.
If the equation is in the form, ax + b = c, where x is the variable, you can solve the
equation as before. First “undo” the addition and subtraction, and then “undo” the
multiplication and division.
Example
Problem Solve 3y + 2 = 11.
Example
Problem 1
Solve x −2=3.
4
1
x −2 = 3 Add 2 from to both sides of the
4
equation to get the term with the
+2 +2 variable by itself.
1
x =5
4
4x
= 5(4) Multiply both sides of the equation by 4
4 to get a coefficient of 1 for the variable.
x = 20
Answer x = 20
If the equation is not in the form, ax + b = c, you will need to perform some additional
steps to get the equation in that form.
In the example below, there are several sets of like terms. You must first combine all
like terms.
Example
Problem Solve 3x + 5x + 4 – x + 7 = 88.
Answer x = 11
Some equations may have the variable on both sides of the equal sign. We need to
“move” one of the variable terms in order to solve the equation.
Example
Problem Solve 6x + 5 = 10 + 5x. Check your solution.
Here are some steps to follow when you solve multi-step equations.
Example
Problem Solve for y.
-20y + 15 = 2 - 16y + 11
Answer 1
y =
2
Example (Advanced)
Problem Solve 3y + 10.5 = 6.5 + 2.5y. Check your solution.
3 y + 10.5 = 6.5 + 2.5 y This equation has y terms
on both the left and the
right. To solve an equation
like this, you must first get
the variables on the same
side of the equal sign.
Answer y = -8
What this means is that when a number multiplies an expression inside parentheses,
you can distribute the multiplication to each term of the expression individually. Then,
you can follow the routine steps described above to isolate the variable to solve the
equation.
Example
Problem Solve for a.
4(2a + 3) = −3(a − 1) + 31
If you prefer not working with fractions, you can use the multiplication property of
equality to multiply both sides of the equation by a common denominator of all of the
fractions in the equation. See the example below.
Example
Problem 1 3
Solve x −3=2− x by clearing the fractions in
2 4
the equation first.
+ 3x + 3x
5 x − 12 = 8 Multiply.
+ 12 + 12
Add 3x to both sides to
5 x 20
= move the variable terms
5 5 to only one side.
x=4 Add 12 to both sides to
move the constant terms
to the other side.
© The Independent Institute of Education (Pty) Ltd 2021 Page 100 of 332
IIE Module Manual MAPC5112
Answer x=4
Of course, if you like to work with fractions, you can just apply your knowledge of
operations with fractions and solve.
Example
Problem 1 3
Solve x −3=2− x.
2 4
1 3 3
x −3 = 2− x Add x to both sides to get
2 4 4
3 3 the variable terms on one
+ x = + x side.
4 4
1 3 2 3 5
5 + = + =
x−3 = 2 2 4 4 4 4
4 3 3
+3 +3 − + =0
4 4
5 Add 3 to both sides to get the
x =5
4 constant terms on the other
side.
4 5 4
x= 5
5 4 5 To get a coefficient of 1,
20
x= multiply the variable term by
5 its multiplicative inverse.
x=4
Answer x=4
© The Independent Institute of Education (Pty) Ltd 2021 Page 101 of 332
IIE Module Manual MAPC5112
Example (Advanced)
Problem 1 3a + 4
Solve (2 + a ) = .
2 32
Check your solution.
a 3a + 4
1+ =
2 9
18 + 9a = 2(3a + 4)
© The Independent Institute of Education (Pty) Ltd 2021 Page 102 of 332
IIE Module Manual MAPC5112
18 + 9a = 6a + 8
18 + 9a = 6a + 8
− 6a − 6a Then isolate the variable, and
solve the remaining one-step
18 + 3a = 8 problem.
18 + 3a = 8
−18 − 18
3a = − 10
3a −10
=
3 3
10
a=−
3
© The Independent Institute of Education (Pty) Ltd 2021 Page 103 of 332
IIE Module Manual MAPC5112
10
3 − + 4
1 10
2 + − =
3
2 3 32
1 10 −10 + 4
2+ − =
2 3 9
1 6 10 −10 + 4
+ − =
2 3 3 9
1 4 −10 + 4
− =
2 3 9
−4 −10 + 4
=
6 9
−4 −6
=
6 9
2 2 2 3
− • =− •
3 2 3 3
2 2
− =−
3 3
This is a true statement, so
the solution is correct.
Answer 10
a=−
3
© The Independent Institute of Education (Pty) Ltd 2021 Page 104 of 332
IIE Module Manual MAPC5112
Regardless of which method you use to solve equations containing variables, you will
get the same answer. You can choose the method you find easier! Remember to check
your answer by substituting your solution into the original equation.
Just as you can clear fractions from an equation, you can clear decimals from the
equation in the same way. Find a common denominator and use the multiplication
property of equality to multiply both sides of the equation.
Example
Problem Solve 0.4x – 0.25 = 1.75 by clearing the decimals first.
Complex, multi-step equations often require multi-step solutions. Before you can begin
to isolate a variable, you may need to simplify the equation first. This may mean using
the distributive property to remove parentheses, or multiplying both sides of an
equation by a common denominator to get rid of fractions. Sometimes it requires both
techniques.
When you follow the steps to solve an equation, you try to isolate the variable. You
have a solution when you get the equation x = some value. There are equations,
however, that have no solution, and other equations that have an infinite number of
solutions. How does this work?
Let’s apply the steps for solving an algebraic equation to the equation below.
© The Independent Institute of Education (Pty) Ltd 2021 Page 105 of 332
IIE Module Manual MAPC5112
Example
Problem Solve for x.
12 + 2x – 8 = 7x + 5 – 5x
This is not a solution! You did not find a value for x. Solving for x the way you know
how; you arrive at the false statement 4 = 5. Surely 4 cannot be equal to 5!
This may make sense when you consider the second line in the solution where like
terms were combined. If you multiply a number by 2 and add 4 you would never get
the same answer as when you multiply that same number by 2 and add 5. Since there
is no value of x that will ever make this a true statement, the solution to the equation
above is “no solution”.
Be careful that you do not confuse the solution x = 0 with “no solution”. The solution x
= 0 means that the value 0 satisfies the equation, so there is a solution. “No solution”
means that there is no value, not even 0, which would satisfy the equation.
Also, be careful not to make the mistake of thinking that the equation 4 = 5 means that
4 and 5 are values for x that are solutions. If you substitute these values into the original
equation, you’ll see that they do not satisfy the equation. This is because there is truly
no solution—there are no values for x that will make the equation 12 + 2x – 8 = 7x + 5
– 5x true.
Example
Problem Solve for x.
3x + 8 = 3(x + 2)
© The Independent Institute of Education (Pty) Ltd 2021 Page 106 of 332
IIE Module Manual MAPC5112
Example (Advanced)
Problem Solve for y.
8y = 2[3(y + 4) + y]
You have seen that if an equation has no solution, you end up with a false statement
instead of a value for x. You can probably guess that there might be a way you could
end up with a true statement instead of a value for x.
Example
Problem Solve for x.
5x + 3 – 4x = 3 + x
−x −x
Isolate the x term by
3=3 subtracting x from both sides.
You arrive at the true statement “3 = 3”. When you end up with a true statement like
this, it means that the solution to the equation is “all real numbers”. Try substituting x
3
= 0 into the original equation—you will get a true statement! Try x = − , and it also
4
will check!
© The Independent Institute of Education (Pty) Ltd 2021 Page 107 of 332
IIE Module Manual MAPC5112
This equation happens to have an infinite number of solutions. Any value for x that you
can think of will make this equation true. When you think about the context of the
problem, this makes sense—the equation x + 3 = 3 + x means “some number plus 3
is equal to 3 plus that same number.” We know that this is always true—it’s the
commutative property of addition!
Example
Problem Solve for x.
5(x – 7) + 42 = 3x + 7 + 2x
−5 x − 5x
Isolate the x term by
7= 7
subtracting 5x from
both sides. You get the
true statement 7 = 7, so
you know that x can be
all real numbers.
Answer x = all real numbers
When solving an equation, multiplying both sides of the equation by zero is not a good
choice. Multiplying both side of an equation by 0 will always result in an equation of 0
= 0, but an equation of 0 = 0 does not help you know what the solution to the original
equation is.
Example
Problem Solve for x.
x=x+2
© The Independent Institute of Education (Pty) Ltd 2021 Page 108 of 332
IIE Module Manual MAPC5112
Some equations are considered special cases. These are equations that have no
solution and equations whose solution is the set of all real numbers. When you use the
steps for solving an equation, and you get a false statement rather than a value for the
variable, there is no solution. When you use the steps for solving an equation, have
avoided multiplying both sides of the equation by zero, and you get a true statement
rather than a value for the variable, the solution is all real numbers. Algebra is a
powerful tool for modeling and solving real-world problems.
Sometimes there is a range of possible values to describe a situation. When you see
a sign that says “Speed Limit 25,” you know that it doesn’t mean that you have to drive
exactly at a speed of 25 miles per hour (mph). This sign means that you are not
supposed to go faster than 25 mph, but there are many legal speeds you could drive,
such as 22 mph, 24.5 mph or 19 mph. In a situation like this, which has more than one
acceptable value, inequalities are used to represent the situation rather than equations.
What is an inequality?
Inequality Signs
x y x is not equal to y.
Example: The number of days in a week is not equal to 9.
© The Independent Institute of Education (Pty) Ltd 2021 Page 109 of 332
IIE Module Manual MAPC5112
The important thing about inequalities is that there can be multiple solutions. For
example, the inequality “31 ≥ the number of days in a month” is a true statement for
every month of the year—no month has more than 31 days. It holds true for January,
which has 31 days (31 ≥ 31); September, which has 30 days (31 ≥ 30); and February,
which has either 28 or 29 days depending upon the year (31 ≥ 28 and 31 ≥ 29).
The inequality x > y can also be written as y < x. The sides of any inequality can be
switched as long as the inequality symbol between them is also reversed.
You can solve most inequalities using the same methods as those for solving
equations. Inverse operations can be used to solve inequalities. This is because when
you add or subtract the same value from both sides of an inequality, you have
maintained the inequality. These properties are outlined in the blue box below.
Example
Problem Solve for x.
x +3 < 5
x + 3 5 Isolate the variable by
− 3 − 3 subtracting 3 from both
sides of the inequality.
x 2
Answer x<2
© The Independent Institute of Education (Pty) Ltd 2021 Page 110 of 332
IIE Module Manual MAPC5112
Just as you can check the solution to an equation, you can check a solution to an
inequality. First, you check the end point by substituting it in the related equation. Then
you check to see if the inequality is correct by substituting any other solution to see if
it is one of the solutions. Because there are multiple solutions, it is a good practice to
check more than one of the possible solutions. This can also help you check that your
graph is correct.
The example below shows how you could check that x < 2 is the solution to x + 3 < 5.
Example
Problem Check that x < 2 is the solution to x + 3 < 5.
The following examples show additional inequality problems. The graph of the solution
to the inequality is also shown. Remember to check the solution. This is a good habit
to build!
Example (Advanced)
Problem Solve for x.
15 37
+x >−
2 4
37 30
x− −
4 4
67
x−
4
© The Independent Institute of Education (Pty) Ltd 2021 Page 111 of 332
IIE Module Manual MAPC5112
Answer 67
x−
4
Example
Problem Solve for x.
x − 10 −12
x − 10 −12 Isolate the variable by
+ 10 + 10 adding 10 to both sides
of the inequality.
x −2
Answer x −2
The graph of this solution is shown below. Notice that a closed circle is used because
the inequality is “less than or equal to” ( ). The blue arrow is drawn to the left of the
point −2 because these are the values that are less than −2.
Example
Problem Check that x −2 is the solution to
x − 10 −12
x − 10 = −12 Substitute the end point
Does − 2 − 10 = −12? −2 into the related
equation
−12 = −12 x – 10 = −12.
Example
Problem Solve for a.
a − 17 > −17
© The Independent Institute of Education (Pty) Ltd 2021 Page 112 of 332
IIE Module Manual MAPC5112
Answer a 0
The graph of this solution is shown below. Notice that an open circle is used because
the inequality is “greater than” (>). The arrow is drawn to the right of 0 because these
are the values that are greater than 0.
Example
Problem Check that a > 0 is the solution to a − 17 > −17 .
Solving an inequality with a variable that has a coefficient other than 1 usually involves
multiplication or division. The steps are like solving one-step equations involving
multiplication or division EXCEPT for the inequality sign. Let’s look at what happens to
the inequality when you multiply or divide each side by the same number.
Let’s start with the 10 > 5 Let’s try again by starting with 10 > 5
true statement: the same true statement:
Next, multiply both 10 • 2 > 5 • 2 This time, multiply both sides 10 • −2 > 5 • −2
sides by the same by the same negative number:
positive number:
20 is greater than 20 > 10 Wait a minute! −20 is not −20 > −10
10, so you still have greater than −10, so you have
a true inequality: an untrue statement.
© The Independent Institute of Education (Pty) Ltd 2021 Page 113 of 332
IIE Module Manual MAPC5112
When you multiply You must “reverse” the −20 < −10
by a positive inequality sign to make the
number, leave the statement true:
inequality sign as it
is!
Whenever you multiply or divide both sides of an inequality by a negative number, the
inequality sign must be reversed in order to keep a true statement.
a b
If a > b, then , if c > 0
c c
a b
If a > b, then , if c < 0
c c
Keep in mind that you only change the sign when you are multiplying and dividing by
a negative number. If you add or subtract by a negative number, the inequality stays
the same.
Example (Advanced)
Problem Solve for x.
1
− x −12 x
3
© The Independent Institute of Education (Pty) Ltd 2021 Page 114 of 332
IIE Module Manual MAPC5112
1
Is − −12(2)
3 Pick a value greater
1
than , such as 2, to
1 36
− −24
3 check in the inequality.
It checks!
Answer 1
x
36
Example
Problem Solve for x.
3x > 12
Answer x4
© The Independent Institute of Education (Pty) Ltd 2021 Page 115 of 332
IIE Module Manual MAPC5112
There was no need to make any changes to the inequality sign because both sides of
the inequality were divided by positive 3. In the next example, there is division by a
negative number, so there is an additional step in the solution!
Example
Problem Solve for x.
−2x > 6
x −3
Check: Does − 2( −3) = 6 ? Check your solution by first
6=6 checking the end point −3, and
then checking another solution
Is − 2( −6) 6 ?
for the inequality.
12 6
It checks!
Answer x −3
Because both sides of the inequality were divided by a negative number, −2, the
inequality symbol was switched from > to <. The graph of this solution is shown below.
Multi-Step Inequalities
A popular strategy for solving equations, isolating the variable, also applies to solving
inequalities. By adding, subtracting, multiplying and/ or dividing, you can rewrite the
inequality so that the variable is on one side and everything else is on the other. As
with one step inequalities, the solutions to multi-step inequalities can be graphed on a
number line.
© The Independent Institute of Education (Pty) Ltd 2021 Page 116 of 332
IIE Module Manual MAPC5112
Example
Problem Solve for p.
4p + 5 < 29
Answer p6
To graph this inequality, you draw an open circle at the end point 6 on the number line.
The circle is open because the inequality is less than 6 and not equal to 6. The values
where p is less than 6 are found all along the number line to the left of 6. Draw a blue
line with an arrow on the number line pointing in that direction.
To check the solution, substitute the end point 6 into the original inequality written as
an equation, which is called the related equation, to see if you get a true statement.
Then check another solution, such as 0, to see if the inequality is correct.
Example
Problem Check that p < 6 is the solution to the
inequality 4p + 5 < 29.
© The Independent Institute of Education (Pty) Ltd 2021 Page 117 of 332
IIE Module Manual MAPC5112
3 x − 7 41 Begin to isolate
+ 7 + 7 the variable by
adding 7 to both
3x 48 sides of the
3 3 inequality.
x 16 Divide both
sides of the
inequality by 3 to
express the
variable with a
coefficient of 1.
3 x − 7 41
Then, try
Is 3(20) − 7 41?
another value
60 − 7 41 to check the
53 41 Yes! inequality. Let’s
use x = 20.
Answer x 16
When solving multi-step equations, pay attention to situations in which you multiply or
divide by a negative number. In these cases, you must reverse the inequality sign.
Example
Problem Solve for p.
−6p + 14 < −58
−6 p + 14 − 58 Begin to isolate
− 14 − 14 the variable by
subtracting 14
−6 p −72 from both sides
−6 −6 of the
p 12 inequality.
Divide both
sides of the
inequality by −6
to express the
variable with a
coefficient of 1.
© The Independent Institute of Education (Pty) Ltd 2021 Page 118 of 332
IIE Module Manual MAPC5112
Dividing by a
negative
number results
in reversing the
inequality sign.
Answer p 12
The graph of the inequality p > 12 has an open circle at 12 with an arrow stretching to
the right.
© The Independent Institute of Education (Pty) Ltd 2021 Page 119 of 332
IIE Module Manual MAPC5112
Example (Advanced)
Problem Solve for x.
1 1 9
(x + 3) + −
3 2 2
1 1 1 9 1 To isolate the
( x + 3) + − − − 1
3 2 2 2 2 variable, subtract
2
1 10
( x + 3) − from both sides of
3 2 the inequality.
1
( x + 3 ) −5
3
1
3 • ( x + 3 ) 3 • ( −5)
3
x + 3 −15 Then multiply by 3
so that the
x + 3 − 3 −15 − 3 coefficient in front of
x −18 the parentheses is 1.
Then subtract 3 from
both sides.
Check 1 1 9 Check the solution.
( −18 + 3 ) + = − First, check the
3 2 2
end point -18 in the
1 1 9
( −15 ) + = − related equation.
3 2 2
1 9
−5 + = −
2 2
10 1 9
− + =−
2 2 2
9 9
− =−
2 2
1 1 9 Now check any
(0 + 3) + − value for x that is
3 2 2
within the region
1 1 9
(3) + − x −18 . We will
3 2 2 use x = 0 .
1 9
1+ −
2 2
2 1 9
+ −
2 2 2
3 9
− The statement is
2 2
true.
Answer x −18
© The Independent Institute of Education (Pty) Ltd 2021 Page 120 of 332
IIE Module Manual MAPC5112
As with equations, the distributive property can be applied to simplify expressions that
are part of an inequality. Once the parentheses have been cleared, solving the
inequality will be straightforward.
Example
Problem Solve for x.
2(3x – 5) ≤ 4x + 6
2x 16
Add 10 to both
2 2 sides to isolate
x8 the variable.
Is 2(3 0 − 5) 4 0 + 6 ?
2( −5) 6
− 10 6 Yes!
Then, choose
another solution
and evaluate the
inequality for that
value to make
sure it is a true
statement.
Try 0.
Answer x 8
© The Independent Institute of Education (Pty) Ltd 2021 Page 121 of 332
IIE Module Manual MAPC5112
Example
Problem Solve for a.
2a − 4
<2
6
2(5) − 4
Is 2?
6
10 − 4
2 Then, choose another
6 solution and evaluate
6
2 the inequality for that
6 value to make sure it
1 2 Yes! is a true statement.
Try 5.
Answer a8
© The Independent Institute of Education (Pty) Ltd 2021 Page 122 of 332
IIE Module Manual MAPC5112
Example (Advanced)
Problem Solve for d.
3 1
(2d − 5) 4 7 − d
5 5
( 2d − 5 ) 4 7 − d
3 1 This inequality
contains two
5 5
parentheses.
3 3 1 Use the
( 2d ) + ( −5 ) 4 ( 7 ) + 4 − d
5 5 5 Distributive
6d −15 −4d Property to
+ 28 +
5 5 5 expand both
6d 4d sides of the
− 3 28 − inequality.
5 5
© The Independent Institute of Education (Pty) Ltd 2021 Page 123 of 332
IIE Module Manual MAPC5112
It results in a
true
statement.
( 2 • 0 − 5 ) 4 7 − • 0
3 1 Now try any
value for d
5 5
that is within
3
(0 − 5) 4 (7 − 0) the region
5 31
3 d . We
( −5 ) 4 ( 7 ) 2
5 will try
−15 d = 0.
28
5
−3 28
This is also
a true
statement.
Answer 31
d
2
© The Independent Institute of Education (Pty) Ltd 2021 Page 124 of 332
IIE Module Manual MAPC5112
Inequalities can have a range of answers. The solutions are often graphed on a number
line in order to visualise all of the solutions. Multi-step inequalities are solved using the
same processes that work for solving equations with one exception. When you multiply
or divide both sides of an inequality by a negative number, you must reverse the
inequality symbol. The inequality symbols stay the same whenever you add or subtract
either positive or negative numbers to both sides of the inequality.
For example, −4 and 4 both have an absolute value of 4 because they are each 4 units
from 0 on a number line—though they are located in opposite directions from 0 on the
number line.
When solving absolute value equations and inequalities, you must consider both the
behaviour of absolute value and the properties of equality and inequality.
Because both positive and negative values have a positive absolute value, solving
absolute value equations means finding the solution for both the positive and the
negative values.
This equation is read “the absolute value of x is equal to five.” The solution is the
value(s) that are five units away from 0 on a number line.
You might think of 5 right away; that is one solution to the equation. Notice that −5 is
also a solution because −5 is 5 units away from 0 in the opposite direction. So, the
solution to this equation x = 5 is x = −5 or x = 5.
© The Independent Institute of Education (Pty) Ltd 2021 Page 125 of 332
IIE Module Manual MAPC5112
x + 5 = 15 or x + 5 = −15
−5 −5 −5 − 5
x = 10 or x = −20
You can check these two solutions in the absolute value equation to see if x = 10 and
x = −20 are correct.
x + 5 = 15 x + 5 = 15
10 + 5 = 15 −20 + 5 = 15
15 = 15 −15 = 15
15 = 15 15 = 15
x = a or x = −a
Example
Problem Solve for p.
|2p – 4| = 26
2 p − 4 = 26 or 2 p − 4 = − 26 Write the two equations that
will give an absolute value
of 26.
© The Independent Institute of Education (Pty) Ltd 2021 Page 126 of 332
IIE Module Manual MAPC5112
Sometimes, you must isolate an absolute value before solving the equation. An
example is shown below.
Example
Problem Solve for w.
3|4w – 1| – 5 = 10
Solve for y.
© The Independent Institute of Education (Pty) Ltd 2021 Page 127 of 332
IIE Module Manual MAPC5112
3y − 5 = −1
Before removing the absolute value sign and making two equations, think about what
this equation means. It reads “the absolute value of the quantity 3y minus 5 is equal to
−1.” Remember that an absolute value is the distance from 0 on a number line, so it
must be a positive number. Since it’s impossible to have an absolute value equal to
−1, this equation has no solution. There are no values for y that will make this a true
statement. There is no additional work needed to know this equation has no solutions.
Let’s apply what you know about solving equations that contain absolute values and
what you know about inequalities to solve inequalities that contain absolute values.
Let’s start with a simple inequality.
x 4
This inequality is read, “the absolute value of x is less than or equal to 4.” If you are
asked to solve for x, you want to find out what values of x are 4 units or less away from
0 on a number line. You could start by thinking about the number line and what values
of x would satisfy this equation.
4 and −4 are both four units away from 0, so they are solutions. 3 and −3 are also
solutions because each of these values is less than 4 units away from 0. So are 1 and
−1, 0.5 and −0.5, and so on—there are an infinite number of values for x that will satisfy
this inequality.
The graph of this inequality will have two closed circles, at 4 and −4. The distance
between these two values on the number line is coloured in blue because all of these
values satisfy the equation.
The situation is a little different when the inequality sign is “greater than” or “greater
than or equal to.” Consider the simple inequality x 3. Again, you could think of the
number line and what values of x are greater than 3 units away from zero. This time, 3
and −3 are not included in the solution, so there are open circles on both values. 2 and
−2 would not be solutions because they are not more than 3 units away from 0. But 5
and −5 would work and so would all of the values extending to the left of −3 and to the
right of 3. The graph would look like the one below.
© The Independent Institute of Education (Pty) Ltd 2021 Page 128 of 332
IIE Module Manual MAPC5112
The solution to this inequality can be written this way: x < −3 or x > 3.
Example
Problem Solve for x.
x +3 > 4
x −7 or x 1
© The Independent Institute of Education (Pty) Ltd 2021 Page 129 of 332
IIE Module Manual MAPC5112
Example
Problem Solve for y.
3 2y + 6 − 9 < 27
© The Independent Institute of Education (Pty) Ltd 2021 Page 130 of 332
IIE Module Manual MAPC5112
Example
Problem Solve for x.
|2x + 3| + 9 ≤ 7
To solve an equation containing an absolute value, you want to isolate the absolute
value expression. Once that is done, you can rewrite the absolute value equation as
two equations, where one of the statements equates the value within the absolute
value to the positive quantity on the other side of the equation and one that equates
the value with the absolute value to the negative (or opposite) value.
Inequalities can also contain absolute values. Absolute inequalities also can be solved
by rewriting them using compound inequalities.
The first step in simplifying a rational expression is to determine the domain, the set of
all possible values of the variables. The denominator in a fraction cannot be zero
6
because division by zero is undefined. The reason = 2 is that when you multiply
3
the answer 2, times the divisor 3, you get back 6. To be able to divide any number c
c
by zero = ? you would have to find a number that when you multiply it by 0 you
0
would get back c (? × 0 = 𝑐 ). There are no numbers that can do this, so we say
“division by zero is undefined”. In simplifying rational expressions, you need to pay
attention to what values of the variable(s) in the expression would make the
denominator equal zero. These values cannot be included in the domain, so they're
called excluded values. Discard them right at the start, before you go any further.
© The Independent Institute of Education (Pty) Ltd 2021 Page 131 of 332
IIE Module Manual MAPC5112
(Note that although the denominator cannot be equivalent to 0, the numerator can—
this is why you only look for excluded values in the denominator of a rational
expression.)
For rational expressions, the domain will exclude values for which the value of the
denominator is 0. Two examples to illustrate finding the domain of an expression are
shown below.
Example
Problem Identify the domain of the expression.
3x + 2
x−4
Find any values for x that
x–4=0 would make the
denominator equal 0.
x = 4 When x = 4, the
denominator is equal to 0.
You found that x cannot be 4. (Sometimes you may see this idea presented as “x ≠ 4.”)
What happens if you do substitute that value into the expression?
3x + 2
x−4
3(4) + 2
(4) − 4
12 + 2
0
14
0
You find that when x = 4, the numerator evaluates to 14, but the denominator evaluates
to 0. And since division by 0 is undefined, this must be an excluded value.
Example
Problem Identify the domain of the expression.
x +7
x 2 + 8x − 9
Find any values for x
x + 8x − 9 = 0
2 that would make the
denominator equal to
0 by setting the
© The Independent Institute of Education (Pty) Ltd 2021 Page 132 of 332
IIE Module Manual MAPC5112
denominator equal to
0 and solving the
equation.
( x + 9)( x − 1) = 0
Solve the equation by
factoring. The
x = −9 or x = 1 solutions are the
values that are
excluded from the
domain.
Once you've figured out the excluded values, the next step is to simplify the rational
expression. To simplify a rational expression, follow the same approach you use to
simplify numeric fractions: find common factors in the numerator and denominator.
Let’s start by simplifying a numeric fraction.
Example
Problem 15
Simplify.
27
15 3•5 Factor the numerator
=
27 3 • 3 • 3 and denominator.
Identify fractions that
3•5 equal 1, and then pull
3•3•3 them out of the fraction.
In this fraction, the
factor 3 is in both the
5 3
• numerator and
3•3 3 denominator. Recall that
3
is another name for
5 3
•1
3•3 1.
5 5
=
3•3 9 Simplify.
Answer 15 5
=
27 9
Now, you could have done that problem in your head—but it was worth writing it all
down, because that's exactly how you simplify a rational expression.
© The Independent Institute of Education (Pty) Ltd 2021 Page 133 of 332
IIE Module Manual MAPC5112
So let's simplify a rational expression, using the same technique you applied to the
15
fraction . Only this time, the numerator and denominator are both monomials with
27
variables.
Example
Problem 5x 2
Simplify.
25 x
See—the same steps worked again. Factor the numerator, factor the denominator,
identify factors that are common to the numerator and denominator, and write as a
factor of 1, and simplify.
When simplifying rational expressions, it is a good habit to always consider the domain,
and to find the values of the variable (or variables) that make the expression undefined.
(This will come in handy when you begin solving for variables a bit later on.)
Example
Problem Identify the domain of the
expression.
5x 2
25 x
© The Independent Institute of Education (Pty) Ltd 2021 Page 134 of 332
IIE Module Manual MAPC5112
25 x 0
= The values for x that make the
25 25
denominator equal 0 are
excluded from the domain.
x=0
Answer The domain is all real numbers except 0.
Notice that you started with the original expression, and identified values of x that would
5x 2
make 25x equal to 0. Why does this matter? Look at when it is simplified…it is
25 x
x
the fraction . Since 5 is the denominator, it seems that no values need to be
5
excluded from the domain. When finding the domain of an expression, you always start
with the original expression because variable terms may be factored out as part of the
simplification process.
In the examples that follow, the numerator and the denominator are polynomials with
more than one term, but the same principles of simplifying will once again apply. Factor
the numerator and denominator to simplify the rational expression.
Example
Problem Simplify and state the domain for the
expression.
x +3
x + 12x + 27
2
x = −3 or x = −9
domain is all real
numbers except −3 and
−9
© The Independent Institute of Education (Pty) Ltd 2021 Page 135 of 332
IIE Module Manual MAPC5112
Simplify.
x +3 1
Answer =
x 2 + 12x + 27 x + 9
Example
Problem Simplify and state the domain for the
expression.
x 2 + 10 x + 24
x 3 − x 2 − 20 x
© The Independent Institute of Education (Pty) Ltd 2021 Page 136 of 332
IIE Module Manual MAPC5112
Equations that contain rational expressions are called rational equations. For example,
2x + 1 x
= is a rational equation.
4 3
You can solve these equations using the techniques for performing operations with
rational expressions and the procedures for solving algebraic equations. Rational
equations can be useful for representing real-life situations and for finding answers to
real problems. In particular, they are quite good for describing distance-speed-time
relationships and for modelling work problems that involve more than one person.
One method for solving rational equations is to rewrite the rational expressions in terms
of a common denominator. Then, since you know the numerators are equal, you can
solve for the variable. To illustrate this, let’s look at a very simple equation.
© The Independent Institute of Education (Pty) Ltd 2021 Page 137 of 332
IIE Module Manual MAPC5112
2 x
=
5 5
Since the denominator of each expression is the same, the numerators must be
equivalent. This means that x = 2.
Since the denominators of each rational expression are the same, x + 4, the
numerators must be equivalent for the equation to be true. So, x – 5 = 11 and x = 16.
Just as with other algebraic equations, you can check your solution in the original
rational equation by substituting the value for the variable back into the equation and
simplifying.
16 − 5 11
=
16 + 4 16 + 4
11 11
=
20 20
When the terms in a rational equation have unlike denominators, solving the equation
will involve some extra steps. One way of solving rational equations with unlike
denominators is to multiply both sides of the equation by the least common multiple of
the denominators of all the fractions contained in the equation. This eliminates the
denominators and turns the rational equation into a polynomial equation. Here’s an
example.
Example
Problem x+5 7
Solve the equation = .
8 4
© The Independent Institute of Education (Pty) Ltd 2021 Page 138 of 332
IIE Module Manual MAPC5112
8 4
• ( x + 5) = 7 • 2 •
8 4
1• ( x + 5) = 14 • 1
14 7
=
8 4
7 7
=
4 4
Answer x =9
Another way to solve a rational equation with unlike denominators is to rewrite each
term with a common denominator and then just create an equation from the
numerators. This works because if the denominators are the same, the numerators
must be equal. The next example shows this approach with the same equation you
just solved:
Example
Problem x+5 7
Solve the equation = .
8 4
© The Independent Institute of Education (Pty) Ltd 2021 Page 139 of 332
IIE Module Manual MAPC5112
In some instances, you’ll need to take some additional steps in finding a common
denominator. Consider the example below, which illustrates using what you know
about denominators to rewrite one of the expressions in the equation.
Example
Problem x 4
Solve the equation +1= .
3 3
x 3 4
+ =
3 3 3
x +3 4
=
3 3
1 3 4
+ =
3 3 3
4 4
=
3 3
Answer x =1
You could also solve this problem by multiplying each term in the equation by 3 to
eliminate the fractions altogether. Here is how it would look.
Example
Problem x 4
Solve the equation +1= .
3 3
© The Independent Institute of Education (Pty) Ltd 2021 Page 140 of 332
IIE Module Manual MAPC5112
3 3
• x +3 = 4•
3 3
1• x + 3 = 4•1
x +3 = 4
Answer x =1
A “work problem” is an example of a real-life situation that can be modelled and solved
using a rational equation. Work problems often ask you to calculate how long it will
take different people working at different speeds to finish a task. The algebraic models
of such situations often involve rational equations derived from the work formula, W =
rt. (Notice that the work formula is very similar to the relationship between distance,
rate, and time, or d = rt.) The amount of work done (W) is the product of the rate of
work (r) and the time spent working (t). The work formula has 3 versions.
W = rt
W
t=
r
W
r =
t
© The Independent Institute of Education (Pty) Ltd 2021 Page 141 of 332
IIE Module Manual MAPC5112
Example
Problem Myra takes two hours to plant 50 flower bulbs. Francis takes three
hours to plant 45 flower bulbs. Working together, how long should it
take them to plant 150 bulbs?
45 bulbs 15 bulbs
Francis: , or
3 hours 1 hour
150 15
t= =
40 4
3
t= 3 hours
4
Answer It should take 3 hours 45 minutes for Myra and Francis to plant 150
bulbs together.
© The Independent Institute of Education (Pty) Ltd 2021 Page 142 of 332
IIE Module Manual MAPC5112
Other work problems go the other way. You can calculate how long it will take one
person to do a job alone when you know how long it takes people working together to
complete the job.
Example
© The Independent Institute of Education (Pty) Ltd 2021 Page 143 of 332
IIE Module Manual MAPC5112
72 24
1= +
3x 3x
72 + 24
1=
3x
96
1=
3x
3x = 96
x = 32
1 1
1= + 24
32 3(32)
24 24
1= +
32 3(32)
24 24
1= +
32 96
3 24 24
1= • +
3 32 96
72 24
1= +
96 96
© The Independent Institute of Education (Pty) Ltd 2021 Page 144 of 332
IIE Module Manual MAPC5112
96
1=
96
t t
As shown above, many work problems can be represented by the equation + =1
a b
, where t is the time to do the job together, a is the time it takes person A to do the job,
and b is the time it takes person B to do the job. The 1 refers to the total work done—
in this case, the work was to paint 1 house.
The key idea here is to figure out each worker’s individual rate of work. Then, once
those rates are identified, add them together, multiply by the time t, set it equal to the
amount of work done, and solve the rational equation.
You can solve rational equations by finding a common denominator. By rewriting the
equation so that all terms have the common denominator, you can solve for the
variable using just the numerators. Or, you can multiply both sides of the equation by
the least common multiple of the denominators so that all terms become polynomials
instead of rational expressions. Rational equations can be used to solve a variety of
problems that involve rates, times and work. Using rational expressions and equations
can help you answer questions about how to combine workers or machines to
complete a job on schedule.
© The Independent Institute of Education (Pty) Ltd 2021 Page 145 of 332
IIE Module Manual MAPC5112
4 Factoring
Factors are the building blocks of multiplication. They are the numbers that you can
multiply together to produce another number: 2 and 10 are factors of 20, as are 4 and
5 and 1 and 20. To factor a number is to rewrite it as a product. 20 = 4 • 5.
Likewise, to factor a polynomial, you rewrite it as a product. Just as any integer can be
written as the product of factors, so too can any monomial or polynomial be expressed
as a product of factors. Factoring is very helpful in simplifying and solving equations
using polynomials.
A prime factor is similar to a prime number—it has only itself and 1 as factors. The
process of breaking a number down into its prime factors is called prime factorization.
Let’s first find the greatest common factor (GCF) of two whole numbers. The GCF of
two numbers is the greatest number that is a factor of both of the numbers. Take the
numbers 50 and 30.
50 = 10 • 5
30 = 10 • 3
Their greatest common factor is 10, since 10 is the greatest factor that both numbers
have in common.
To find the GCF of greater numbers, you can factor each number to find their prime
factors, identify the prime factors they have in common, and then multiply those
together.
Example
Problem Find the greatest common
factor of 210 and 168.
210 = 2 • 3 • 5 • 7
168 = 2 • 2 • 2 • 3 • 7
GCF = 2 • 3 • 7
Answer GCF = 42
© The Independent Institute of Education (Pty) Ltd 2021 Page 146 of 332
IIE Module Manual MAPC5112
Because the GCF is the product of the prime factors that these numbers have in
common, you know that it is a factor of both numbers. (If you want to test this, go ahead
and divide both 210 and 168 by 42—they are both evenly divisible by this number!)
Finding the greatest common factor in a set of monomials is not very different from
finding the GCF of two whole numbers. The method remains the same: factor each
monomial independently, look for common factors, and then multiply them to get the
GCF.
Example
Problem Find the greatest common
factor of 25b3 and 10b2.
25b3 = 5 • 5 • b • b • b
10b2 = 5 • 2 • b • b
GCF = 5 • b • b
Answer GCF = 5b2
The monomials have the factors 5, b, and b in common, which means their greatest
common factor is 5 • b • b, or simply 5b2.
Example
Problem Find the greatest common factor of
81c3d and 45c2d2.
81c3d = 3 • 3 • 3 • 3 • c • c • c • d
45c2d2 = 3 • 3 • 5 • c • c • d • d
GCF = 3 • 3 • c • c • d
Answer GCF = 9c2d
Factoring by Grouping
The distributive property allows you to factor out common factors. However, what do
you do if the terms within the polynomial do not share any common factors?
If there is no common factor for all of the terms in the polynomial, another technique
needs to be used to see if the polynomial can be factored. It involves organising the
polynomial in groups.
© The Independent Institute of Education (Pty) Ltd 2021 Page 147 of 332
IIE Module Manual MAPC5112
Example
Problem
Factor 4ab + 12a + 3b + 9
GCF = 4a
(4a • b + 4a • 3) + (3b + 9)
4a(b + 3) + (3b + 9) Factor the GCF, 4a, out of the first
group.
3b = 3 • b Find the GCF of the second pair of
9 = 3 • 3 terms.
GCF =3
4a(b + 3) +(3 • b + 3 • 3)
4a(b + 3) + 3(b + 3) Factor 3 out of the second group.
4a(b + 3) + 3(b + 3) Notice that the two terms have a
common factor (b + 3).
Answer (b + 3)(4a + 3)
Notice that when you factor two terms, the result is a monomial times a polynomial.
But the factored form of a four-term polynomial is the product of two binomials.
This process is called the grouping technique. Broken down into individual steps,
here's how to do it (you can also follow this process in the example below):
Let’s try factoring a few more four-term polynomials. Notice that in the example below,
the first term is x2, and x is the only variable present.
© The Independent Institute of Education (Pty) Ltd 2021 Page 148 of 332
IIE Module Manual MAPC5112
Example
Problem
Factor x2 + 2x + 5x + 10
This method of factoring only works in some cases. Notice that both factors here
contain the term x.
Example
Problem
Factor 2x2 – 3x + 8x –
12.
© The Independent Institute of Education (Pty) Ltd 2021 Page 149 of 332
IIE Module Manual MAPC5112
Example
Problem
Factor 3x2 + 3x – 2x – 2.
Sometimes, you will encounter polynomials that, despite your best efforts, cannot be
factored into the product of two binomials.
Example
Problem
Factor 7x2 – 21x + 5x – 5.
In the example above, each pair can be factored, but then there is no common factor
between the pairs!
© The Independent Institute of Education (Pty) Ltd 2021 Page 150 of 332
IIE Module Manual MAPC5112
When two or more monomials are combined (either added or subtracted), the resulting
expression is called a polynomial. If you can find common factors for each term of the
polynomial, then you can factor the polynomial.
As you look at the examples of simple polynomials below, try to identify factors that the
terms of the polynomial have in common.
To factor a polynomial, first identify the greatest common factor of the terms. You can
then use the distributive property to rewrite the polynomial in a factored form. Recall
that the distributive property of multiplication over addition states that a product of a
number and a sum is the same as the sum of the products.
Product of a number and a sum: a(b + c) = a • b + a • c. You can say that “a is being
distributed over b + c.”
Sum of the products: a • b + a • c = a(b + c). Here you can say that “a is being factored
out.”
Example
Problem
Factor 25b3 + 10b2.
25b3 = 5 • 5 • b • b • b Find the GCF. From a previous example,
10b2 = 5 • 2 • b • b you found the GCF of 25b3 and 10b2 to be
GCF = 5 • b • b = 5b2 5b2.
25b3 = 5b2 • 5b Rewrite each term with the GCF as one
factor.
10b = 5b • 2
2 2
© The Independent Institute of Education (Pty) Ltd 2021 Page 151 of 332
IIE Module Manual MAPC5112
The factored form of the polynomial 25b3 + 10b2 is 5b2(5b + 2). You can check this by
doing the multiplication. 5b2(5b + 2) = 25b3 + 10b2.
Note that if you do not factor the greatest common factor at first, you can continue
factoring, rather than start all over.
For example:
Notice that you arrive at the same simplified form whether you factor out the GCF
immediately or if you pull out factors individually.
Example
Problem Factor 81c3d + 45c2d2.
3
3 • 3 • 9 • c • c • c • d Factor 81c d.
3 • 3 • 5 • c • c • d • d Factor 45c2d2.
3 • 3 • c • c • d = 9c2d Find the GCF.
81c3d = 9c2d(9c) Rewrite each term as the
product of the GCF and
45c2d2 = 9c2d(5d) the remaining terms.
Factoring Trinomials
A polynomial with three terms is called a trinomial. Trinomials often (but not always!)
have the form x2 + bx + c. At first glance, it may seem difficult to factor trinomials, but
you can take advantage of some interesting mathematical patterns to factor even the
most difficult-looking trinomials.
So, how do you get from 6x2 + 2x – 20 to (2x + 4)(3x −5)? Let’s take a look.
© The Independent Institute of Education (Pty) Ltd 2021 Page 152 of 332
IIE Module Manual MAPC5112
Factoring Trinomials: x2 + bx + c
Trinomials in the form x2 + bx + c can often be factored as the product of two binomials.
Remember that a binomial is simply a two-term polynomial. Let’s start by reviewing
what happens when two binomials, such as (x + 2) and (x + 5), are multiplied.
Example
Problem
Multiply (x + 2)(x + 5).
Use the FOIL method to
(x + 2)(x + 5)
multiply binomials.
Then combine like terms 2x
x2 + 5x + 2x +10
and 5x.
Answer x2 + 7x +10
Factoring is the reverse of multiplying. So let’s go in reverse and factor the trinomial x2
+ 7x + 10. The individual terms x2, 7x, and 10 share no common factors. So look at
rewriting x2 + 7x + 10 as x2 + 5x + 2x + 10.
And, you can group pairs of factors: (x2 + 5x) + (2x + 10)
Factor each pair: x(x + 5) + 2(x + 5)
Then factor out the common factor x + 5: (x + 5)(x + 2)
Example
Problem
Factor x2 + 7x +10.
Rewrite the middle term 7x as
x2 + 5x + 2x +10
5x + 2x.
Group the pairs and factor out
the common factor x from the
x(x + 5) + 2(x + 5)
first pair and 2 from the
second pair.
Factor out the common factor
(x + 5)(x + 2)
(x + 5).
Answer (x + 5)(x + 2)
© The Independent Institute of Education (Pty) Ltd 2021 Page 153 of 332
IIE Module Manual MAPC5112
How do you know how to rewrite the middle term? Unfortunately, you can’t rewrite it
just any way. If you rewrite 7x as 6x + x, this method won’t work. Fortunately, there's a
rule for that.
Rewrite the trinomial as x2 + rx + sx + c and then use grouping and the distributive
property to factor the polynomial. The resulting factors will be (x + r) and (x + s).
For example, to factor x2 + 7x +10, you are looking for two numbers whose sum is 7
(the coefficient of the middle term) and whose product is 10 (the last term).
Look at factor pairs of 10: 1 and 10, 2 and 5. Do either of these pairs have a sum of 7?
Yes, 2 and 5. So you can rewrite 7x as 2x + 5x, and continue factoring as in the
example above. Note that you can also rewrite 7x as 5x + 2x. Both will work.
Let’s factor the trinomial x2 + 5x + 6. In this polynomial, the b part of the middle term is
5 and the c term is 6. A chart will help us organise possibilities. On the left, list all
possible factors of the c term, 6; on the right you'll find the sums.
Factors whose
Sum of the factors
product is 6
1•6=6 1+6=7
2•3=6 2+3=5
There are only two possible factor combinations, 1 and 6, and 2 and 3. You can see
that 2 + 3 = 5. So 2x + 3x = 5x, giving us the correct middle term.
© The Independent Institute of Education (Pty) Ltd 2021 Page 154 of 332
IIE Module Manual MAPC5112
Example
Problem
Factor x2 + 5x +
6.
Finally, let’s take a look at the trinomial x2 + x – 12. In this trinomial, the c term is −12.
So look at all of the combinations of factors whose product is −12. Then see which of
these combinations will give you the correct middle term, where b is 1.
Factors whose
Sum of the factors
product is −12
2 • −6 = −12 2 + −6 = −4
3 • −4 = −12 3 + −4 = −1
4 • −3 = −12 4 + −3 = 1
6 • −2 = −12 6 + −2 = 4
12 • −1 = −12 12 + −1 = 11
© The Independent Institute of Education (Pty) Ltd 2021 Page 155 of 332
IIE Module Manual MAPC5112
There is only one combination where the product is −12 and the sum is 1, and that is
when r = 4, and s = −3. Let’s use these to factor our original trinomial.
Example
Problem
Factor x2 + x – 12
While there is no fool proof way to find the right combination on the first guess, there
are some tips that can ease the way.
© The Independent Institute of Education (Pty) Ltd 2021 Page 156 of 332
IIE Module Manual MAPC5112
After you have factored a number of trinomials in the form x2 + bx + c, you may notice
that the numbers you identify for r and s end up being included in the factored form of
the trinomial. Have a look at the following chart, which reviews the three problems you
have seen so far.
Trinomial x2 + 7x + 10 x2 + 5x + 6 x2 + x - 12
r and s values r = + 5, s = + 2 r = + 2, s = + 3 r = + 4, s = –3
Factored form (x + 5)(x + 2) (x + 2)(x + 3) (x + 4)(x – 3)
Notice that in each of these examples, the r and s values are repeated in the factored
form of the trinomial.
So, what does this mean? It means that in trinomials of the form x2 + bx + c (where
the coefficient in front of x2 is 1), if you can identify the correct r and s values, you can
effectively skip the grouping steps and go right to the factored form. You may want to
stick with the grouping method until you are comfortable factoring, but this is a neat
shortcut to know about!
© The Independent Institute of Education (Pty) Ltd 2021 Page 157 of 332
IIE Module Manual MAPC5112
Not all trinomials look like x2 + 5x + 6, where the coefficient in front of the x2 term is 1.
In these cases, your first step should be to look for common factors for the three terms.
Factor out
Trinomial Factored
Common Factor
Notice that once you have identified and pulled out the common factor, you can factor
the remaining trinomial as usual. This process is shown below.
Example
Problem
Factor 3x3 – 3x2 – 90x.
© The Independent Institute of Education (Pty) Ltd 2021 Page 158 of 332
IIE Module Manual MAPC5112
Negative Terms
Example
Problem
Factor −4h2 + 11h + 3
r • s = −12 r + s = −11
−1(4h2 – 12h + 1h – 3)
−12 • 1 = −12 + 1 =
−12 −11
−6 • 2 = −12 −6 + 2 = −4
−4 • 3 = −12 −4 + 3 = −1
© The Independent Institute of Education (Pty) Ltd 2021 Page 159 of 332
IIE Module Manual MAPC5112
Note that the answer above can also be written as (−h + 3)(4h + 1) or (h – 3)( −4h – 1)
if you multiply −1 times one of the other factors.
One of the keys to factoring is finding patterns between the trinomial and the factors of
the trinomial. Learning to recognise a few common polynomial types will lessen the
amount of time it takes to factor them. Knowing the characteristic patterns of special
products—trinomials that come from squaring binomials, for example—provides a
shortcut to finding their factors.
Perfect Squares
Perfect squares are numbers that are the result of a whole number multiplied by itself
or squared. For example 1, 4, 9, 16, 25, 36, 49, 64, 81, and 100 are all perfect
squares—they come from squaring each of the numbers from 1 to 10. Notice that these
perfect squares can also come from squaring the negative numbers from −1 to −10,
as (−1)( −1) = 1, (−2)( −2) = 4, (−3)( −3) = 9, and so on.
Example
Problem
Factor x2 + 6x + 9.
Notice that in the trinomial x2 + 6x + 9, the a and c terms are each a perfect square, as
x2 = x • x, and 9 = 3 • 3. Also the middle term is twice the product of the x and 3 terms,
2(3)x = 6x.
© The Independent Institute of Education (Pty) Ltd 2021 Page 160 of 332
IIE Module Manual MAPC5112
Let’s look at a slightly different example next. The above example shows how (x + 3)2
= x2 + 6x + 9. What do you suppose (x – 3)2 equals? Using what you know about
multiplying binomials, you see the following.
(x – 3)2
(x – 3)(x – 3)
x2 – 3x – 3x + 9
x2 – 6x + 9
Let’s try one more example: 9x2 – 24x + 16. Notice that 9x2 is a perfect square, as (3x)2
= 9x2 and that 16 is a perfect square, as 42 = 16. However, the middle term, –24x is
negative, so try 16 = (−4)2. In this case, the middle term is 2(3x)( −4) = −24x. So the
trinomial 9x2 – 24x + 16 is a perfect square and factors as (3x – 4)2.
Example
Problem
Factor 9x2 – 24x + 16.
Notice that if you had factored out 4 rather than −4, the 3x – 4 factor would have been
−3x + 4, which is the opposite of 3x – 4. By factoring out the −4, the factors from the
grouping come out the same, both as 3x – 4. We need that to happen if we are going
to pull a common grouping factor out for our next step.
© The Independent Institute of Education (Pty) Ltd 2021 Page 161 of 332
IIE Module Manual MAPC5112
The pattern for factoring perfect square trinomials lead to this general rule.
Examples:
The factored form of 4x2 + 20x + 25 is (2x + 5)2.
The factored form of x2 – 10x + 25 is (x – 5)2.
Let’s factor a trinomial using the rule above. Once you have determined that the
trinomial is indeed a perfect square, the rest is easy. Notice that the c term is always
positive in a perfect trinomial square.
Example
Problem Factor x2 – 14x + 49.
Answer (x – 7)2
You can, and should, always multiply to check the answer. (x – 7)2 = (x – 7)(x – 7) = x2
– 7x – 7x + 49 = x2 – 14x + 49.
The difference of two squares, a2 – b2, is also a special product that factors into the
product of two binomials.
Let’s factor 9x2 – 4 by writing it as a trinomial, 9x2 + 0x – 4. Now you can factor this
trinomial just as you have been doing.
© The Independent Institute of Education (Pty) Ltd 2021 Page 162 of 332
IIE Module Manual MAPC5112
9x2 + 0x – 4 fits the standard form of a trinomial, ax2 + bx + c. Let’s factor this trinomial
the same way you would any other trinomial. Find the factors of ac (9 • −4 = −36)
whose sum is b, in this case, 0.
4 • −9 = −36 4 + (−9) = −5
6 • −6 = −36 6 + (−6) = 0
9 • −4 = −36 9 + (−4) = 5
… …
There are more factors, but you have found the pair that has a sum of 0, 6 and −6. You
can use these to factor 9x2 – 4.
Example
Problem Factor 9x2 – 4.
Since multiplication is commutative, the answer can also be written as (3x + 2)(3x – 2).
You can check the answer by multiplying (3x – 2)(3x + 2) = 9x2 + 6x – 6x – 4 = 9x2 –
4.
Examples
The factored form of x2 – 100 is (x + 10)(x – 10).
The factored form of 49y2 – 25 is (7y + 5)(7y – 5).
© The Independent Institute of Education (Pty) Ltd 2021 Page 163 of 332
IIE Module Manual MAPC5112
Let’s factor the difference of two squares using the above rule. Once you have
determined that you have the difference of two squares, you just follow the pattern.
Example
Problem Factor 4x2 – 36.
Check the answer by multiplying: (2x + 6)(2x – 6) = 4x2 – 12x + 12x – 36 = 4x2 – 36.
Learning to identify certain patterns in polynomials helps you factor some “special
cases” of polynomials quickly. The special cases are:
• Trinomials that are perfect squares, a2 + 2ab + b2 and a2 – 2ab + b2, which
factor as (a+ b)2 and (a – b)2, respectively;
• Binomials that are the difference of two squares, a2 – b2, which factors as (a +
b)(a – b).
For some polynomials, you may need to combine techniques (looking for common
factors, grouping, and using special products) to factor the polynomial completely.
Sum of Cubes
In many ways, factoring is about patterns—if you recognise the patterns that numbers
make when they are multiplied together, you can use those patterns to separate these
numbers into their individual factors.
Some interesting patterns arise when you are working with cubed quantities within
polynomials. Specifically, there are two more special cases to consider: a3 + b3 and a3
– b3.
Let’s take a look at how to factor sums and differences of cubes.
The term “cubed” is used to describe a number raised to the third power. In geometry,
a cube is a six-sided shape with equal width, length, and height; since all these
measures are equal, the volume of a cube with width x can be represented by x3.
(Notice the exponent!)
Cubed numbers get large very quickly. 13 = 1, 23 = 8, 33 = 27, 43 = 64, and 53 = 125.
Before looking at factoring a sum of two cubes, let’s look at the possible factors.
© The Independent Institute of Education (Pty) Ltd 2021 Page 164 of 332
IIE Module Manual MAPC5112
It turns out that a3 + b3 can actually be factored as (a + b)(a2 – ab + b2). Let’s check
these factors by multiplying.
Did you see that? Four of the terms cancelled out, leaving us with the (seemingly)
simple binomial a3 + b3. So, the factors are correct.
You can use this pattern to factor binomials in the form a3 + b3, otherwise known as
“the sum of cubes.”
Examples:
The factored form of x3 + 64 is (x + 4)(x2 – 4x + 16).
The factored form of 8x3 + y3 is (2x + y)(4x2 – 2xy + y2).
Example
Problem
Factor x3 + 8y3.
© The Independent Institute of Education (Pty) Ltd 2021 Page 165 of 332
IIE Module Manual MAPC5112
And that’s it. The binomial x3 + 8y3 can be factored as (x + 2y)(x2 – 2xy + 4y2)! Let’s try
another one.
You should always look for a common factor before you follow any of the patterns for
factoring.
Example
Problem
Factor 16m3 + 54n3.
Difference of Cubes
Having seen how binomials in the form a3 + b3 can be factored, it should not come as
a surprise that binomials in the form a3 – b3 can be factored in a similar way.
Examples:
The factored form of x3 – 64 is (x – 4)(x2 + 4x + 16).
The factored form of 27x3 – 8y3 is (3x – 2y)(9x2 + 6xy + 4y2).
© The Independent Institute of Education (Pty) Ltd 2021 Page 166 of 332
IIE Module Manual MAPC5112
Notice that the basic construction of the factorisation is the same as it is for the sum of
cubes; the difference is in the + and – signs. Take a moment to compare the factored
form of a3 + b3 with the factored form of a3 – b3.
This can be tricky to remember because of the different signs—the factored form of a3
+ b3 contains a negative, and the factored form of a3 – b3 contains a positive! Some
people remember the different forms like this:
Try this for yourself. If the first sign is +, as in a3 + b3, according to this strategy how do
you fill in the rest: (a b)(a2 ab b2)? Does this method help you remember the factored
form of a3 + b3 and a3 – b3?
Let’s go ahead and look at a couple of examples. Remember to factor out all common
factors first.
Example
Problem
Factor 8x3 – 1,000.
Let’s see what happens if you don’t factor out the common factor first. In this example,
it can still be factored as the difference of two cubes. However, the factored form still
has common factors, which need to be factored out.
© The Independent Institute of Education (Pty) Ltd 2021 Page 167 of 332
IIE Module Manual MAPC5112
Example
Problem
Factor 8x3 – 1,000.
As you can see, this last example still worked, but required a couple of extra steps. It
is always a good idea to factor out all common factors first. In some cases, the only
efficient way to factor the binomial is to factor out the common factors first.
Here is one more example. Note that r9 = (r3)3 and that 8s6 = (2s2)3.
Example
Problem
Factor r9 – 8s6.
© The Independent Institute of Education (Pty) Ltd 2021 Page 168 of 332
IIE Module Manual MAPC5112
You encounter some interesting patterns when factoring. Two special cases—the sum
of cubes and the difference of cubes—can help you factor some binomials that have a
degree of three (or higher, in some cases). The special cases are:
The Principle of Zero Products states that if the product of two numbers is 0, then at
least one of the factors is 0. (This is not really new.)
This property may seem fairly obvious, but it has big implications for solving quadratic
equations. If you have a factored polynomial that is equal to 0, you know that at least
one of the factors or both factors equal 0.
You can use this method to solve quadratic equations. Let’s start with one that is
already factored.
© The Independent Institute of Education (Pty) Ltd 2021 Page 169 of 332
IIE Module Manual MAPC5112
Example
Problem Solve (x + 4)(x – 3) = 0 for
x.
Applying the
(x + 4)(x – 3) = 0 Principle of Zero
Products, you know
that if the product is
0, then one or both
of the factors has to
be 0.
x+4=0 or x – 3 Set each factor
=0 equal to 0.
x+4–4=0–4 x – 3 + Solve each equation.
3=0+3
x = −4 or x
=3
Answer x = −4 OR x = 3
You can check these solutions by substituting each one at a time into the original
equation, (x + 4)(x – 3) = 0. You can also try another number to see what happens.
0=0 0=0 27 ≠ 0
The two values that we found via factoring, x = −4 and x = 3, lead to true statements:
0 = 0. So, the solutions are correct. But x = 5, the value not found by factoring, creates
an untrue statement—27 does not equal 0!
Solving Quadratics
Let’s try solving an equation that looks a bit different: 5a2 + 15a = 0.
© The Independent Institute of Education (Pty) Ltd 2021 Page 170 of 332
IIE Module Manual MAPC5112
Example
Problem Solve for a: 5a2 + 15a = 0.
To check your answers, you can substitute both values directly into the original
equation and see if you get a true sentence for each.
Checking a = 0 Checking a = −3
5(0) + 0 = 0 5(9) – 45 = 0
0+0=0 45 – 45 = 0
0=0 0=0
You can use the Principle of Zero Products to solve quadratic equations in the form
ax2 + bx + c = 0. First factor the expression, and set each factor equal to 0.
© The Independent Institute of Education (Pty) Ltd 2021 Page 171 of 332
IIE Module Manual MAPC5112
Example
Problem Solve for r: r2 – 5r + 6 = 0.
Note in the example above, if the common factor of 2 had been factored out, the
resulting factor would be (−r + 3), which is the negative of (r – 3). So factoring out −2
will result in the common factor of (r – 3). If we had gotten (−r + 3) as a factor, then
when setting that factor equal to zero and solving for r we would have gotten:
There are many applications for quadratic equations. When you use the Principle of
Zero Products to solve a quadratic equation, you need to make sure that the equation
is equal to zero. For example, 12x2 + 11x + 2 = 7 must first be changed to 12x2 + 11x
+ −5 = 0 by subtracting 7 from both sides.
© The Independent Institute of Education (Pty) Ltd 2021 Page 172 of 332
IIE Module Manual MAPC5112
Example
Problem The area of a rectangular garden is 30 square feet. If the length
is 7 feet longer than the width, find the dimensions.
width = w
30 = (w + 7)(w) length = w + 7
area = 30
30 = w2 + 7w Multiply.
The example below shows another quadratic equation where neither side is originally
equal to zero. (Note that the factoring sequence has been shortened.)
© The Independent Institute of Education (Pty) Ltd 2021 Page 173 of 332
IIE Module Manual MAPC5112
Example
Problem Solve 5b2 + 4 = −12b for b.
Answer 2
b=− OR b= = −2
5
If you factor out a constant, the constant will never equal 0. So, it can essentially be
ignored when solving. See the following example.
Example
Problem A small toy rocket is launched from a 4-foot pedestal. The height
(h, in feet) of the rocket t seconds after taking off is given by the
formula h = −2t2 + 7t + 4. How long will it take the rocket to hit
the ground?
0 = −2t2 + 7t + 4
0 = −2t2 + 8t – t + 4 Factor the trinomial by
grouping.
© The Independent Institute of Education (Pty) Ltd 2021 Page 174 of 332
IIE Module Manual MAPC5112
You can find the solutions, or roots, of quadratic equations by setting one side equal
to zero, factoring the polynomial, and then applying the Zero Product Property. The
Principle of Zero Products states that if ab = 0, then either a = 0 or b = 0, or both a and
b are 0. Once the polynomial is factored, set each factor equal to zero and solve them
separately. The answers will be the set of solutions for the original equation.
Not all solutions are appropriate for some applications. In many real-world situations,
negative solutions are not appropriate and must be discarded.
5 Roots
You have probably dealt with the roots of plants and trees when gardening, but did you
know that there are roots in mathematics, too?
Yes, roots do exist in math. The most common root is the square root. Let’s take a look
at what roots are, how they relate to exponents, and how you find the square root of a
number.
To help understand square roots, let’s review some facts about exponents. Look at the
table below.
© The Independent Institute of Education (Pty) Ltd 2021 Page 175 of 332
IIE Module Manual MAPC5112
Just as dividing is the inverse of multiplying, the inverse of raising a number to a power
is taking the root of a number. The most common root (and the one you will be studying
here) is called the square root. When you are trying to find the square root of a number
(say, 25), you are trying to find a number that can be multiplied by itself to create that
original number. In the case of 25, you can find that 5 • 5 = 25, so 5 must be the square
root.
The symbol for the square root is called a radical symbol and looks like this: . The
Look at 25 again. You may realize that there is another value that, when multiplied
by itself, also results in 25. That number is −5.
5 • 5 = 25
−5 • −5 = 25
By definition, the square root symbol always means to find the positive root, called the
principal root. So while 5 • 5 and −5 • −5 both equal 25, only 5 is the principal root. You
should also know that zero is special because it has only one square root: itself (since
0 • 0 = 0).
© The Independent Institute of Education (Pty) Ltd 2021 Page 176 of 332
IIE Module Manual MAPC5112
If you know the principal square root, you can also find its opposite. (Recall that any
number plus its opposite will equal 0. So, for instance, a + ( −a ) = 0 .) In the table
below, notice that while x will give the principal root, − x will give its opposite. For
example, 36 equals the principal square root, 6, and − 36 equals its opposite,
−6.
36 6•6 = 6 − 36 − 6 • 6 = −6
100 10 •10 = 10 − 100 − 10 •10 = −10
225 15 •15 = 15 − 225 − 15 •15 = −15
There you have it—putting a negative sign in front of a radical has the effect of turning
the principal root into its opposite (the negative square root of the radicand).
So now you have reviewed exponents, and you have been introduced to square roots.
How does knowing about one help you understand the other?
The square root of a number can be displayed by using the radical symbol or by raising
1
the number to the power. This is illustrated in the table below.
2
The square of 4 is 16 because 4 times 4 is equal to 16. Recall from your work with
exponents that this can also be written as 42 = 16 .
Thinking this way, you can identify that the square root of 9 is 3 because 3 • 3 = 9.
Similarly, the square root of 25 is 5 because 5 • 5 = 25, and the square root of x 2 is x
since x • x = x 2 . For example, 7 = 7 . (You will often see this type of notation—
2
where you take the square root of a squared number—when you simplify, multiply, and
divide radicals.)
© The Independent Institute of Education (Pty) Ltd 2021 Page 177 of 332
IIE Module Manual MAPC5112
Ok…square roots and exponents are connected. Keep that in mind as you begin
simplifying some square roots.
This first example, “Simplify 144 ,” can be read “Simplify the square root of 144.”
Think about a number that, when multiplied by itself, has a product of 144.
Example
Problem Simplify. 144
Example
Problem
Simplify. − 81
However, if the negative sign is under the radical as in −49 , there is no way to
simplify it using real numbers. That is because there is no number that you could
multiply by itself to get −49. Remember, a negative number multiplied by a negative
number results in a positive number: −7 • −7 = 49.
© The Independent Institute of Education (Pty) Ltd 2021 Page 178 of 332
IIE Module Manual MAPC5112
If finding the square root by trial and error is difficult, you can use what you know about
factoring to help you determine the principal root.
Example
Problem Simplify. 144
2 • 2 • 36
2 • 2 • 2 • 18
2•2•2•2•9
2•2•2•2•3•3
122 = 12 .
Answer 144 = 12
Notice something that happened in the final step of this example: the expression
2• 2• 2• 2• 3• 3 2
was rewritten as 12 •12 , and then 12 . You split the factors
into identical groupings, multiplied them, and arrived at a squared number.
Many times, though, it is easier to identify factor pairs after you have gone through the
factors (as you did when you found that 2 • 2 • 2 • 2 • 3 • 3 = 12•12 ), you might be
able to simplify radicals more quickly.
This is where it helps to think of roots as fractional exponents. Recall the Product
Raised to a Power Rule from when you studied exponents. This rule states that the
product of two or more non-zero numbers raised to a power is equal to the product of
© The Independent Institute of Education (Pty) Ltd 2021 Page 179 of 332
IIE Module Manual MAPC5112
each number raised to the same power. In math terms, it is written (ab)x = ax • bx. So,
for example, you can use the rule to rewrite ( 3x ) as 32 • x 2 = 9 • x 2 = 9 x 2 .
2
1
Now instead of using the exponent 2, let’s use the exponent . The exponent is
2
distributed in the same way.
1 1 1
(3x ) 2 =3 •x
2 2
1
And since you know that raising a number to the power is the same as taking the
2
square root of that number, you can also write it this way.
3x = 3 • x
Look at that—you can think of any number underneath a radical as the product of
separate factors, each underneath its own radical. Using this idea helps you identify
smaller squared numbers, which often lets you simplify radicals more quickly.
This rule is important because it helps you think of one radical as the product of multiple
radicals. If you can identify perfect squares within a radical, as with
(2 • 2)(2 • 2)(3 • 3) , you can rewrite the expression as the product of multiple perfect
squares: 22 • 22 • 32 . Let’s take another look at 144 using this new idea.
Example
Problem Simplify. 144
© The Independent Institute of Education (Pty) Ltd 2021 Page 180 of 332
IIE Module Manual MAPC5112
You get the same solution in both cases, but it is often easier to pull out smaller factor
pairs and then multiply them together (as shown here) than recombining all the factors
to find the full root (as shown in the first example).
So far, you have seen examples that are perfect squares. That is, each is a number
whose square root is an integer. But many radical expressions are not perfect squares.
Some of these radicals can still be simplified by finding perfect square factors. The
example below illustrates how to factor the radicand, looking for pairs of factors that
can be expressed as a power.
Example
Problem
Simplify. 63
Factor 63 into 7 and 9.
7•9
Factor 9 further into 3 and 3.
7•3•3
Rewrite 3 • 3 as 32.
7 • 32
Using the Product Raised to a
7 • 32
Power rule, separate the radical
into the product of two factors,
each under a radical.
The final answer 3 7 may look a bit odd, but it is in simplified form. You can read
this as “three radical seven” or “three times the square root of seven.”
© The Independent Institute of Education (Pty) Ltd 2021 Page 181 of 332
IIE Module Manual MAPC5112
Example
Problem
Simplify. 2,000
Another approach to handling square roots that are not perfect squares is to
approximate them by comparing the values to perfect squares. Suppose you wanted
to know the square root of 17. Let’s look at how you might approximate it.
Example
Problem Simplify. 17
© The Independent Institute of Education (Pty) Ltd 2021 Page 182 of 332
IIE Module Manual MAPC5112
This approximation is pretty close. If you kept using this trial-and-error strategy you
could continue to find the square root to the thousandths, ten-thousandths, and
hundred-thousandths places, but eventually it would become too tedious to do by
hand.
For this reason, when you need to find a more precise approximation of a square root,
you should use a calculator. Most calculators have a square root key ( ) that will
give you the square root approximation quickly. On a simple 4-function calculator, you
would likely key in the number that you want to take the square root of and then press
the square root key.
Try to find 17 using your calculator. Note that you will not be able to get an “exact”
answer because 17 is an irrational number, a number that cannot be expressed as
a fraction, and the decimal never terminates or repeats. To nine decimal positions,
17 is approximated as 4.123105626. A calculator can save a lot of time and yield a
more precise square root when you are dealing with numbers that aren’t perfect
squares.
Example
Problem
Approximate 50 and also find its value using a
calculator.
© The Independent Institute of Education (Pty) Ltd 2021 Page 183 of 332
IIE Module Manual MAPC5112
Using number
49 and 50 are close, so 50 is only
sense and trial
a little greater than 7. and error, try
squaring
7.1 • 7.1 = 50.41 incrementally
greater
Since 50.41 is greater than 50, the numbers,
estimate must be between 7 and beginning with
7.1. 7.1, to find a
good
approximation
for 50 .
Since 50 is closer to 50.41 than to Use reasoning
49, try 7.07. to get an
estimate to the
7.07 • 7.07 = 49.9849 hundredths
place.
By approximation: 50 7.07
Answer
Using a calculator:
50 7.071067812
The square root of a number is the number which, when multiplied by itself, gives the
original number. Principal square roots are always positive and the square root of 0 is
0. You can only take the square root of values that are greater than or equal to 0. The
square root of a perfect square will be an integer. Other square roots can be simplified
by identifying factors that are perfect squares and taking their square root. Square
roots can be approximated using trial and error or a calculator.
Radical expressions
Radical expressions are expressions that contain radicals. Radical expressions come
© The Independent Institute of Education (Pty) Ltd 2021 Page 184 of 332
IIE Module Manual MAPC5112
Example
Problem Simplify. 9x 6 y 4
Factor the coefficient 9
3 • 3 • x6y 4
into 3• 3 .
Factor variables into
3 • 3 • x2 • x2 • x2 • y 2 • y 2 squares.
Write 3 • 3 as 32 and
32 • x 2 • x 2 • x 2 • y 2 • y 2 separate into individual
radicals.
that x2 = x .
Rewrite the expression
3x 3 y 2 with constants in front and
using exponents for the
variables.
Answer
9x 6 y 4 = 3x 3 y
The goal is to find factors under the radical that are perfect squares so that you can
take their square root. Let’s repeat the example above and focus on finding identical
pairs of factors.
Example
Problem Simplify. 9x 6 y 4
( ) • (y )
2 2 Rewrite the pairs as perfect
32 • x 3 2
squares.
(x ) (y )
2 2 Separate into individual
32 • 3
• 2
radicals.
x2 = x .
Answer
9x 6 y 4 = 3x 3 y
Variable factors with even exponents can be written as squares. In the example above,
x 6 = x 3 • x 3 = ( x 3 ) and y 4 = y 2 • y 2 = ( y 2 ) . Let’s try to simplify another radical
2 2
expression.
© The Independent Institute of Education (Pty) Ltd 2021 Page 185 of 332
IIE Module Manual MAPC5112
Example
Problem Simplify. 49x10 y 8
72 • ( x 5 )2 • ( y 4 )2
Rewrite the pairs as
squares.
72 • ( x 5 )2 • ( y 4 )2
Separate the squared
factors into individual
radicals.
rule that x2 = x .
7x 5 y 4 Multiply.
Answer
49 x10 y 8 = 7 x 5 y 4
You find that the square root of 49x10 y 8 is 7x 5 y 4 . In order to check this calculation,
you could square 7x 5 y 4 , hoping to arrive at 49x10 y 8 . And, in fact, you would get this
expression if you evaluated ( 7x 5 y 4 ) .
2
Absolute Value
3 5 7
Take a moment to think about two radical expressions: 900 and a b c . You
would use the same techniques to simplify either one of these: find squares within the
radical, rewrite the expression as the product of separate radicals, simplify and
multiply.
There is an added issue when you are taking the root of a radical expression that
contains variables. Recall that the root of an integer, such as 900 , is defined to be
nonnegative. This means that although both 302 and (−30)2 are equal to 900, 900
is defined only as 30. This is the idea behind 30 being the principal root of 900.
But it is not as straightforward with radical expressions that contain variables. Consider
2
the expression x . This looks like it should be equal to x, right? Let’s test some
values for x and see what happens.
© The Independent Institute of Education (Pty) Ltd 2021 Page 186 of 332
IIE Module Manual MAPC5112
In the chart below, look along each row and determine whether the value of x is the
same as the value of x2 . Where are they equal? Where are they not equal?
After doing that for each row, look again and determine whether the value of x2 is
the same as the value of x .
x x2 x2 x
−5 25 5 5
−2 4 2 2
0 0 0 0
6 36 6 6
10 100 10 10
process of squaring the number loses the negative sign, since a negative times a
negative is a positive.) However, in all cases x 2 = x . You need to consider this fact
When finding the square root of an expression that contains variables raised to a
power, consider that x2 = x .
Examples: 9 x 2 = 3 x , and 16 x 2 y 2 = 4 xy
Example
Problem
Simplify. a3 b5c 2
Factor to find
a2 • a • b 4 • b • c 2
variables with even
exponents.
4 2 2
a2 • a • (b2 )2 • b • c 2 Rewrite b as (b ) .
© The Independent Institute of Education (Pty) Ltd 2021 Page 187 of 332
IIE Module Manual MAPC5112
Cube Roots
While square roots are probably the most common radical, you can also find the third
root, the fifth root, the 10th root, or really any other nth root of a number. Just as the
square root is a number that, when squared, gives the radicand, the cube root is a
number that, when cubed, gives the radicand. Cubing a number is the same as taking
it to the third power: 23 is 2 cubed, so the cube root of 23 is 2.
The cube root of a number is written with a small number 3, called the index, just
outside and above the radical symbol. It looks like 3 . This little 3 distinguishes cube
roots from square roots which are written without a small number outside and above
the radical symbol.
Be careful to distinguish between 3 x , the cube root of x, and 3 x , three times the
square root of x. They may look similar at first, but they lead you to much different
expressions!
© The Independent Institute of Education (Pty) Ltd 2021 Page 188 of 332
IIE Module Manual MAPC5112
Example
Problem Simplify.
3
8
2 • 2 • 2 Ask yourself, “What
number can I multiply
by itself, and then by
itself again, to get 8?”
Answer 3
8 =2
Another approach to simplifying a cube root is to use factoring. Let’s explore factoring
3
with the expression 125 . You can read this as “the third root of 125” or “the cube root
of 125.” To simplify this expression, look for a number that, when multiplied by itself
two times (for a total of three identical factors), equals 125. Let’s factor 125 and find
that number.
Example
Problem 3
Simplify. 125
125 ends in 5, so you know that 5 is a
3
5 • 25
factor. Expand 125 into 5 • 25.
Factor 25 into 5 and 5.
3
5•5•5
3 The factors are 5 • 5 • 5, or 53.
53
Answer 3
125 = 5
The prime factors of 125 are 5 • 5 • 5, which can be rewritten as 53. The cube root of
3 3
a cubed number is the number itself, so 5 = 5 . You have found the cube root, the
three identical factors that when multiplied together give 125. 125 is known as a perfect
cube because its cube root is an integer.
Example
Problem 3
Simplify. 32m5
Factor 32 into prime factors.
3
2• 2• 2• 2• 2• m5
© The Independent Institute of Education (Pty) Ltd 2021 Page 189 of 332
IIE Module Manual MAPC5112
There is one interesting fact about cube roots that is not true of square roots. Negative
numbers can’t have real number square roots, but negative numbers can have real
number cube roots! What is the cube root of −8? −8 = −2 because −2• −2• −2 = −8
3
. Remember, when you are multiplying an odd number of negative numbers, the result
is negative! In the example below, notice how 3
( −1)3 = −1 is used to simplify the
radical.
Example
Problem Simplify. 3
−27x 4 y 3
3
(−1)3 • (3)3 • x 3 • x • y 3
Answer 3
−27 x 4 y 3 = −3 xy 3 x
© The Independent Institute of Education (Pty) Ltd 2021 Page 190 of 332
IIE Module Manual MAPC5112
You could check your answer by performing the inverse operation. If you are right,
when you cube −3xy 3 x you should get −27x 4 y 3
−3 • −3 • −3 • x • x • x • y • y • y • 3 x • 3 x • 3 x
−27 • x 3 • y 3 • 3 x 3
−27 x 3 y 3 • x
−27 x 4 y 3
So, you can find the odd root of a negative number, but you cannot find the even root
of a negative number. This means you can simplify the radicals
3
−81, 5 −64 , and
7
−2187 , but you cannot simplify the radicals −100, 4 −16 , or 6 −2,500 .
Let’s look at another example.
Example
Problem
Simplify.
3
−24a5
Factor −24 to find
3
−1• 8 • 3 • a5
perfect cubes. Here,
−1 and 8 are the
perfect cubes.
Factor variables. You
3
( −1)3 • 23 • 3 • a3 • a2
are looking
for cube exponents, so
you factor
a5 into a3 and a2.
Separate the factors
3
( −1)3 • 3 23 • 3 a3 • 3 3 • a2
into individual radicals.
Simplify, using the
−1• 2 • a • 3 3 • a2
property
3
x3 = x .
This is the simplest
−2a 3 3a2
form of this expression;
all cubes have been
pulled out of the radical
expression.
Answer 3
−24a5 = −2a 3 3a2
© The Independent Institute of Education (Pty) Ltd 2021 Page 191 of 332
IIE Module Manual MAPC5112
Simplifying a radical
• If n is odd,
n
xn = x .
• If n is even, n
x n = x . (The absolute value accounts for the fact that if x is
negative and raised to an even power, that number will be positive, as will
the nth principal root of that number.)
Example
Problem Simplify. 100x 2 y 4
Answer 100 x 2 y 4 = 10 x y 2
© The Independent Institute of Education (Pty) Ltd 2021 Page 192 of 332
IIE Module Manual MAPC5112
6 Rational Exponents
Square roots are most often written using a radical sign, like this, 4 . But there is
another way to represent the taking of a root. You can use rational exponents instead
of a radical. A rational exponent is an exponent that is a fraction. For example, 4
1
can be written as 4 2 .
Can’t imagine raising a number to a rational exponent? They may be hard to get used
to, but rational exponents can actually help simplify some problems. Let’s explore the
relationship between rational (fractional) exponents and radicals.
Radicals and fractional exponents are alternate ways of expressing the same thing.
You have already seen how square roots can be expressed as an exponent to the
power of one-half.
Radical Exponent
Integer
Form Form
1
16 16 2 4
1
25 25 2 5
1
100 100 2 10
Let’s look at some more examples, but this time with cube roots. Remember, cubing a
number raises it to the power of three. Notice that in these examples, the denominator
of the rational exponent is the number 3.
Radical Exponent
Integer
Form Form
3 1
8 83 2
3 1
125 125 3 5
3 1
1000 1000 3 10
These examples help us model a relationship between radicals and rational exponents:
1
namely, that the nth root of a number can be written as either n
x or x n .
© The Independent Institute of Education (Pty) Ltd 2021 Page 193 of 332
IIE Module Manual MAPC5112
Radical Exponent
Form Form
1
x x2
3 1
x x3
4 1
x x4
… …
n 1
x xn
When faced with an expression containing a rational exponent, you can rewrite it using
a radical. In the table above, notice how the denominator of the rational exponent
1
determines the index of the root. So, an exponent of translates to the square root,
2
1 5 1
an exponent of translates to the fifth root or , and translates to the eighth
5 8
8
root or .
Example
Problem 4
Write 81 as an expression with a
rational exponent.
1
The radical form 4
can be rewritten as
814
1
the exponent . Remove the radical and
4
Example
Problem 1
3
Express (2 x ) in radical form.
3
2x Rewrite the expression with the fractional exponent as a
radical. The denominator of the fraction determines the
root, in this case the cube root.
1
The parentheses in ( 2x ) 3 indicate that the exponent
refers to everything within the parentheses.
Answer 1
3
(2 x ) = 3 2 x
© The Independent Institute of Education (Pty) Ltd 2021 Page 194 of 332
IIE Module Manual MAPC5112
Remember that exponents only refer to the quantity immediately to their left unless a
grouping symbol is used. The example below looks very similar to the previous
example with one important difference—there are no parentheses! Look what
happens.
Example
Problem 1
3
Express 2x in radical form.
Just as you can rewrite an expression with a rational exponent as a radical expression,
you can express a radical expression using a rational exponent.
Example
Problem Express 4 3 xy with rational exponents.
© The Independent Institute of Education (Pty) Ltd 2021 Page 195 of 332
IIE Module Manual MAPC5112
Example
Problem 1
4 2
Simplify. (36 x )
62 • x 4
62 • ( x 2 )2
6 • x2
Answer 1
(36 x 4 ) 2 = 6 x 2
Let’s explore some radical expressions now and see how to simplify them. Here’s a
3
radical expression that needs simplifying, a6 .
One method of simplifying this expression is to factor and pull out groups of a3, as
shown below in this example.
Example
Problem 3
Simplify. a6
Rewrite by
factoring out
3
a3 • a3
cubes.
Write each
3
a3 • 3 a3
factor under
its own radical
a•a and simplify.
Answer 3
a6 = a2
© The Independent Institute of Education (Pty) Ltd 2021 Page 196 of 332
IIE Module Manual MAPC5112
You can also simplify this expression by thinking about the radical as an expression
with a rational exponent, and using the principle that any radical in the form
n
a x can
x
be written using a fractional exponent in the form a n .
Example
Problem 3
Simplify. a6
6
Rewrite the radical using
a3
a rational exponent.
Answer 3
a6 = a2
Note that rational exponents are subject to all of the same rules as other exponents
when they appear in algebraic expressions.
Both simplification methods gave the same result, a2. Depending on the context of the
problem, it may be easier to use one method or the other, but for now, you’ll note that
you were able to simplify this expression more quickly using rational exponents than
when using the “pull-out” method.
Example
Problem Simplify. 4
81x 8 y 3
1 Rewrite the radical using rational
8 3 4
(81x y ) exponents.
1 8 3 Use the rules of exponents to simplify
81 • x • y
4 4 4
the expression.
1 3
(3 • 3 • 3 • 3) 4 x 2 y 4
1 3
4 4 2
(3 ) x y 4
3
3x 2 y 4
Again, the alternative method is to work on simplifying under the radical by using
factoring. For the example you just solved, it looks like this.
© The Independent Institute of Education (Pty) Ltd 2021 Page 197 of 332
IIE Module Manual MAPC5112
Example
Problem Simplify. 4
81x 8 y 3
4
81• 4 x 8 • 4 y 3 Rewrite the
expression.
4
3 • 3 • 3 • 3 • 4 x 2 • x 2 • x 2 • x 2 • 4 y 3 Factor each radicand.
4
34 • 4 ( x 2 )4 • 4 y 3 Simplify.
3 • x2 • 4 y 3
Answer 4
81x 8 y 3 = 3x 2 4 y 3
10b2c 2
Let’s try a more complicated expression, . This expression has two variables,
c 3 8b 4
a fraction, and a radical. Let’s take it step-by-step and see if using fractional exponents
can help us simplify it.
Let’s start by simplifying the denominator, since this is where the radical sign is located.
Example
Problem 10b2c 2
Simplify.
c 3 8b 4
10b 2c 2
Separate the factors in the denominator.
c • 3 8 • 3 b4
10b2c 2
Take the cube root of 8, which is 2.
c • 2 • 3 b4
b2
5•c • 4 Simplify the constant and c factors.
3
b
4
− Use the rule of negative exponents,
5cb2b 3
© The Independent Institute of Education (Pty) Ltd 2021 Page 198 of 332
IIE Module Manual MAPC5112
1 −4
n -x = x
, to rewrite 1 as b 3 .
n 4
b3
2
Combine the b factors by adding the
5cb 3
exponents.
Change the expression with the fractional
5c 3 b2
exponent back to radical form. By
convention, an expression is not usually
considered simplified if it has a fractional
exponent or a radical in the denominator.
Answer 10b2c 2
= 5c 3 b2
3 4
c 8b
Well, that took a while, but you did it. You applied what you know about fractional
exponents, negative exponents, and the rules of exponents to simplify the expression.
You can do more than just simplify radical expressions. You can multiply and divide
them, too. You can use your knowledge of exponents to help you when you have to
operate on radical expressions this way.
Let’s start with a quantity that you have seen before, 64 . You can simplify this square
root by thinking of it as 16 • 4 .
64 = 16 • 4
= 16 • 4
= 4•2
=8
If you think of the radicand as a product of two factors (here, thinking about 64 as the
product of 16 and 4), you can take the square root of each factor and then multiply the
© The Independent Institute of Education (Pty) Ltd 2021 Page 199 of 332
IIE Module Manual MAPC5112
This is an example of the Product Raised to a Power Rule. This rule states that the
product of two or more numbers raised to a power is equal to the product of each
number raised to the same power.
This should be a familiar idea. You have applied this rule when expanding expressions
such as (ab)x to ax • bx; now you are going to amend it to include radicals as well.
1
Imagine that the exponent x is not an integer but is a unit fraction, like , so that you
3
1
3
have the expression (ab ) . According to the Product Raised to a Power Rule, this can
1 1
also be written a 3 • b 3 , which is the same as
3
a • 3 b , since fractional exponents can
1 1 1
be rewritten as roots. So, for the same reason that (ab ) x = a x • b x , you find that
x
ab = x a • x b .
1 1 1
The Product Raised to a Power Rule is important because you can use it to multiply
radical expressions. Note that the roots are the same—you can combine square roots
with square roots, or cube roots with cube roots, for example. But you can’t multiply a
square root and a cube root using this rule.
Example
Problem
Simplify. 18 • 16
288
144 • 2 Look for perfect squares in the
radicand, and rewrite the
© The Independent Institute of Education (Pty) Ltd 2021 Page 200 of 332
IIE Module Manual MAPC5112
12 • 2 Simplify, using x2 = x .
12 • 2
Answer
18 • 16 = 12 2
Using the Product Raised to a Power Rule, you can take a seemingly complicated
You may have also noticed that both 18 and 16 can be written as products
involving perfect square factors. How would the expression change if you simplified
each radical first, before multiplying?
Example
Problem Simplify.
18 • 16
9 • 2 • 4 • 4 Look for perfect squares in
each radicand, and rewrite as
3•3•2 • 4• 4
the product of two factors.
3 • 2 • 4 Simplify, using x2 = x .
3• 2•4
12 Multiply.
Answer
18 • 16 = 12 2
In both cases, you arrive at the same product, 12 2 . It does not matter whether you
multiply the radicands or simplify each radical first.
You multiply radical expressions that contain variables in the same manner. As long
as the roots of the radical expressions are the same, you can use the Product Raised
© The Independent Institute of Education (Pty) Ltd 2021 Page 201 of 332
IIE Module Manual MAPC5112
to a Power Rule to multiply and simplify. Look at the two examples that follow. In both
problems, the Product Raised to a Power Rule is used right away and then the
expression is simplified.
Example
Problem
Simplify. 12x 3 • 3 x , x 0
12• 3 • x 3 • x
3 +1
36 • x 3+1 Recall that x • x = x .
3
36 • x 4
6 • x2
Answer
12x 3 • 3 x = 6 x 2
Example
Problem Simplify. 3
x 5 y 2 • 5 3 8x 2 y 4
53 8 • x5 • x2 • y 2 • y 4
5 3 8 • x 5 + 2 • y 2+ 4
53 8 • x7 • y 6
© The Independent Institute of Education (Pty) Ltd 2021 Page 202 of 332
IIE Module Manual MAPC5112
to be rewritten as
6 +1
x = (x ) • x .
2 3
5• 2• x 2 • y 2 • 3 x
Answer 3
x 5 y 2 • 5 3 8 x 2 y 4 = 10 x 2 y 2 3 x
This next example is slightly more complicated because there are more than two
radicals being multiplied. In this case, notice how the radicals are simplified before
multiplication takes place. (Remember that the order you choose to use is up to you—
you will find that sometimes it is easier to multiply before simplifying, and other times
it is easier to simplify before multiplying. With some practice, you may be able to tell
which is which before you approach the problem, but either order will work for all
problems.)
Example
Problem Simplify. 2 4 16 x 9 • 4 y 3 • 4 81x 3 y , x 0 , y 0
© The Independent Institute of Education (Pty) Ltd 2021 Page 203 of 332
IIE Module Manual MAPC5112
Answer
2 4 16 x 9 • 4 y 3 • 4 81x 3 y = 12x 3 y, x 0, y 0
You can use the same ideas to help you figure out how to simplify and divide radical
expressions. Recall that the Product Raised to a Power Rule states that
x
ab = x a • x b . Well, what if you are dealing with a quotient instead of a product?
There is a rule for that, too. The Quotient Raised to a Power Rule states that
x
a ax
b = . Again, if you imagine that the exponent is a rational number, then you can
bx
1 1
a a
x x
a xa
make this rule applicable for roots as well: = 1 , so x = .
b b xb
bx
1 1
a x ax
For any real numbers a and b (b ≠ 0) and any positive integer x: = 1
b
bx
a xa
For any real numbers a and b (b ≠ 0) and any positive integer x: x =
b xb
As you did with multiplication, you will start with some examples featuring integers
3
24 xy 4
before moving on to more complex expressions like .
3
8y
Example
Problem 48
Simplify.
25
48 a xa
Use the rule x = to create two
25 b xb
radicals; one in the numerator and one
in the denominator.
© The Independent Institute of Education (Pty) Ltd 2021 Page 204 of 332
IIE Module Manual MAPC5112
(4)2 • 3
(5)2
4 • 3 Simplify.
5
Answer 48 4 3
=
25 5
Example
Problem 640
Simplify. 3
40
3
640 Rewrite using the Quotient Raised to a
3 Power Rule.
40
3
64 • 10 Simplify each radical. Look for perfect
cubes in the radicand, and rewrite the
3
8•5
radicand as a product of factors.
Identify and pull out perfect cubes.
3
(4)3 • 10
3
(2)3 • 5
3
(4)3 • 3 10
3
(2)3 • 3 5
4 • 3 10
2• 3 5
© The Independent Institute of Education (Pty) Ltd 2021 Page 205 of 332
IIE Module Manual MAPC5112
2 •1• 3 2
Answer 640
3 = 23 2
40
That was a lot of effort, but you were able to simplify using the Quotient Raised to a
Power Rule. What if you found the quotient of this expression by dividing within the
radical first, and then took the cube root of the quotient?
Example
Problem 3
640
Simplify. 3
40
3
640 Since both radicals are cube roots, you
x
40 can use the rule a = x a to create a
x
b b
single rational expression underneath
the radical.
3
16
Look for perfect cubes in the radicand,
3
8•2
and rewrite the radicand as a product of
factors.
3
(2)3 • 2 Identify perfect cubes and pull them out.
3
(2)3 • 3 2
2• 3
2 Simplify.
Answer 3
640
3
= 23 2
40
© The Independent Institute of Education (Pty) Ltd 2021 Page 206 of 332
IIE Module Manual MAPC5112
As with multiplication, the main idea here is that sometimes it makes sense to divide
and then simplify, and other times it makes sense to simplify and then divide.
Whichever order you choose, though, you should arrive at the same final expression.
Now let’s turn to some radical expressions containing variables. Notice that the
process for dividing these is the same as it is for dividing integers.
Example
Problem 30 x
Simplify. , x 0
10 x
3 • 10 x 30 x
Simplify by
10 x 10 x
identifying similar factors in
10 x the numerator and
3• denominator and then
10 x
identifying factors of 1.
3 •1
Answer 30 x
= 3
10 x
Example
Problem 3
24 xy 4
Simplify. ,y 0
3
8y
8• 3• x • y3 • y 24 xy 4
3 Simplify 3 by
8• y 8y
identifying similar factors in
3 • x • y 8y 3 the numerator and
3 • denominator and then
1 8y
identifying factors of 1.
© The Independent Institute of Education (Pty) Ltd 2021 Page 207 of 332
IIE Module Manual MAPC5112
3 • x • y3
3 •1
1
3
3xy 3 Identify perfect cubes and
pull them out of the radical.
3
( y )3 3 x
3
( y )3 3
3x Simplify.
Answer 3
24 xy 4
= y 3 3x
3
8y
As you become more familiar with dividing and simplifying radical expressions, make
sure you continue to pay attention to the roots of the radicals that you are dividing. For
8y 2 8y 2
example, while you can think of as equivalent to since both the
225y 4 225 y 4
numerator and the denominator are square roots, notice that you cannot express
8y 2 8y 2
as 4 . In this second case, the numerator is a square root and the
4
225y 4 225 y 4
denominator is a fourth root.
The Product Raised to a Power Rule and the Quotient Raised to a Power Rule can be
used to simplify radical expressions as long as the roots of the radicals are the same.
The Product Rule states that the product of two or more numbers raised to a power is
equal to the product of each number raised to the same power. The same is true of
roots:
x
ab = x a • x b . When dividing radical expressions, the rules governing
a xa
quotients are similar: x = .
b xb
Adding Radicals
Let’s look at some examples. In this first example, both radicals have the same root
and index.
Example
Problem Add. 3 11 + 7 11
© The Independent Institute of Education (Pty) Ltd 2021 Page 208 of 332
IIE Module Manual MAPC5112
Answer 3 11 + 7 11 = 10 11
This next example contains more addends. Notice how you can combine like terms
(radicals that have the same root and index) but you cannot combine unlike terms.
Example
Problem
Add. 5 2 + 3 +4 3 +2 2
5 2 +2 2 + 3 +4 3 Rearrange terms
so that like radicals
are next to each
other. Then add.
Answer
5 2 + 3 +4 3 +2 2 =7 2 +5 3
Notice that the expression in the previous example is simplified even though it has two
Example
Problem Add. 3 x + 12 3 xy + x
3 x + x + 12 3 xy Rearrange terms so
that like radicals are
next to each other.
Then add.
Answer 3 x + 12 3 xy + x = 4 x + 12 3 xy
Sometimes you may need to add and simplify the radical. If the radicals are different,
try simplifying first—you may end up being able to combine the radicals at the end, as
shown in these next two examples.
© The Independent Institute of Education (Pty) Ltd 2021 Page 209 of 332
IIE Module Manual MAPC5112
Example
Problem
Add and simplify. 2 3 40 + 3 135
2 3 (2)3 • 5 + 3 (3)3 • 5
2 3 (2)3 • 3 5 + 3 (3)3 • 3 5
2• 2• 3 5 + 3• 3 5 Simplify.
43 5 + 33 5 Add.
Answer
2 3 40 + 3 135 = 7 3 5
Example
Problem Add and simplify. x 3 xy 4 + y 3 x 4 y
x 3 y 3 • 3 xy + y 3 x 3 • 3 xy
xy • 3 xy + xy • 3 xy
Subtracting Radicals
Subtraction of radicals follows the same set of rules and approaches as addition—the
radicands and the indices (plural of index) must be the same for two (or more) radicals
to be subtracted. In the three examples that follow, subtraction has been rewritten as
addition of the opposite.
© The Independent Institute of Education (Pty) Ltd 2021 Page 210 of 332
IIE Module Manual MAPC5112
Example
Problem
Subtract. 5 13 - 3 13
Example
Problem
Subtract. 4 3 5a - 3 3a - 2 3 5a
Example
Problem Subtract and simplify.
5 4 a5b - a 4 16ab, where a 0 and b 0
5 • a 4 a • b − a • 24 a • b
5a 4 ab − 2a 4 ab
Answer
5 4 a5b − a 4 16ab = 3a 4 ab
Combining radicals is possible when the index and the radicand of two or more radicals
are the same. Radicals with the same index and radicand are known as like radicals.
It is often helpful to treat radicals just as you would treat variables: like radicals can be
© The Independent Institute of Education (Pty) Ltd 2021 Page 211 of 332
IIE Module Manual MAPC5112
added and subtracted in the same way that like variables can be added and subtracted.
Sometimes, you will need to simplify a radical expression before it is possible to add
or subtract like terms.
A basic strategy for solving radical equations is to isolate the radical term first, and
then raise both sides of the equation to a power to remove the radical. (The reason for
using powers will become clear in a moment.) This is the same type of strategy you
used to solve other, non-radical equations—rearrange the expression to isolate the
variable you want to know, and then solve the resulting equation.
There are two key ideas that you will be using to solve radical equations. The first is
that if a = b , then a 2 = b 2 . (This property allows you to square both sides of an
equation and remain certain that the two sides are still equal.) The second is that if the
( x)
2
square root of any nonnegative number x is squared, then you get x: = x . (This
property allows you to “remove” the radicals from your equations.)
Let’s start with a radical equation that you can solve in a few steps: x −3 = 5.
Example
Problem Solve. x −3 = 5
To check your solution, you can substitute 64 in for x in the original equation. Does
64 − 3 = 5 ? Yes—the square root of 64 is 8, and 8 − 3 = 5.
© The Independent Institute of Education (Pty) Ltd 2021 Page 212 of 332
IIE Module Manual MAPC5112
Notice how you combined like terms and then squared both sides of the equation in
this problem. This is a standard method for removing a radical from an equation. It is
important to isolate a radical on one side of the equation and simplify as much as
possible before squaring. The fewer terms there are before squaring, the fewer
additional terms will be generated by the process of squaring.
In the example above, only the variable x was underneath the radical. Sometimes you
will need to solve an equation that contains multiple terms underneath a radical. Follow
the same steps to solve these, but pay attention to a critical point—square both sides
of an equation, not individual terms. Watch how the next two problems are solved.
Example
Problem
Solve. x +8 =3
( ) = (3)
Notice how the radical
2 2
x +8 contains a binomial: x + 8.
Square both sides to
remove the radical.
x +8 =9
( )
2
x +8 = x + 8 . Now
x =1
simplify the equation and
solve for x.
Example
Problem
Solve. 1 + 2x + 3 = 6
( ) = (5)
2 2 remove the binomial from the
2x + 3
radical.
x = 11
© The Independent Institute of Education (Pty) Ltd 2021 Page 213 of 332
IIE Module Manual MAPC5112
7 Complex Numbers
Several times in your learning of mathematics, you have been introduced to new kinds
of numbers. Each time, these numbers made possible something that seemed
impossible! Before you learned about negative numbers, you couldn’t subtract a
greater number from a lesser one, but negative numbers give us a way to do it. When
you were learning to divide, you initially weren't able to do a problem like 13 divided by
5 because 13 isn't a multiple of 5. You then learned how to do this problem writing the
3
answer as 2 remainder 3. Eventually, you were able to express this answer as 2 .
5
Using fractions allowed you to make sense of this division.
Up to now, you’ve known it was impossible to take a square root of a negative number.
This is true, using only the real numbers. But here you will learn about a new kind of
number that lets you work with square roots of negative numbers! Like fractions and
negative numbers, this new kind of number will let you do what was previously
impossible.
You really need only one new number to start working with the square roots of negative
numbers. That number is the square root of −1, −1 . The real numbers are those that
can be shown on a number line—they seem pretty real to us! When something’s not
real, you often say it is imaginary. So let’s call this new number i and use it to represent
the square root of −1.
© The Independent Institute of Education (Pty) Ltd 2021 Page 214 of 332
IIE Module Manual MAPC5112
i = −1
i 2 = −1
The number i allows us to work with roots of all negative numbers, not just −1 . There
are two important rules to remember: −1 = i , and ab = a b . You will use these
rules to rewrite the square root of a negative number as the square root of a positive
number times −1 . Next you will simplify the square root and rewrite −1 as i. Let’s
try an example.
Example
Problem Simplify. −4
−4 = 4 • −1 = 4 −1 ab = a b to
Use the rule
rewrite this as a product using
−1 .
Answer −4 = 2i
Example
Problem
Simplify. −18
© The Independent Institute of Education (Pty) Ltd 2021 Page 215 of 332
IIE Module Manual MAPC5112
Remember to write i in
front of the radical.
Answer
18 = 3i 2
Example
Problem Simplify. − −72
− −72 = − 72 • −1 = − 72 −1 ab = a b
Use the rule to rewrite
this as a product using −1 .
You may have wanted to simplify − −72 using different factors. Some may have
Example: −18 = 9 −2 = 9 2 −1 = 3i 2
Complex numbers have the form a + bi, where a and b are real numbers and i is the
square root of −1. All real numbers can be written as complex numbers by setting b =
© The Independent Institute of Education (Pty) Ltd 2021 Page 216 of 332
IIE Module Manual MAPC5112
0. Imaginary numbers have the form bi and can also be written as complex numbers
by setting a = 0. Square roots of negative numbers can be simplified using −1 = i
and ab = a b.
Any time new kinds of numbers are introduced, one of the first questions that needs to
be addressed is, “How do you add them?” In this topic, you’ll learn how to add complex
numbers and also how to subtract, multiply, and divide them.
(6x + 8) + (4x + 2)
To simplify this expression, you combine the like terms, 6x and 4x. These are like terms
because they have the same variable with the same exponents. Similarly, 8 and 2 are
like terms because they are both constants, with no variables.
(6 3 + 8) + (4 3 + 2) = 10 3 + 10
You can add 6 3 to 4 3 because the two terms have the same radical, 3 , just as
6x and 4x have the same variable and exponent.
The number i looks like a variable, but remember that it is equal to −1 . The great
thing is you have no new rules to worry about—whether you treat it as a variable or a
radical, the exact same rules apply to adding and subtracting complex numbers. You
combine the imaginary parts (the terms with i), and you combine the real parts.
Example
Problem Add. (−3 + 3i) + (7 – 2i)
Example
© The Independent Institute of Education (Pty) Ltd 2021 Page 217 of 332
IIE Module Manual MAPC5112
Again, consider the following expression. Before reading further, consider how you
would simplify it.
(5x)(−3x)
You can simplify by multiplying the coefficients together, then the variables.
(5x)( −3x) = (5)( −3)(x)(x)
= −15x2
Multiplying two imaginary (but not complex!) numbers together works in a similar way,
but there is an additional step. Start with the same method to multiply 5i and −3i.
(5i)( −3i) = (5)( −3)(i)(i)
= −15i2
When you multiply a square root by itself, you get the number under the radical. This
is what square root means.
( 3)( 3) = 3
( 15)( 15) = 15
i 2 = (i )(i )
= ( −1)( −1)
= −1
So, the final step to simplifying (5i)( −3i) = −15i2 is to replace i2 with −1.
© The Independent Institute of Education (Pty) Ltd 2021 Page 218 of 332
IIE Module Manual MAPC5112
= −15i2
= −15(−1)
= 15
Example
Problem Multiply. (3i)(2i)
6(−1) = −6 Multiply.
Answer (3i)(2i) = −6
Notice that the product of two imaginary numbers is a real number! We will see this
again when we multiply two complex numbers.
So far, each operation with complex numbers has worked just like the same operation
with radical expressions. This should no longer be a surprise—the number i is a radical,
after all, so complex numbers are radical expressions!
Let’s look at division in two parts, like we did multiplication. First, let’s look at a situation
in which the divisor is a monomial.
Example
Problem Simplify. −24i ÷ 6
Example
© The Independent Institute of Education (Pty) Ltd 2021 Page 219 of 332
IIE Module Manual MAPC5112
Example
Problem Simplify. 56 ÷ −7i
When the divisor (that is, the denominator in the fraction) is a complex number with
non-zero real and imaginary parts, you must rationalize the denominator using the
© The Independent Institute of Education (Pty) Ltd 2021 Page 220 of 332
IIE Module Manual MAPC5112
complex conjugate. Remember that the product of a complex number with its complex
conjugate is always a real number, so the denominator will be a real number. That
means the result will be equivalent, but rationalized.
Example
Problem Simplify. (56 – 8i) ÷ (14 + 10i)
(28 − 4i )(7 − 5i ) 28(7) + 28( −5i ) + ( −4i )(7) + ( −4i )( −5 i ) Expand the
=
(7 + 5i )(7 − 5i ) 7(7) + 7( −5i ) + 5i (7) + 5i ( −5i ) numerator and the
denominator.
196 − 140i − 28i + 20i 2
= Remember, the
49 − 35i + 35i − 25i 2 denominator
196 − 168i + 20i 2 should be a real
=
49 − 25i 2 number (no i term)
if you chose the
correct complex
conjugate and
performed the
multiplication
correctly.
© The Independent Institute of Education (Pty) Ltd 2021 Page 221 of 332
IIE Module Manual MAPC5112
196 − 168i + 20i 2 196 − 168i + 20( −1) Replace i2 with −1 and
= simplify. Be sure to replace
49 − 25i 2 49 − 25( −1)
i2 in both the numerator and
196 − 168i − 20
= the denominator!
49 + 25
176 − 168i
=
74
176 − 168i 176 168 The quotient can be written
= − i
74 74 74 in the form
a + bi using fractions for both
a and b.
Complex numbers can be added, subtracted, multiplied, and divided using the same
ideas you used for radicals and variables. With multiplication and division, you may
need to replace i2 with −1 and simplify further.
Grossman, P. 2009. Discrete mathematics for computing. (3rd ed) New York (NY):
Palgrave Macmillian.
© The Independent Institute of Education (Pty) Ltd 2021 Page 222 of 332
IIE Module Manual MAPC5112
Bogart, K, Drysdale, S, Stein, C and Kenneth Bogart, P. 2004. Discrete Math for
Computer Science Students.
9 Activities
Complete the activities on IIELearn.
10 Exercises
Refer to the workbook for exercises.
11 Glossary of Terms
© The Independent Institute of Education (Pty) Ltd 2021 Page 223 of 332
IIE Module Manual MAPC5112
equation.
like terms Terms that contain the same variables raised to the same
powers. For example, 3x and −8x are like terms, as are
8xy2 and 0.5xy2.
distributive The product of a sum and a number is the same as the sum of
property of the product of each addend and the number. For example,
multiplication 3(4 + 2) = 3(4) + 3(2).
over addition
greatest The product of the prime factors that two or more terms have in
common factor common. The greatest common factor of xyz and 3xy is xy.
(GCF)
monomial A polynomial with exactly one term. 4x, −5y2, and 6 are all
examples of monomials.
perfect square A trinomial that is the product of a binomial times itself, such as
trinomial a2 + 2ab + b2 (from (a + b)2), and a2 – 2ab + b2 (from (a –
b)2).
prime The process of breaking a number down into its prime factors.
factorization
prime number A prime number is a natural number with exactly two distinct
factors, 1 and itself. The number 1 is not a prime number
© The Independent Institute of Education (Pty) Ltd 2021 Page 224 of 332
IIE Module Manual MAPC5112
completing the A method for solving quadratic equations by rewriting one side
square of the equation as a squared binomial.
complex Two complex numbers for which the real parts are equal and the
conjugate, imaginary parts are additive inverses. a + bi and a – bi are
complex complex conjugates.
conjugates
complex A number in the form a + bi, where a and b are real numbers
number and i is the square root of −1.
conjugate pair A pair of binomials that, when multiplied, follow the pattern:
(a + b )(a − b ) = a 2
−b
2
cube root The number which, when multiplied together three times yields
the original number. For example, the cube root of 64 is 4
because 4 • 4 • 4 = 64.
© The Independent Institute of Education (Pty) Ltd 2021 Page 225 of 332
IIE Module Manual MAPC5112
distributive The product of a sum (or a difference) and a number is the same
property of as the sum (or difference) of the product of each addend (or
multiplication each number being subtracted) and the number. For example,
3(4 + 2) = 3(4) + 3(2), and 3(4 – 2) = 3(4) – 3(2).
imaginary A number in the form bi, where b is a real number and i is the
number square root of −1.
index The small positive integer just outside and above the radical
symbol that denotes the root. For example, 3 denotes the
cube root.
perfect square A trinomial that is the product of a binomial times itself, such as
trinomial a2 + 2ab + b2 (from (a + b)2), and a2 – 2ab + b2 (from (a – b)2).
principal root
The positive square root of a number, as in 16 = 4 . By
definition, the radical symbol always means to find the principal
root. Note that zero has only one square root, itself (since 0 • 0
= 0).
product raised The product of two or more non-zero numbers raised to a power
to a power rule, equals the product of each number raised to the same power:
product raised (ab)x = ax • bx
to a power
quotient raised For any real numbers a and b (b ≠ 0) and any positive integer x:
to a power rule 1
1
a x ax
=
b
1
b x
© The Independent Institute of Education (Pty) Ltd 2021 Page 226 of 332
IIE Module Manual MAPC5112
radical
expressions
radical symbol The symbol, , used to denote the process of taking a root of
a quantity.
square root A number that when multiplied by itself gives the original
nonnegative number. For example, 6 • 6 = 36 and −6 • −6 = 36
so 6 is the positive square of 36 and −6 is the negative square
root of 36.
© The Independent Institute of Education (Pty) Ltd 2021 Page 227 of 332
IIE Module Manual MAPC5112
1 Introduction to Preliminaries
Mathematical Statements
Communication in mathematics requires more precision than many other subjects, and
thus we should take a few pages here to consider the basic building blocks:
mathematical statements.
© The Independent Institute of Education (Pty) Ltd 2021 Page 228 of 332
IIE Module Manual MAPC5112
EXAMPLE
These are statements (in fact, atomic statements):
• Telephone numbers have 10 digits.
• The moon is made of cheese.
• 42 is perfect square.
• Every even number greater than 2 can be expressed as the sum of two
primes.
• 3 + 7 = 12
These are not statements:
The reason the last sentence is not a statement is because it contains a variable.
Depending on what x is, the sentence is either true or false, but right now it is neither.
One way to make the sentence into a statement is to specify the value of the variable
in some way. This could be done in a number of ways.
This is an example of quantifying over a variable, which we will discuss more in a bit.
You can build more complicated (molecular) statements out of simpler (atomic or
molecular) ones using logical connectives.
Note that we can break this down into two smaller statements. The two shorter
statements are connected by an “and.” We will consider 5 connectives: “and” (Sam
is a man and Chris is a woman), “or” (Sam is a man or Chris is a woman),
“if. . . , then. . . ”
© The Independent Institute of Education (Pty) Ltd 2021 Page 229 of 332
IIE Module Manual MAPC5112
The first four are called binary connectives (because they connect two statements)
while “not” is an example of a unary connective (since it applies to a single
statement).
Which connective we use to modify statement(s) will determine the truth value of the
molecular statement (that is, whether the statement is true or false), based on the truth
values of the statements being modified. It is important to realize that we do not need
to know what the parts actually say, only whether those parts are true or false. So to
analyse logical connectives, it is enough to consider propositional variables
(sometimes called sentential variables), usually capital letters in the middle of the
alphabet: P, Q, R, S, . . .
These are variables that can take on one of two values: T or F. We also have
symbols for the logical connectives: ∧, ∨, →, ↔, ¬.
The truth value of a statement is determined by the truth value(s) of its part(s),
depending on the connectives:
© The Independent Institute of Education (Pty) Ltd 2021 Page 230 of 332
IIE Module Manual MAPC5112
Note that for us, or is the inclusive or (and not the sometimes used exclusive or)
meaning that P ∨ Q is in fact true when both P and Q are true. As for the other
connectives, “and” behaves as you would expect, as does negation. The biconditional
(if and only if) might seem a little strange, but you should think of this as saying the two
parts of the statements are equivalent.
This leaves only the conditional P → Q which has a slightly different meaning in
mathematics than it does in ordinary usage. However, implications are so common
and useful in mathematics that we must develop fluency with their use, and as such,
they deserve their own subsection.
Implications
“a2 + b2 = c2.”
This is absolutely not correct. For one thing, that is not a statement since it has three
variables in it. Perhaps they imply that this should be true for any values of the
variables?
So 12 + 52 = 22?
Well, the equation is true as long as a and b are the legs or a right triangle and c is
the hypotenuse. In other words:
© The Independent Institute of Education (Pty) Ltd 2021 Page 231 of 332
IIE Module Manual MAPC5112
This is a reasonable way to think about implications: our claim is that the conclusion
(“then” part) is true, but on the assumption that the hypothesis (“if” part) is true. We
make no claim about the conclusion in situations when the hypothesis is false.
Still, it is important to remember that an implication is a statement, and therefore is
either true or false. The truth value of the implication is determined by the truth values
of its two parts. To agree with the usage above, we say that an implication is true either
when the hypothesis is false, or when the conclusion is true. This leaves only one way
for an implication to be false: when the hypothesis is true and the conclusion is false.
EXAMPLE
If Bob gets a 90 on the final, then Bob will pass the class.
This is definitely an implication: P is the statement “Bob gets a 90
on the final,” and Q is the statement “Bob will pass the class.”
Then I have not lied; my statement is true. However, if Bob did get
a 90 on the final and did not pass the class, then I lied, making the
statement false.
The tricky case is this: what if Bob did not get a 90 on the final?
© The Independent Institute of Education (Pty) Ltd 2021 Page 232 of 332
IIE Module Manual MAPC5112
particular, if you claim that P → Q is false, you are not saying that P does not imply Q,
but rather that P is true and Q is false.
EXAMPLE
1. 0=1→ 1 1
SOLUTION
All four of the statements are true. Remember, the only way
for an implication to be false is for the if part to be true and
the then part to be false.
It is important to understand the conditions under which an implication is true not only
to decide whether a mathematical statement is true, but in order to prove that it is.
Proofs might seem scary (especially if you have had a bad high school geometry
experience) but all we are really doing is explaining (very carefully) why a statement is
true. If you understand the truth conditions for an implication, you already have the
outline for a proof.
© The Independent Institute of Education (Pty) Ltd 2021 Page 233 of 332
IIE Module Manual MAPC5112
There are other techniques to prove statements (implications and others) that we will
encounter throughout our studies, and new proof techniques are discovered all the
time. Direct proof is the easiest and most elegant style of proof and has the advantage
that such a proof often does a great job of explaining why the statement is true.
EXAMPLE
This sort of argument shows up outside of math as well. If you ever found yourself
starting an argument with “hypothetically, let’s assume,” then you have attempted a
direct proof of your desired conclusion.
© The Independent Institute of Education (Pty) Ltd 2021 Page 234 of 332
IIE Module Manual MAPC5112
number is odd does not mean it is prime. If a shape is a square, then it is a rectangle.
But it is false that if a shape is a rectangle, then it is a square. While this happens
often, it does not always happen. For example, the
Pythagorean theorem has a true converse: if a 2 + b 2 = c 2 , then the triangle with sides
a, b, and c is a right triangle. Whenever you encounter an implication in mathematics,
it is always reasonable to ask whether the converse is true.
The contrapositive, on the other hand, always has the same truth value as its original
implication. This can be very helpful in deciding whether an implication is true: often it
is easier to analyse the contrapositive.
EXAMPLE
True or false: If you draw any nine playing cards from a regular deck, then you will
have at least three cards all of the same suit. Is the converse true?
SOLUTION
True. The original implication is a little hard to analyse because there are so
many different combinations of nine cards. But consider the contrapositive: If
you don’t have at least three cards all of the same suit, then you don’t have nine
cards. It is easy to see why this is true: you can at most have two cards of each
of the four suits, for a total of eight cards (or fewer).
The converse: If you have at least three cards all of the same suit, then you
have nine cards. This is false. You could have three spades and nothing else.
Note that to demonstrate that the converse (an implication) is false, we provided
an example where the hypothesis is true (you do have three cards of the same
suit), but where the conclusion is false (you do not have nine cards).
EXAMPLE
Suppose I tell Sue that if she gets a 93% on her final, then
she will get an A in the class. Assuming that what I said is
true, what can you conclude in the following cases:
© The Independent Institute of Education (Pty) Ltd 2021 Page 235 of 332
IIE Module Manual MAPC5112
SOLUTION
Note first that whenever P → Q and P are both true
statements, Q must be true as well. For this problem,
take P to mean “Sue gets a 93% on her final” and Q
to mean “Sue will get an A in the class.”
You can think of “if and only if” statements as having two parts: an implication and its
converse. We might say one is the “if” part, and the other is the “only if” part. We also
sometimes say that “if and only if” statements have two directions: a forward direction
(P → Q) and a backwards direction (P ← Q, which is really just sloppy notation for Q
→ P).
© The Independent Institute of Education (Pty) Ltd 2021 Page 236 of 332
IIE Module Manual MAPC5112
Let’s think a little about which part is which. Is P → Q the “if” part or the “only if” part?
Perhaps we should look at an example:
EXAMPLE
Suppose it is true that I sing if and only if I’m in the shower. We know
this means both that if I sing, then I’m in the shower, and also the
converse, that if I’m in the shower, then I sing. Let P be the statement,
“I sing,” and Q be, “I’m in the shower.” So P → Q is the statement “if I
sing, then I’m in the shower.” Which part of the if and only if statement
is this?
It is not terribly important to know which part is the “if” or “only if” part, but this does get
at something very, very important: there are many ways to state an implication! The
problem is, since these are all different ways of saying the same implication, we cannot
use truth tables to analyse the situation. Instead, we just need good English skills.
EXAMPLE
Rephrase the implication, “if I dream, then I am asleep” in as
many different ways as possible. Then do the same for the
converse.
SOLUTION
The following are all equivalent to the original implication:
1. I am asleep if I dream.
2. I dream only if I am asleep.
3. In order to dream, I must be asleep.
4. To dream, it is necessary that I am asleep.
5. To be asleep, it is sufficient to dream.
6. I am not dreaming unless I am asleep.
1. I dream if I am asleep.
2. I am asleep only if I dream.
3. It is necessary that I dream in order to be asleep.
4. It is sufficient that I be asleep in order to dream.
5. If I don’t dream, then I’m not asleep.
© The Independent Institute of Education (Pty) Ltd 2021 Page 237 of 332
IIE Module Manual MAPC5112
Hopefully, you agree with the above example. We include the “necessary and
sufficient” versions because those are common when discussing mathematics. In fact,
let’s agree once and for all what they mean:
Thinking about the necessity and sufficiency of conditions can also help when writing
proofs and justifying conclusions. If you want to establish some mathematical fact, it is
helpful to think what other facts would be enough (be sufficient) to prove your fact. If
you have an assumption, think about what must also be necessary if that hypothesis
is true.
Quantifiers
where P(n) means “ n is prime.” But this is not quite right. For one thing, because this
sentence has a free variable (that is, a variable that we have not specified anything
about), it is not a statement. Now, if we plug in a specific value for n, we do get a
statement. In fact, it turns out that no matter what value we plug in for n, we get a
true implication. What we really want to say is that for all values of n, if n is prime,
then n + 7 is not. We need to quantify the variable.
Although there are many types of quantifiers in English (e.g., many, few, most, etc.) in
mathematics we, for the most part, stick to two: existential and universal.
© The Independent Institute of Education (Pty) Ltd 2021 Page 238 of 332
IIE Module Manual MAPC5112
∀x∃ y ( y < x ).
You would read this, “for every x there is some y such that y is less than x.” Is this
true? The answer depends on what our domain of discourse is: when we say “for all”
x, do we mean all positive integers or all real numbers or all elements of some other
set? Usually this information is implied. In discrete mathematics, we almost always
quantify over the natural numbers, 0, 1, 2, , so let’s take that for our domain of
discourse here.
For the statement to be true, we need it to be the case that no matter what natural
number we select, there is always some natural number that is strictly smaller. Perhaps
we could let y be x − 1? But here is the problem: what if x = 0? Then y = −1 and that
is not a number! (in our domain of discourse). Thus we see that the statement is false
because there is a number which is less than or equal to all other numbers. In symbols,
∃x∀ y ( y ≥ x ).
To show that the original statement is false, we proved that the negation was true.
Notice how the negation and original statement compare. This is typical.
Essentially, we can pass the negation symbol over a quantifier, but that causes the
quantifier to switch type. This should not be surprising: if not everything has a property,
then something doesn’t have that property. And if there is not something with a
property, then everything doesn’t have that property.
2 Sets
The most fundamental objects we will use in our studies (and really in all of math) are
sets. Much of what follows might be review, but it is very important that you are fluent
in the language of set theory. Most of the notation we use below is standard, although
some might be a little different than what you have seen before.
For us, a set will simply be an unordered collection of objects. Two examples: we could
consider the set of all actors who have played The Doctor on Doctor Who, or the set
of natural numbers between 1 and 10 inclusive. In the first case, Tom Baker is an
element (or member) of the set, while Idris Elba, among many others, is not an element
© The Independent Institute of Education (Pty) Ltd 2021 Page 239 of 332
IIE Module Manual MAPC5112
of the set. Also, the two examples are of different sets. Two sets are equal exactly if
they contain the exact same elements. For example, the set containing all of the vowels
in the declaration of independence is precisely the same set as the set of vowels in the
word “questionably” (namely, all of them); we do not care about order or repetitions,
just whether the element is in the set or not.
Notation
A = {1, 2, 3 } .
This is read, “A is the set containing the elements 1, 2 and 3.” We use curly braces
“{, }” to enclose elements of a set. Some more notation:
a ∈ {a, b, c}.
The symbol “∈” is read “is in” or “is an element of.” Thus the above means that a is
an element of the set containing the letters a, b, and c. Note that this is a true
statement. It would also be true to say that d is not in that set:
d rf {a, b, c}.
We have described the sets above by listing their elements. Sometimes this is hard to
do, especially when there are a lot of elements in the set (perhaps infinitely many).
For instance, if we want A to be the set of all even natural numbers, would could write,
A = {0, 2, 4, 6, . . . } ,
A = {x ∈ N : ∃n ∈ N(x = 2n)}.
© The Independent Institute of Education (Pty) Ltd 2021 Page 240 of 332
IIE Module Manual MAPC5112
Breaking that down: “x ∈ N” means x is in the set N (the set of natural numbers,
{0, 1, 2, . . .}), “:” is read “such that” and “∃n ∈ N(x = 2n) ” is read “there exists an n
in the natural numbers for which x is two
times n” (in other words, x is even). Slightly easier might be,
A = {x : x is even}.
Note: Sometimes people use | or 3 for the “such that” symbol instead of the colon.
Defining a set using this sort of notation is very useful, although it takes some
practice to read them correctly. It is a way to describe the set of all things that satisfy
some condition (the condition is the logical statement after the “:” symbol). Here are
some more examples:
EXAMPLE
Describe each of the following sets both in words and by
listing out enough elements to see the pattern.
1. { x : x + 3 ∈ N}.
2. { x ∈ N : x + 3 ∈ N}.
3. { x : x ∈ N ∨ −x ∈ N}.
4. { x : x ∈ N ∧ −x ∈ N}.
SOLUTION
© The Independent Institute of Education (Pty) Ltd 2021 Page 241 of 332
IIE Module Manual MAPC5112
We already have a lot of notation, and there is more yet. Below is a handy chart of
symbols. Some of these will be discussed in greater detail as we move forward.
We have already said what it means for two sets to be equal: they have exactly the same
elements. Thus, for example,
© The Independent Institute of Education (Pty) Ltd 2021 Page 242 of 332
IIE Module Manual MAPC5112
(Remember, the order the elements are written down in does not matter.) Also,
since these are all ways to write the set containing the first three positive integers
(how we write them doesn’t matter, just what they are).
What about the sets A = {1, 2, 3} and B = {1, 2, 3, 4}? Clearly A t:: B, but notice that
every element of A is also an element of B. Because of this we say that A is a subset
of B, or in symbols A ⊂ B or A ⊆ B. Both symbols are read “is a subset of.” The
difference is that sometimes we want to say that A is either equal to or is a subset of
B, in which case we use ⊆. This is analogous to the difference between < and ≤.
EXAMPLE
2. B ⊂ A.
3. B ∈ C.
4. ∅ ∈ A.
5. ∅ ⊂ A.
6. A < D.
7. 3 ∈ C.
8. 3 ⊂ C.
9. {3} ⊂ C.
SOLUTION
1. False. For example, 1 ∈ A but 1 rf B.
4. False. A has exactly 6 elements, and none of them are the empty set.
© The Independent Institute of Education (Pty) Ltd 2021 Page 243 of 332
IIE Module Manual MAPC5112
9. True. 3 is the only element of the set {3}, and is an element of C, so every
element in {3} is an element of C.
In the example above, B is a subset of A. You might wonder what other sets are
subsets of A. If you collect all these subsets of A into a new set, we get a set of sets.
We call the set of all subsets of A the power set of A, and write it P (A).
EXAMPLE
SOLUTION
P(A) is a set of sets, all of which are subsets of A. So
P(A) = {∅, {1}, {2}, {3}, {1, 2}, {1, 3}, {2, 3}, {1, 2, 3}}.
Another way to compare sets is by their size. Notice that in the example above, A has
6 elements and B, C, and D all have 3 elements. The size of a set is called the set’s
cardinality.
We would write |A| = 6, |B| = 3, and so on. For sets that have a finite number of
elements, the cardinality of the set is simply the number of elements in the set. Note
that the cardinality of {1, 2, 3, 2, 1} is 3. We do not count repeats (in fact, {1, 2, 3, 2, 1}
is exactly the same set as {1, 2, 3}).
There are sets with infinite cardinality, such as N, the set of rational numbers (written
Q), the set of even natural numbers, and the set of real numbers (R).
© The Independent Institute of Education (Pty) Ltd 2021 Page 244 of 332
IIE Module Manual MAPC5112
EXAMPLE
SOLUTION
1. Since 38 − 23 = 15, we can conclude that the cardinality of the set is |A| = 16
(you need to add one since 23 is included).
2. Here |B| = 3. The three elements are the number 1, the set {2, 3, 4}, and the empty
set.
3. We wrote out the elements of the power set P(C) above, and there are 8
elements (each of which is a set). So |P(C)| = 8. (You might wonder if
there is a relationship between |A| and |P(A)| for all sets A.
Operations on Sets
Is it possible to add two sets? Not really, however there is something similar. If we want
to combine two sets to get the collection of objects that are in either set, then we can
take the union of the two sets. Symbolically,
C = A ∪ B,
read, “C is the union of A and B,” means that the elements of C are exactly the
elements which are either an element of A or an element of B (or an element of both).
For example, if A = {1, 2, 3} and B = {2, 3, 4}, then A ∪ B = {1, 2, 3, 4}.
and say, “C is the intersection of A and B,” when the elements in C are precisely those
both in A and in B.
Often when dealing with sets, we will have some understanding as to what
“everything” is. Perhaps we are only concerned with natural numbers. In this case we
would say that our universe is N. Sometimes we denote this universe by U. Given
this context, we might wish to speak of all the elements which are not in a particular
set. We say B is the complement of A, and write,
© The Independent Institute of Education (Pty) Ltd 2021 Page 245 of 332
IIE Module Manual MAPC5112
when B contains every element not contained in A. So, if our universe is {1, 2, . . . , 9, 10},
and A = {2, 3, 5, 7}, then
Of course, we can perform more than one operation at a time. For example, consider
This is the set of all elements which are both elements of A and not elements of B. What
have we done? We’ve started with A and removed all of the elements which were in B.
Another way to write this is the set difference:
EXAMPLE
Let A = {1, 2, 3, 4, 5, 6}, B = {2, 4, 6}, C = {1, 2, 3} and D = {7, 8, 9}. If the
universe is U = {1, 2, . . . , 10}, find:
SOLUTION
1. A ∪ B = {1, 2, 3, 4, 5, 6} = A since everything in B is already in A.
© The Independent Institute of Education (Pty) Ltd 2021 Page 246 of 332
IIE Module Manual MAPC5112
You might notice that the symbols for union and intersection slightly resemble the
logic symbols for “or” and “and.” This is no accident.
What does it mean for x to be an element of A ∪ B?
This sounds fancy but is nothing you haven’t seen before. When you graph a function
in calculus, you graph it in the Cartesian plane. This is the set of all ordered pairs of
real numbers (x, y). We can do this for any pair of sets, not just the real numbers with
themselves.
The first coordinate comes from the first set and the second coordinate comes from
the second set. Sometimes we will want to take the Cartesian product of a set with
itself, and this is fine:
A × A = {(a, b) : a, b ∈ A}
(we might also write A2 for this set). Notice that in A × A, we still want all ordered
pairs, not just the ones where the first and second coordinate are the same. We can
© The Independent Institute of Education (Pty) Ltd 2021 Page 247 of 332
IIE Module Manual MAPC5112
also take products of 3 or more sets, getting ordered triples, or quadruples, and so
on.
Venn Diagrams
There is a very nice visual tool we can use to represent operations on sets.
A Venn diagram displays sets as intersecting circles. We can shade the region we are
talking about when we carry out an operation. We can also represent cardinality of a
particular set by putting the number in the corresponding region.
Each circle represents a set. The rectangle containing the circles represents the
universe. To represent combinations of these sets, we shade the corresponding
region.
© The Independent Institute of Education (Pty) Ltd 2021 Page 248 of 332
IIE Module Manual MAPC5112
3 Sequences
© The Independent Institute of Education (Pty) Ltd 2021 Page 249 of 332
IIE Module Manual MAPC5112
(a n )n∈N
or
(a n )n≥0 ,
or sometimes if we are being sloppy, just (a n ) (in which case we assume we start the
sequence with a0 ).
We might replace the a with another letter, and sometimes we omit a0 , starting with
a1 , in which case we would use (a n )n≥1 to refer to the sequence as a whole.
The numbers in the subscripts are called indices (the plural of index).
While we often just think of sequences as an ordered list of numbers, they really are
a type of function. Specifically, the sequence (a n )n≥0 is a function with domain N where
a n is the image of the natural number n.
EXAMPLE
1. 7, 7, 7, 7, 7, . . .
2. 3, −3, 3, −3, 3, . . .
3. 1, 5, 2, 10, 3, 15, . . .
4. 1, 2, 4, 8, 16, 32, . . .
6. 1, 2, 3, 5, 8, 13, 21, . . .
8. 2, 3, 5, 7, 11, 13, . . .
9. 3, 2, 1, 0, −1, . . .
10. 1, 1, 2, 6, . . .
© The Independent Institute of Education (Pty) Ltd 2021 Page 250 of 332
IIE Module Manual MAPC5112
SOLUTION
No you cannot. You might guess that the next terms are:
1. 7
2. −3
3. 4
4. 64
5. 49
6. 34
7. 28
8. 17
9. -2
10.24
Given that no number of initial terms in a sequence is enough to say for certain
which sequence we are dealing with; we need to find another way to specify a
sequence. We consider two ways to do this:
© The Independent Institute of Education (Pty) Ltd 2021 Page 251 of 332
IIE Module Manual MAPC5112
• a n = 2a n−1 with a 0 = 1.
In these cases, if you are given n, you cannot calculate a n directly, you first need
to find a n−1 (or a n−1 and a n−2 ). In the second sequence, to find a3 you would take 2a2 ,
but to find a2 = 2a1 we would need to know a1 = 2a0 . We do know this, so we could
trace back through these equations to find a1 = 54, a 2 = 108 and finally a3 = 216.
You might wonder why we would bother with recursive definitions for sequences.
After all, it is harder to find a n with a recursive definition than with a closed formula.
This is true, but it is also harder to find a closed formula for a sequence than it is to
find a recursive definition. So to find a useful closed formula, we might first find the
recursive definition, then use that to find the closed formula.
EXAMPLE
SOLUTION
© The Independent Institute of Education (Pty) Ltd 2021 Page 252 of 332
IIE Module Manual MAPC5112
a 5 = 2a 4 − a 3 and a 4 = 2a 3 − a 2 ,
a 3 = 2a 2 − a 1 and a 2 = 2a 1 − a 0 ,
a0 = 3
a1 = 4
a2 = 2 · 4 − 3 = 5
a3 = 2 · 5 − 4 = 6
a4 = 2 · 6 − 5 = 7
a5 = 2 · 7 − 6 = 8
a6 = 2 · 8 − 7 = 9.
Note that now we can guess a closed formula for the nth
term of the sequence: a n = n + 3. To be sure this will
always work, we could plug in this formula into the
recurrence relation:
Finding closed formulas, or even recursive definitions, for sequences is not trivial.
There is no one method for doing this. Just like in evaluating integrals or solving
differential equations, it is useful to have a bag of tricks you can apply, but sometimes
there is no easy answer.
One useful method is to relate a given sequence to another sequence for which we
already know the closed formula.
© The Independent Institute of Education (Pty) Ltd 2021 Page 253 of 332
IIE Module Manual MAPC5112
EXAMPLE
SOLUTION
© The Independent Institute of Education (Pty) Ltd 2021 Page 254 of 332
IIE Module Manual MAPC5112
4 Functions
A function is a rule that assigns each input exactly one output. We call the output
the image of the input. The set of all inputs for a function is called the domain.
The set of all allowable outputs is called the codomain. We would write
f: X →Y
This does not tell us which function f is though. To define the function, we must
describe the rule. This is often done by giving a formula to compute the output for
any input (although this is certainly not the only way to describe the rule).
For example,
Here the domain and codomain are the same set (the natural numbers).
The rule is: take your input, multiply it by itself and add 3.
This works because we can apply this rule to every natural number (every element of
the domain) and the result is always a natural number (an element of the codomain).
Notice though that not every natural number actually is an output (there is no way to get
0, 1, 2, 5, etc.). The set of natural numbers that are actually outputs is called the range
of the function (in this case, the range is {3, 4, 7, 12, 19, 28, . . . }, all the natural numbers
that are 3 more than a perfect square).
The key thing that makes a rule actually a function is that there is exactly one output
for each input. That is, it is important that the rule be a good rule. What output do we
assign to the input 7? There can only be one answer for any particular function.
© The Independent Institute of Education (Pty) Ltd 2021 Page 255 of 332
IIE Module Manual MAPC5112
The description of the rule can vary greatly. We might just give a list of the images
of each input. You could also describe the function with a table or a graph or in words.
The arrow diagram used to define the function above can be very helpful in visualizing
functions. We will often be working with functions with finite domains, so this kind of
picture is often more useful than a traditional graph of a function. A graph of the function
in example 3 above would look like this:
It would be absolutely WRONG to connect the dots or try to fit them to some curve.
There are only three elements in the domain. A curve suggests that the domain
contains an entire interval of real numbers. Remember, we are not in calculus
anymore!
Since we will so often use functions with small domains and codomains, let’s adopt
some notation that is a little easier to work with than that of examples 2 and 3 above.
All we need is some clear way of denoting the image of each element in the domain.
In fact, writing a table of values would work perfectly:
© The Independent Institute of Education (Pty) Ltd 2021 Page 256 of 332
IIE Module Manual MAPC5112
We simplify this further by writing this as a matrix with each input directly over its
output:
Note this is just notation and not the same sort of matrix you would find in a linear
algebra class (it does not make sense to do operations with these matrices, or row
reduce them, for example).
It is important to know how to determine if a rule is or is not a function. Drawing the
arrow diagrams can help.
EXAMPLE
Which of the following diagrams represent a function? Let X = {1,
2, 3, 4} and Y = {a, b, c, d}.
SOLUTION
© The Independent Institute of Education (Pty) Ltd 2021 Page 257 of 332
IIE Module Manual MAPC5112
It might also be helpful to think about how you would write the
two-line notation for h. We would have something like:
We now turn to investigating special properties functions might or might not possess.
Properties
In the examples above, you may have noticed that sometimes there are elements of
the codomain which are not in the range. When this sort of the thing does not happen,
(that is, when everything in the codomain is in the range) we say the function is onto
or that the function maps the domain onto the codomain. This terminology should
make sense: the function puts the domain (entirely) on top of the codomain. The fancy
math term for an onto function is a surjection, and we say that an onto function is a
surjective function.
© The Independent Institute of Education (Pty) Ltd 2021 Page 258 of 332
IIE Module Manual MAPC5112
In pictures:
EXAMPLE
SOLUTION
© The Independent Institute of Education (Pty) Ltd 2021 Page 259 of 332
IIE Module Manual MAPC5112
To be a function, a rule cannot assign a single element of the domain to two or more
different elements of the codomain. However, we have seen that the reverse is
permissible: a function might assign the same element of the codomain to two or more
different elements of the domain. When this does not occur (that is, when each
element of the codomain is the image of at most one element of the domain) then we
say the function is one-to-one. Again, this terminology makes sense: we are sending
at most one element from the domain to one element from the codomain. One input to
one output. The fancy math term for a one-to-one function is an injection. We call
one-to-one functions injective functions.
In pictures:
EXAMPLE
SOLUTION
From the examples above, it should be clear that there are functions which are
surjective, injective, both, or neither. In the case when a function is both one-to-one
and onto (an injection and surjection), we say the function is a bijection, or that the
function is a bijective function.
© The Independent Institute of Education (Pty) Ltd 2021 Page 260 of 332
IIE Module Manual MAPC5112
Inverse image
When discussing functions, we have notation for talking about an element of the
domain (say x) and its corresponding element in the codomain (we write f (x ), which
is the image of x). It would also be nice to start with some element of the codomain
(say y) and talk about which element or elements (if any) from the domain it is the
image of. We could write “those x in the domain such that f (x ) = y,” but this is a lot
of writing. Here is some notation to make our lives easier.
That is, f −1 (y) = {x ∈ X : f (x) = y}. We say that f −1 (y) is the complete inverse
image of y under f.
EXAMPLE
Consider the function f : {1, 2, 3, 4, 5, 6} → { a, b, c, d } given by
SOLUTION
Remember, we are looking for sets.
f −1 (a ) = {1, 2 }
f −1 (b ) = {3 }
f −1 (c ) = {4, 5, 6}
f −1 (d ) = ∅.
EXAMPLE
Consider the function g : Z → Z defined by g(n) = n 2 + 1.
Find g −1 (1), g −1 (2), g −1 (3) and g −1 (10).
SOLUTION
© The Independent Institute of Education (Pty) Ltd 2021 Page 261 of 332
IIE Module Manual MAPC5112
Since f −1 ( y ) is a set, it makes sense to ask for | f −1 ( y )|, the number of elements in the
domain which map to y.
Function Definitions
• A function is a rule that assigns each element of a set, called the domain, to
exactly one element of a second set, called the codomain.
• Notation: f : X → Y is our way of saying that the function is called f , the
domain is the set X, and the codomain is the set Y.
• To specify the rule for a function with small domain, use two-line notation
by writing a matrix with each output directly below its corresponding input,
as in:
• The range is a subset of the codomain. It is the set of all elements which are
assigned to at least one element of the domain by the function. That is, the
range is the set of all outputs.
© The Independent Institute of Education (Pty) Ltd 2021 Page 262 of 332
IIE Module Manual MAPC5112
Bogart, K., Drysdale, S., Stein, C., and Kenneth Bogart, P. (2004). Discrete Math for
Computer Science Students.
6 Activities
Complete the activities on IIELearn.
7 Exercises
Refer to the workbook for exercises.
© The Independent Institute of Education (Pty) Ltd 2021 Page 263 of 332
IIE Module Manual MAPC5112
1 Introduction to Counting
One of the first things you learn in mathematics is how to count. Now we want to count
large collections of things quickly and precisely. For example:
Before tackling questions like these, let’s look at the basics of counting.
© The Independent Institute of Education (Pty) Ltd 2021 Page 264 of 332
IIE Module Manual MAPC5112
It is important that the events be disjoint: i.e., that there is no way for A and B to both
happen at the same time. For example, a standard deck of 52 cards contains 26 red
cards and 12 face cards. However, the number of ways to select a card which is either
red or a face card is not 26 + 12 = 38. This is because there are 6 cards which are both
red and face cards.
EXAMPLE
How many two letter “words” start with either A or B? (A word is just a
strings of letters; it doesn’t have to be English, or even pronounceable.)
SOLUTION
First, how many two letter words start with A? We just need to select the
second letter, which can be accomplished in 26 ways. So there are 26
words starting with A. There are also 26 words that start with B. To select
a word which starts with either A or B, we can pick the word from the first
26 or the second 26, for a total of 52 words.
The additive principle also works with more than two events. Say, in addition to your
14 choices for donuts and 16 for dogs, you would also consider eating one of 15
waffles? How many choices do you have now? You would have 14 + 16 + 15 = 45
options.
EXAMPLE
How many two letter words start with one of the 5 vowels?
SOLUTION
There are 26 two letter words starting with A, another 26
starting with E, and so on. We will have 5 groups of 26. So we
add 26 to itself 5 times. Of course it would be easier to just
multiply 5 · 26. We are really using the additive principle again,
just using multiplication as a shortcut.
© The Independent Institute of Education (Pty) Ltd 2021 Page 265 of 332
IIE Module Manual MAPC5112
EXAMPLE
Suppose you are going for some Milkshake. You can pick one
of 6 milkshake choices, and one of 4 toppings. How many
choices do you have?
SOLUTION
Break your choices up into disjoint events: A are the
choices with the first topping, B the choices featuring the
second topping, and so on. There are four events; each
can occur in 6 ways (one for each yogurt flavor). The
events are disjoint, so the total number of choices is 6 + 6
+ 6 + 6 = 24.
Note that in both of the previous examples, when using the additive principle
on a bunch of events all the same size, it is quicker to multiply. This really is
the same, and not just because 6 + 6 + 6 + 6 = 4 · 6. We can first select the
topping in 4 ways (that is, we first select which of the disjoint events we will
take). For each of those first 4 choices, we now have 6 choices of yogurt. We
have:
EXAMPLE
How many license plates can you make out of three letters
followed by three numerical digits?
SOLUTION
Here we have six events: the first letter, the second letter,
the third letter, the first digit, the second digit, and the third
digit. The first three events can each happen in 26 ways;
the last three can each happen in 10 ways. So the total
number of license plates will be 26·26·26·10·10·10, using
the multiplicative principle.
© The Independent Institute of Education (Pty) Ltd 2021 Page 266 of 332
IIE Module Manual MAPC5112
Careful: “and” doesn’t mean “times.” For example, how many playing cards are both
red and a face card? Not 26 · 12. The answer is 6, and we needed to know something
about cards to answer that question.
Another caution: how many ways can you select two cards, so that the first one is a
red card and the second one is a face card? This looks more like the multiplicative
principle (you are counting two separate events) but the answer is not 26 · 12 here
either. The problem is that while there are 26 ways for the first card to be selected, it
is not the case that for each of those there are 12 ways to select the second card. If the
first card was both red and a face card, then there would be only 11 choices for the
second card. 1
© The Independent Institute of Education (Pty) Ltd 2021 Page 267 of 332
IIE Module Manual MAPC5112
EXAMPLE
How many functions f : {1, 2, 3, 4, 5} → {a, b, c, d} are there?
SOLUTION
Remember that a function sends each element of the
domain to exactly one element of the codomain. To
determine a function, we just need to specify the image of
each element in the domain. Where can we send 1? There
are 4 choices. Where can we send 2? Again, 4 choices.
What we have here is 5 “events” (picking the image of an
element in the domain) each of which can happen in 4
ways (the choices for that image).
To make things clearer, and more mathematically rigorous, we will use sets. Do not
skip this section! It might seem like we are just trying to give a proof of these
principles, but we are doing a lot more. If we understand the additive and
multiplicative principles rigorously, we will be better at applying them, and knowing
when and when not to apply them at all.
We will look at the additive and multiplicative principles in a slightly different way.
Instead of thinking about event A and event B, we want to think of a set A and a set
B. The sets will contain all the different ways the event can happen. (It will be helpful
to be able to switch back and forth between these two models when checking that we
have counted correctly.) Here’s what we mean:
© The Independent Institute of Education (Pty) Ltd 2021 Page 268 of 332
IIE Module Manual MAPC5112
EXAMPLE
Suppose you own 9 shirts and 5 pairs of pants.
1. How many outfits can you make?
2. If today is half-naked-day, and you will wear only a
shirt or only a pair of pants, how many choices do you
have?
SOLUTION
By now you should agree that the answer to the first question
is 9·5 = 45 and the answer to the second question is
9 + 5 = 14. These are the multiplicative and additive
principles. There are two events: picking a shirt and picking a
pair of pants. The first event can happen in 9 ways and the
second event can happen in 5 ways. To get both a shirt and
a pair of pants, you multiply. To get just one article of clothing,
you add.
Now look at this using sets. There are two sets, call them S
and P. The set S contains all 9 shirts so |S| = 9 while |P| = 5,
since there are 5 elements in the set P (namely your 5 pairs
of pants). What are we asking in terms of these sets? Well in
question 2, we really want |S ∪P|, the number of elements in
the union of shirts and pants. This is just |S| + |P| (since there
is no overlap; |S ∩ P| = 0).
From this example we can see right away how to rephrase our additive principle in
terms of sets:
This hardly needs a proof. To find A ∪ B, you take everything in A and throw
in everything in B. Since there is no element in both sets already, you will have
© The Independent Institute of Education (Pty) Ltd 2021 Page 269 of 332
IIE Module Manual MAPC5112
| A | things and add | B | new things to it. This is what adding does! Of course,
we can easily extend this to any number of disjoint sets.
From the example above, we see that in order to investigate the
multiplicative principle carefully, we need to consider ordered pairs. We should
define this carefully:
EXAMPLE
Let A = {1, 2} and B = {3, 4, 5}. Find A × B.
SOLUTION
We want to find ordered pairs (a, b ) where a can be either 1
or 2 and b can be either 3, 4, or 5. A × B is the set of all of
these pairs:
The question is, what is |A × B|? To figure this out, write out A × B. Let A = {a1 , a2 ,
a3 , . . . , a m } and B = {b1 , b2 , b 3 , . . . , b n } (so |A| = m and |B| = n). The set A × B
contains all pairs with the first half of the pair being some a i ∈ A and the second being
one of the b j ∈ B. In other words:
Notice what we have done here: we made m rows of n pairs, for a total of m · n pairs.
Each row above is really { a i } × B for some a i ∈ A. That is, we fixed the A-element.
Broken up this way,
we have
A × B = ({ a 1 } × B ) ∪ ({ a 2 } × B ) ∪ ({ a 3 } × B ) ∪ · · · ∪ ({ a m } × B ).
© The Independent Institute of Education (Pty) Ltd 2021 Page 270 of 332
IIE Module Manual MAPC5112
So A × B is really the union of m disjoint sets. Each of those sets has n elements in
them. The total (using the additive principle) is n + n + n + · · · + n = m · n.
4 Principle of Inclusion/Exclusion
While we are thinking about sets, consider what happens to the additive principle
when the sets are NOT disjoint. Suppose we want to find | A ∪ B | and know that | A | =
10 and | B | = 8. This is not enough information though. We do not know how many of
the 8 elements in B are also elements of A. However, if we also know that | A ∩ B | =
6, then we can say exactly how many elements are in A, and, of those, how many are
in B and how many are not (6 of the 10 elements are in B, so 4 are in A but not in B).
We could fill in a Venn diagram as follows:
This will always work, but drawing a Venn diagram is more than we need to do. In
fact, it would be nice to relate this problem to the case where A and B are disjoint. Is
there one rule we can make that works in either case?
Here is another way to get the answer to the problem above. Start by just adding |A| +
|B|. This is 10 + 8 = 18, which would be the answer if |A ∩ B| = 0. We see that we are
off by exactly 6, which just so happens to be |A ∩ B|. So perhaps we guess,
|A ∪ B| = |A| + |B| − |A ∩ B| .
This works for this one example. Will it always work? Think about what we are doing
here. We want to know how many things are either in A or B (or both). We can throw
in everything in A, and everything in B.
This would give | A | + | B | many elements. But of course when you actually take the
© The Independent Institute of Education (Pty) Ltd 2021 Page 271 of 332
IIE Module Manual MAPC5112
union, you do not repeat elements that are in both. So far we have counted every
element in A ∩ B exactly twice: once when we put in the elements from A and once
when we included the elements from B. We correct by subtracting out the number of
elements we have counted twice. So we added them in twice, subtracted once,
leaving them counted only one time.
EXAMPLE
An examination in three subjects, Algebra, Biology,
and Chemistry, was taken by 41 students. The
following table shows how many students failed in
each single subject and in their various
combinations:
SOLUTION
The answer is not 37, even though the sum of the
numbers above is 37. For example, while 12 students
failed Algebra, 2 of those students also failed Biology, 6
also failed Chemestry, and 1 of those failed all three
subjects. In fact, that 1 student who failed all three
subjects is counted a total of 7 times in the total 37. To
clarify things, let us think of the students who failed
Algebra as the elements of the set A, and similarly for sets
B and C. The one student who failed all three subjects is
the lone element of the set A ∩ B ∩ C. Thus, in Venn
diagrams:
© The Independent Institute of Education (Pty) Ltd 2021 Page 272 of 332
IIE Module Manual MAPC5112
© The Independent Institute of Education (Pty) Ltd 2021 Page 273 of 332
IIE Module Manual MAPC5112
Could we have solved the problem above in an algebraic way? While the additive
principle generalizes to any number of sets, when we add a third set here, we must be
careful. With two sets, we needed to know the cardinalities of A, B, and A ∩ B in order
to find the cardinality of A ∪ B. With three sets we need more information. There are
more ways the sets can combine. Not surprisingly then, the formula for cardinality of
the union of three non-disjoint sets is more complicated:
To determine how many elements are in at least one of A, B, or C we add up all the
elements in each of those sets. However, when we do that, any element in both A and
B is counted twice. Also, each element in both A and C is counted twice, as are
elements in B and C, so we take each of those out of our sum once. But now what about
the elements which are in A ∩ B ∩ C (in all three sets)? We added them in three times,
but also removed them three times. They have not yet been counted. Thus we add
those elements back in at the end.
Returning to our example above, we have |A| = 12, |B| = 5, |C| = 8. We also have |A ∩ B|
= 2, |A ∩ C| = 6, |B ∩ C| = 3, and |A ∩ B ∩ C| = 1. Therefore:
| A ∪ B ∪ C | = 12 + 5 + 8 − 2 − 6 − 3 + 1 = 15
This is what we got when we solved the problem using Venn diagrams.
This process of adding in, then taking out, then adding back in, and so on is
called the Principle of Inclusion/Exclusion, or simply PIE. We will return to this
counting technique later to solve for more complicated problems (involving more
than 3 sets).
5 Counting Functions
We have seen throughout this chapter that many counting questions can be rephrased as
questions about counting functions with certain properties. This is reasonable since
many counting questions can be thought of as counting the number of ways to assign
elements from one set to elements of another.
© The Independent Institute of Education (Pty) Ltd 2021 Page 274 of 332
IIE Module Manual MAPC5112
EXAMPLE
You decide to give away your video game collection so to
better spend your time studying advance mathematics.
How many ways can you do this? Provided:
one friend can get more than one game. This gives P (5, 3)
= 60 functions, which is the answer to our counting
question.
© The Independent Institute of Education (Pty) Ltd 2021 Page 275 of 332
IIE Module Manual MAPC5112
EXAMPLE
How many functions f
: {1, 2, 3, 4, 5} → { a, b }
are surjective?
SOLUTION
There are 2 functions all together, two choices for where to
5
EXAMPLE
How many functions f :
{1, 2, 3, 4, 5} → { a, b, c }
are surjective?
SOLUTION
Again start with the total number of functions: 35 (as
each of the five elements of the domain can go to any of
three elements of the codomain). Now we count the
functions which are not surjective.
© The Independent Institute of Education (Pty) Ltd 2021 Page 276 of 332
IIE Module Manual MAPC5112
25 + 25 + 25 − 1 − 1 − 1 + 0.
© The Independent Institute of Education (Pty) Ltd 2021 Page 277 of 332
IIE Module Manual MAPC5112
each 0 or 1. On a magnetic disk it's stored with magnetism (whether a tiny spot on
the disk is magnetised north or south).
When we write what is stored in a computer on paper, we normally use “0” for
one of the states, and “1” for the other state. For example, a piece of computer
memory could have the following voltages:
low low high low high high high high low high low low
We could allocate “0” to “low”, and “1” to “high” and write this sequence down as:
0 0 1 0 1 1 1 1 0 1 0 0
While this notation is used extensively, and you may often hear the data being
referred to as being “0’s and 1’s”, it is important to remember that a computer
does not store 0’s and 1’s; it has no way of doing this. They are just using physical
mechanisms such as high and low voltage, north or south polarity, and light or dark
materials.
+
The use of the two digits 0 and 1 is so common that some of
the best known computer jargon is used for them. Since there
are only two digits, the system is called binary. The short
word for a "binary digit" is made by taking the first two letters
and the last letter --- a bit is just a digit that can have two
values.
Every file you save, every picture you make, every download, every digital recording,
every web page is just a whole lot of bits. These binary digits are what make digital
technology digital! And the nature of these digits unlock a powerful world of storing and
sharing a wealth of information and entertainment.
Computer scientists don't spend a lot of time reading bits themselves, but knowing how
they are stored is really important because it affects the amount of space that data will
use, the amount of time it takes to send the data to a friend (as data that takes more
space takes longer to send!) and the quality of what is being stored. You may have
come across things like "24-bit colour", "128-bit encryption", "32-bit IPv4 addresses"
or "8-bit ASCII". Understanding what the bits are doing enables you to work out how
much space will be required to get high-quality colour, hard-to-crack secret codes, a
unique ID for every device in the world, or text that uses more characters than the
usual English alphabet.
This chapter is about some of the different methods that computers use to code
different kinds of information in patterns of these bits, and how this affects the cost and
quality of what we do on the computer, or even if something is feasible at all.
© The Independent Institute of Education (Pty) Ltd 2021 Page 278 of 332
IIE Module Manual MAPC5112
In this section, we will look at how computers represent numbers. To begin with, we'll
revise how the base-10 number system that we use every day works, and then look at
binary, which is base-2. After that, we'll look at some other characteristics of numbers
that computers must deal with, such as negative numbers and numbers with decimal
points.
The number system that humans normally use is in base 10 (also known as decimal).
It's worth revising quickly, because binary numbers use the same ideas as decimal
numbers, just with fewer digits!
In decimal, the value of each digit in a number depends on its place in the number. For
example, in R123, the 3 represents R3, whereas the 1 represents R100. Each place
value in a number is worth 10 times more than the place value to its right, i.e. there are
the “ones”, the “tens”, the “hundreds”, the “thousands” the “ten thousand”, the “hundred
thousand”, the “millions”, and so on. Also, there are 10
different digits (0,1,2,3,4,5,6,7,8,9) that can be at each of those place values.
If you were only able to use one digit to represent a number, then the largest number
would be 9. After that, you need a second digit, which goes to the left, giving you the
next ten numbers (10, 11, 12... 19). It's because we have 10 digits that each one is
worth 10 times as much as the one to its right.
You may have encountered different ways of expressing numbers using “expanded
form”. For example, if you want to write the number 90328 in expanded form you might
have written it as:
© The Independent Institute of Education (Pty) Ltd 2021 Page 279 of 332
IIE Module Manual MAPC5112
• A place is the place in the number that a digit is, i.e. ones, tens, hundreds,
thousands, and so on. For example, in the number 90328, 3 is in the
"hundreds" place, 2 is in the "tens" place, and 9 is in the "ten thousand" place.
• Numbers are made with a sequence of digits.
• The right-most digit is the one that's worth the least (in the "ones" place).
• The left-most digit is the one that's worth the most.
• Because we have 10 digits, the digit at each place is worth 10 times as much
as the one immediately to the right of it.
All this probably sounds really obvious, but it is worth thinking about consciously,
because binary numbers have the same properties.
Computers can only store information using bits, which only have 2 possible states.
This means that they cannot represent base 10 numbers using digits 0 to 9, the way
we write down numbers in decimal. Instead, they must represent numbers using just 2
digits -- 0 and 1.
Binary works in a very similar way to Decimal, even though it might not initially seem
that way. Because there are only 2 digits, this means that each digit is 2 times the
value of the one immediately to the right.
EXAMPLE
Can you figure out a systematic approach to counting in
binary?
Try counting from 0 to 16, and see if you can detect a pattern.
© The Independent Institute of Education (Pty) Ltd 2021 Page 280 of 332
IIE Module Manual MAPC5112
CHALLENGE
Write representations for the following. If it is not possible to
do the representation, put "Impossible".
SOLUTION
The answers are (spaces are added to make the answers
easier to read, but are not required)
An important concept with binary numbers is the range of values that can be
represented using a given number of bits. When we have 8 bits the binary numbers
© The Independent Institute of Education (Pty) Ltd 2021 Page 281 of 332
IIE Module Manual MAPC5112
start to get useful -- they can represent values from 0 to 255, so it is enough to store
someone's age, the day of the month, and so on.
What is a byte?
In practice, computers store numbers with either 16, 32, or 64 bits. This is because
these are full numbers of bytes (a byte is 8 bits), and makes it easier for computers to
know where each number starts and stops.
Most of the time binary numbers are stored electronically, and we don't need to worry
about making sense of them. But sometimes it's useful to be able to write down and
share numbers, such as the unique identifier assigned to each digital device (MAC
address), or the colours specified in an HTML page.
Writing out long binary numbers is tedious --- for example, suppose you need to copy
down the 16-bit number 0101001110010001. A widely used shortcut is to break the
number up into 4-bit groups (in this case, 0101 0011 1001 0001), and then write down
the digit that each group represents (giving 5391). There's just one small problem:
each group of 4 bits can go up to 1111, which is 15, and the digits only go up to 9.
The solution is simple: we introduce symbols for the digits from 1010 (10) to 1111 (15),
which are just the letters A to F. So, for example, the 16-bit binary number 1011 1000
1110 0001 can be written more concisely as B8E1. The "B" represents the binary 1011,
which is the decimal number 11, and the E represents binary 1110, which is decimal
14.
Because we now have 16 digits, this representation is base 16, and known as
hexadecimal (or hex for short). Converting between binary and hexadecimal is very
simple, and that's why hexadecimal is a very common way of writing down large binary
numbers.
Here is a full table of all the 4-bit numbers and their hexadecimal digit equivalent:
© The Independent Institute of Education (Pty) Ltd 2021 Page 282 of 332
IIE Module Manual MAPC5112
Binary Hex
0000 0
0001 1
0010 2
0011 3
0100 4
0101 5
0110 6
0111 7
1000 8
1001 9
1010 A
1011 B
1100 C
1101 D
1110 E
1111 F
For example, the largest 8-bit binary number is 11111111. This can be written as FF
in hexadecimal. Both of those representations mean 255 in our conventional decimal
system (you can check that by converting the binary number to decimal).
Which notation you use will depend on the situation; binary numbers represent what is
actually stored, but can be confusing to read and write; hexadecimal numbers are a
good shorthand of the binary; and decimal numbers are used if you're trying to
understand the meaning of the number or doing normal math. All three are widely used
in computer science.
Some of the things that we might think of as numbers, such as the telephone number
(03) 555-1234, aren't actually stored as numbers, as they contain important characters
(like dashes and spaces) as well as the leading 0 which would be lost if it was stored
as a number (the above number would come out as 35551234, which isn't quite right).
These are stored as text.
© The Independent Institute of Education (Pty) Ltd 2021 Page 283 of 332
IIE Module Manual MAPC5112
On the other hand, things that don't look like a number (such as "30 January 2014")
are often stored using a value that is converted to a format that is meaningful to the
reader (try typing two dates into Excel, and then subtract one from the other --- the
result is a useful number). In the underlying representation, a number is used. Program
code is used to translate the underlying representation into a meaningful date on the
user interface.
Numbers are used to store things as diverse as dates, student marks, prices, statistics,
scientific readings, sizes, and dimensions of graphics.
Any system that stores numbers needs to make a compromise between the number
of bits allocated to store the number, and the range of values that can be stored.
In some systems (like the Java and C programming languages and databases) it's
possible to specify how accurately numbers should be stored; in others it is fixed in
advance (such as in spreadsheets).
Some are able to work with arbitrarily large numbers by increasing the space used to
store them as necessary (e.g. integers in the Python programming language).
However, it is likely that these are still working with a multiple of 32 bits (e.g. 64 bits,
96 bits, 128 bits, 160 bits, etc.). Once the number is too big to fit in 32 bits, the computer
would reallocate it to have up to 64 bits.
In some programming languages there isn't a check for when a number gets too big
(overflows). For example, if you have an 8-bit number using two's complement, then
01111111 is the largest number (127), and if you add one without checking, it will
change to 10000000, which happens to be the number -128. This can cause serious
problems if not checked for, and is behind a variant of the Y2K problem, called
the “Year 2038 problem”, involving a 32-bit number overflowing for dates on Tuesday,
19 January 2038.
On tiny computers, such as those embedded inside your car, washing machine, or a
tiny sensor that is barely larger than a grain of sand, we might need to specify more
precisely how big a number needs to be. While computers prefer to work with chunks
of 32 bits, we could write a program (as an example for an earthquake sensor) that
knows the first 7 bits are the latitude, the next 7 bits are the longitude, the next 10 bits
are the depth, and the last 8 bits are the amount of force.
© The Independent Institute of Education (Pty) Ltd 2021 Page 284 of 332
IIE Module Manual MAPC5112
Even on standard computers, it is important to think carefully about the number of bits
you will need. For example, if you have a field in your database that could be either
"0", "1", "2", or "3" (perhaps representing the four bases that can occur in a DNA
sequence), and you used a 64-bit number for everyone, that will add up as your
database grows. If you have 10,000,000 items in your database, you will have wasted
62 bits for each one (only 2 bits is needed to represent the 4 numbers in the example),
a total of 620,000,000 bits, which is around 74 MB. If you are doing this a lot in your
database that will really add up -- human DNA has about 3 billion base pairs in it, so it
is incredibly wasteful to use more than 2 bits for each one.
And for applications such as Google Maps, which are storing an astronomical amount
of data, wasting space is not an option at all!
EXAMPLES
It is really useful to know roughly how many bits you will need
to represent a certain value. Think about the following
scenarios, and choose the best number of bits out of the
options given.
You want to ensure that the largest possible number will fit
within the number of bits, but you also want to ensure that you
are not wasting space.
© The Independent Institute of Education (Pty) Ltd 2021 Page 285 of 332
IIE Module Manual MAPC5112
SOLUTION
1. b (actually, 3 bits is enough as it gives 8 values, but
amounts that fit evenly into 8-bit bytes are easier to work
with)
2. c (32 bits is slightly too small, so you will need 64 bits)
3. c (This is a challenging question, but one a database
designer would have to think about. There's about 94,000
km of roads in NZ, so if the average length of a road was
1km, there would be too many roads for 16 bits. Either
way, 32 bits would be a safe bet.)
4. d (Even 64 bits is not enough, but 128 bits is plenty!
Remember that 128 bits isn't twice the range of 64 bits.)
We will look at two possible approaches: Adding a simple sign bit, much like we do for
decimal, and then a more useful system called Two's Complement.
On a computer we don’t have minus signs for numbers (it doesn't work very well to use
the text based one when representing a number because you can't do arithmetic on
characters), but we can do it by allocating one extra bit, called a sign bit, to represent
the minus sign. Just like with decimal numbers, we put the negative indicator on the
left of the number --- when the sign bit is set to “0”, that means the number is positive
and when the sign bit is set to “1”, the number is negative (just as if there were a minus
sign in front of it).
For example, if we wanted to represent the number 41 using 7 bits along with an
additional bit that is the sign bit (to give a total of 8 bits), we would represent it
by 00101001. The first bit is a 0, meaning the number is positive, then the remaining 7
bits give 41, meaning the number is +41. If we wanted to make -59, this would
be 10111011. The first bit is a 1, meaning the number is negative, and then the
remaining 7 bits represent 59, meaning the number is -59.
EXAMPLE
Using 8 bits as described above (one for the sign, and 7 for
the actual number), what would be the binary representations
for 1, -1, -8, 34, -37, -88, and 102?
© The Independent Institute of Education (Pty) Ltd 2021 Page 286 of 332
IIE Module Manual MAPC5112
SOLUTION
The spaces are not necessary, but are added to make reading
the binary numbers easier
• 1 is 0000 0001
• -1 is 1000 0001
• -8 is 1000 1000
• 34 is 0010 0010
• -37 is 1010 0101
• -88 is 1101 1000
• 102 is 0110 0110
Going the other way is just as easy. If we have the binary number 10010111, we know
it is negative because the first digit is a 1. The number part is the next 7 bits 0010111,
which is 23. This means the number is -23.
EXAMPLE
Converting binary with sign bit to decimal:
But what about 10000000? That converts to -0. And 00000000 is +0. Since -0 and +0
are both just 0, it is very strange to have two different representations for the same
number.
This is one of the reasons that we don't use a simple sign bit in practice. Instead,
computers usually use a more sophisticated representation for negative binary
numbers called Two's Complement.
Two’s compliment
© The Independent Institute of Education (Pty) Ltd 2021 Page 287 of 332
IIE Module Manual MAPC5112
Representing positive numbers is the same as the method you have already learnt.
Using 8 bits, the leftmost bit is a zero and the other 7 bits are the usual binary
representation of the number; for example, 1 would be 00000001, and 65 would
be 00110010.
This is where things get more interesting. In order to convert a negative number to its
two's complement representation, use the following process.
1. Convert the number to binary (don't use a sign bit, and pretend it is a positive
number).
2. Invert all the digits (i.e. change 0's to 1's and 1's to 0's).
3. Add 1 to the result (Adding 1 is easy in binary; you could do it by converting to
decimal first, but think carefully about what happens when a binary number is
incremented by 1 by trying a few; there are more hints in the panel below).
EXAMPLE
Determining the Two's Complement:
© The Independent Institute of Education (Pty) Ltd 2021 Page 288 of 332
IIE Module Manual MAPC5112
2. -19
3. 107
4. -107
5. -92
SOLUTION
1. 19 in binary is 0001 0011, which is the two's complement
for a positive number.
2. For -19, we take the binary of the positive, which is 0001
0011 (above), invert it to 1110 1100, and add 1, giving a
representation of 1110 1101.
3. 107 in binary is 0110 1011, which is the two's complement
for a positive number.
4. For -107, we take the binary of the positive, which is 0110
1011 (above), invert it to 1001 0100, and add 1, giving a
representation of 1001 0101.
5. For -92, we take the binary of the positive, which is 0101
1100, invert it to 1010 0011, and add 1, giving a
representation of 1010 0100. (If you have this incorrect,
double check that you incremented by 1 correctly).
In order to reverse the process, we need to know whether the number we are looking
at is positive or negative. For positive numbers, we can simply convert the binary
number back to decimal. But for negative numbers, we first need to convert it back to
a normal binary number.
So how do we know if the number is positive or negative? It turns out (for reasons you
will understand later in this section) that Two's Complement numbers that are negative
always start in a 1, and positive numbers always start in a 0. Have a look back at the
previous examples to double check this.
So, if the number starts with a 1, use the following process to convert the number back
to a negative decimal number.
© The Independent Institute of Education (Pty) Ltd 2021 Page 289 of 332
IIE Module Manual MAPC5112
EXAMPLE
Reversing Two's Complement:
SOLUTION
1. 12
2. 10001100 -> (-1) 10001011 -> (inverted) 01110100 -> (to
decimal) 116 -> (negative sign added) -116
3. 10111111 -> (-1) 10111110 -> (inverted) 01000001 -> (to
decimal) 65 -> (negative sign added) -65
While it might initially seem that there is no bit allocated as the sign bit, the left-most
bit behaves like one. With 8 bits, you can still only make 256 possible patterns of 0's
and 1's. If you attempted to use 8 bits to represent positive numbers up to 255, and
negative numbers down to -255, you would quickly realise that some numbers were
mapped onto the same pattern of bits. Obviously, this will make it impossible to know
what number is actually being represented!
© The Independent Institute of Education (Pty) Ltd 2021 Page 290 of 332
IIE Module Manual MAPC5112
Before adding negative binary numbers, we'll look at adding positive numbers. It's
basically the same as the addition methods used on decimal numbers, except the rules
are way simpler because there are only two different digits that you might add!
You've probably learnt about column addition. For example, the following column
addition would be used to do 128 + 255.
When you go to add 5 + 8, the result is higher than 9, so you put the 3 in the one's
column, and carry the 1 to the 10's column. Binary addition works in exactly the same
way.
With negative numbers using sign bits like we did before, this does not work. If you
wanted to add +11 (01011) and -7 (10111), you would expect to get an answer of +4
(00100).
Which is -2.
One way we could solve the problem is to use column subtraction instead. But this
would require giving the computer a hardware circuit which could do this. Luckily this
is unnecessary, because addition with negative numbers works automatically using
Two's Complement!
For the above addition (+11 + -7), we can start by converting the numbers to their 5-
bit Two's Complement form. Because 01011 (+11) is a positive number, it does not
need to be changed. But for the negative number, 00111 (-7) (sign bit from before
removed as we don't use it for Two's Complement), we need to invert the digits and
then add 1, giving 11001.
© The Independent Institute of Education (Pty) Ltd 2021 Page 291 of 332
IIE Module Manual MAPC5112
Any extra bits to the left (beyond what we are using, in this case 5 bits) have been
truncated. This leaves 00100, which is 4, like we were expecting.
We can also use this for subtraction. If we are subtracting a positive number from a
positive number, we would need to convert the number we are subtracting to a negative
number. Then we should add the two numbers. This is the same as for decimal
numbers, for example 5 - 2 = 3 is the same as 5 + (-2) = 3.
This property of Two's Complement is very useful. It means that positive numbers and
negative numbers can be handled by the same computer circuit, and addition and
subtraction can be treated as the same operation.
If you wanted to add two positive binary numbers, such as 00001111 and 11001110,
you would follow a similar process to the column addition. You only need to know 0+0,
0+1, 1+0, and 1+1, and 1+1+1. The first three are just what you might expect. Adding
1+1 causes a carry digit, since in binary 1+1 = 10, which translates to "0, carry 1" when
doing column addition. The last one, 1+1+1 adds up to 11 in binary, which we can
express as "1, carry 1". For our two example numbers, the addition works like this:
Remember that the digits can be only 1 or 0. So you will need to carry a 1 to the
next column if the total you get for a column is (decimal) 2 or 3.
© The Independent Institute of Education (Pty) Ltd 2021 Page 292 of 332
IIE Module Manual MAPC5112
Subtracting 2 from 6 is the same as adding the complement, and ignoring the extra 1 digit
on the left. The complement of 2 is 8, so we add 8 to 6, giving (1)4.
For larger numbers (such as subtracting the two 3-digit numbers 255 - 128), the
complement is the number that adds up to the next power of 10 i.e. 1000-128 = 872. Check
that adding 872 to 255 produces (almost) the same result as subtracting 128.
Working out complements in binary is way easier because there are only two digits to work
with, but working them out in decimal may help you to understand what is going on.
7 Text
There are several different ways in which computers use bits to store text. In this
section, we will look at some common ones and then look at the pros and cons of each
representation.
ASCII
We saw earlier that 64 unique patterns can be made using 6 dots in Braille. A dot
corresponds to a bit, because both dots and bits have 2 different possible values.
If you counted correctly, you should find that there were more than 64 characters, and
you might have found up to around 95. Because 6 bits can only represent 64
characters, we will need more than 6 bits; it turns out that we need at least 7 bits to
represent all of these characters as this gives 128 possible patterns. This is exactly
what the ASCII representation for text does.
The name "ASCII" stands for "American Standard Code for Information Interchange",
which was a particular way of assigning bit patterns to the characters on a keyboard.
The ASCII system even includes "characters" for ringing a bell (useful for getting
attention on old telegraph systems), deleting the previous character (kind of an early
"undo"), and "end of transmission" (to let the receiver know that the message was
finished). These days those characters are rarely used, but the codes for them still
exist (they are the missing patterns in the table above). Nowadays ASCII has been
supplanted by a code called "UTF-8", which happens to be the same as ASCII if the
© The Independent Institute of Education (Pty) Ltd 2021 Page 293 of 332
IIE Module Manual MAPC5112
extra left-hand bit is a 0, but opens up a huge range of characters if the left-hand bit is
a 1.
Each pattern in ASCII is usually stored in 8 bits, with one wasted bit, rather than 7 bits.
However, the left-most bit in each 8-bit pattern is a 0, meaning there are still only 128
possible patterns. Where possible, we prefer to deal with full bytes (8 bits) on a
computer, this is why ASCII has an extra wasted bit.
Here is a table that shows the patterns of bits that ASCII uses for each of the
characters.
© The Independent Institute of Education (Pty) Ltd 2021 Page 294 of 332
IIE Module Manual MAPC5112
For example, the letter c (lower-case) in the table has the pattern “01100011” (the 0 at
the front is just extra padding to make it up to 8 bits). The letter o has the pattern
“01101111”. You could write a word out using this code, and if you give it to someone
else, they should be able to decode it exactly.
Computers can represent pieces of text with sequences of these patterns, much like
Braille does. For example, the word “computers” (all lower-case) would be 01100011
01101111 01101101 01110000 01110101 01110100 01100101 01110010 01110011.
This is because "c" is "01100011", "o" is "01101111", and so on. Have a look at the
ASCII table above to check that we are right!
EXAMPLE
Have a go at the following ASCII exercises:
SOLUTION
These are the answers.
• "science" = 01110011 01100011 01101001 01100101
01101110 01100011 01100101
• "Wellington" = 01010111 01100101 01101100
01101100 01101001 01101110 01100111 01110100
01101111 01101110
• "358" = 00110011 00110101 00111000
Note that the text "358" is treated as 3 characters in ASCII, which may be confusing,
as the text "358" is different to the number 358! You may have encountered this
distinction in a spreadsheet e.g. if a cell starts with an inverted comma in Excel, it is
© The Independent Institute of Education (Pty) Ltd 2021 Page 295 of 332
IIE Module Manual MAPC5112
treated as text rather than a number. One place this comes up is with phone numbers;
if you type 027555555 into a spreadsheet as a number, it will come up as 27555555,
but as text the 0 can be displayed. In fact, phone numbers aren't really just numbers
because a leading zero can be important, as they can contain other characters -- for
example, +64 3 555 1234 extn. 1234.
ASCII was first used commercially in 1963, and despite the big changes in computers
since then, it is still the basis of how English text is stored on computers. ASCII
assigned a different pattern of bits to each of the characters, along with a few other
“control” characters, such as delete or backspace.
English text can easily be represented using ASCII, but what about languages such as
Chinese where there are thousands of different characters? Unsurprisingly, the 128
patterns aren’t nearly enough to represent such languages. Because of this, ASCII is
not so useful in practice, and is no longer used widely. In the next sections, we will look
at Unicode and its representations. These solve the problem of being unable to
represent non-English characters.
Unicode
In practice, we need to be able to represent more than just English characters. To solve
this problem, we use a standard called Unicode. Unicode is a character set with
around 120,000 different characters, in many different languages, current and historic.
Each character has a unique number assigned to it, making it easy to identify.
The following interactive will allow you to explore the Unicode character set. Enter a
number in the box on the left to see what Unicode character corresponds to it, or enter
a character on the right to see what its Unicode number is (you could paste one in from
a foreign language web page to see what happens with non-English characters).
The most widely used Unicode encoding schemes are called UTF-8, UTF-16, and
UTF-32; you may have seen these names in email headers or describing a text file.
Some of the Unicode encoding schemes are fixed length, and some are variable
length. Fixed length means that each character is represented using the same number
of bits. Variable length means that some characters are represented with fewer bits
than others. It's better to be variable length, as this will ensure that the most commonly
used characters are represented with fewer bits than the uncommonly used
characters. Of course, what might be the most commonly used character in English is
not necessarily the most commonly used character in Japanese. You may be
wondering why we need so many encoding schemes for Unicode. It turns out that
some are better for English language text, and some are better for Asian language
text.
© The Independent Institute of Education (Pty) Ltd 2021 Page 296 of 332
IIE Module Manual MAPC5112
The remainder of the text representation section will look at some of these Unicode
encoding schemes so that you understand how to use them, and why some of them
are better than others in certain situations.
UTF-32
UTF-32 is a fixed length Unicode encoding scheme. The representation for each
character is simply its number converted to a 32-bit binary number. Leading zeroes
are used if there are not enough bits (just like how you can represent 254 as a 4-digit
decimal number -- 0254). 32 bits is a nice round number on a computer, often referred
to as a word (which is a bit confusing, since we can use UTF-32 characters to represent
English words!)
The following interactive will allow you to convert a Unicode character to its UTF-32
representation. The Unicode character's number is also displayed. The bits are simply
the binary number form of the character number.
Each ASCII character has a number between 0 and 255, and the representation for
the character the number converted to an 8 bit binary number. ASCII is also a fixed
length encoding scheme -- every character in ASCII is represented using 8 bits.
In practice, UTF-32 is rarely used -- you can see that it's pretty wasteful of space. UTF-
8 and UTF-16 are both variable length encoding schemes, and very widely used. We
will look at them next.
EXAMPLE
How big is 32 bits?
© The Independent Institute of Education (Pty) Ltd 2021 Page 297 of 332
IIE Module Manual MAPC5112
UTF-8
UTF-8 is a variable length encoding scheme for Unicode. Characters with a lower
Unicode number require fewer bits for their representation than those with a higher
Unicode number. UTF-8 representations contain either 8, 16, 24, or 32 bits.
Remembering that a byte is 8 bits, these are 1, 2, 3, and 4 bytes.
01001000
11000111 10111111
The following interactive will allow you to convert a Unicode character to its UTF-8
representation. The Unicode character's number is also displayed.
So how does UTF-8 actually work? Use the following process to do what the interactive
is doing and convert characters to UTF-8 yourself.
© The Independent Institute of Education (Pty) Ltd 2021 Page 298 of 332
IIE Module Manual MAPC5112
4. Replace the x's in the pattern with the bits of the binary number you converted
in 2. If there are more x's than bits, replace extra left-most x's with 0's.
For example, if you wanted to find out the representation for 貓 (cat in Chinese), the
steps you would take would be as follows.
UTF-16
Just like UTF-8, UTF-16 is a variable length encoding scheme for Unicode. Because it
is far more complex than UTF-8, we won't explain how it works here.
However, the following interactive will allow you to represent text with UTF-16. Try
putting some text that is in English and some text that is in Japanese into it. Compare
the representations to what you get with UTF-8.
The following table summarises what we have said so far about each representation.
© The Independent Institute of Education (Pty) Ltd 2021 Page 299 of 332
IIE Module Manual MAPC5112
In order to compare and evaluate them, we need to decide what it means for a
representation to be "good". Two useful criteria are:
We know that UTF-8, UTF-16, and UTF-32 can represent all characters, but ASCII can
only represent English. Therefore, ASCII fails the first criterion. But for the second
criteria, it isn't so simple.
The following interactive will allow you to find out the length of pieces of text using
UTF-8, UTF-16, or UTF-32. Find some samples of English text and Asian text (forums
or a translation site are a good place to look), and see how long your various samples
are when encoded with each of the three representations. Copy paste or type text into
the box.
As a general rule, UTF-8 is better for English text, and UTF-16 is better for Asian text.
UTF-32 always requires 32 bits for each character, so is unpopular in practice.
In school or art class you may have mixed different colours of paint or dye together in
order to make new colours. In painting it's common to use red, yellow and blue as three
"primary" colours that can be mixed to produce lots more colours. Mixing red and blue
give purple, red and yellow give orange, and so on. By mixing red, yellow, and blue,
you can make many new colours.
For printing, printers commonly use three slightly different primary colours: cyan,
magenta, and yellow (CMY). All the colours on a printed document were made by
mixing these primary colours.
Both these kinds of mixing are called "subtractive mixing", because they start with a
white canvas or paper, and "subtract" colour from it. The interactive below allows you
to experiment with CMY in case you are not familiar with it, or if you just like mixing
colours.
Computer screens and related devices rely on mixing three colours, except they need
a different set of primary colours because they are additive, starting with a black screen
and adding colour to it. For additive colour on computers, the colours red, green and
blue (RGB) are used. Each pixel on a screen is typically made up of three tiny "lights";
one red, one green, and one blue. By increasing and decreasing the amount of light
coming out of each of these three, all the different colours can be made. The following
interactive allows you to play around with RGB.
© The Independent Institute of Education (Pty) Ltd 2021 Page 300 of 332
IIE Module Manual MAPC5112
Because a colour is simply made up of amounts of the primary colours -- red, green
and blue -- three numbers can be used to specify how much of each of these primary
colours is needed to make the overall colour.
A commonly used scheme is to use numbers in the range 0 to 255. Those numbers
tell the computer how fully to turn on each of the primary colour "lights" in an individual
pixel. If red was set to 0, that means the red "light" is completely off. If the red "light"
was set to 255, that would mean the "light" was fully on.
With 256 possible values for each of the three primary colours (don't forget to count
0!), that gives 256 x 256 x 256 = 16,777,216 possible colours -- more than the human
eye can detect!
© The Independent Institute of Education (Pty) Ltd 2021 Page 301 of 332
IIE Module Manual MAPC5112
The next thing we need to look at is how bits are used to represent each colour in a
high quality image. Firstly, how many bits do we need? Secondly, how should we
decide the values of each of those bits? This section will work through those problems.
How many bits will we need for each colour in the image?
With 256 different possible values for the amount of each primary colour, this means
8 bits would be needed to represent the number.
28=2×2×2×2×2×2×2×2=256
The smallest number that can be represented using 8 bits is 00000000 -- which is 0.
And the largest number that can be represented using 8 bits is 11111111 -- which is
255.
Because there are three primary colours, each of which will need 8 bits to represent
each of its 256 different possible values, we need 24 bits in total to represent a colour.
3×8=24
So, how many colours are there in total with 24 bits? We know that there is 256
possible values each colour can take, so the easiest way of calculating it is:
256×256×256=16,777,216
Because 24 bits are required, this representation is called 24 bit colour. 24 bit colour
is sometimes referred to in settings as "True Color" (because it is more accurate than
the human eye can see). On Apple systems, it is called "Millions of colours".
A logical way is to use 3 binary numbers that represent the amount of each of red,
green, and blue in the pixel. In order to do this, convert the amount of each primary
colour needed to an 8 bit binary number, and then put the 3 binary numbers side by
side to give 24 bits.
Because consistency is important in order for a computer to make sense of the bit
pattern, we normally adopt the convention that the binary number for red should be put
first, followed by green, and then finally blue. The only reason we put red first is
because that is the convention that most systems assume is being used. If everybody
had agreed that green should be first, then it would have been green first.
Start by converting each of the three numbers into binary, using 8 bits for each.
© The Independent Institute of Education (Pty) Ltd 2021 Page 302 of 332
IIE Module Manual MAPC5112
• red = 10010001,
• green = 00110010,
• blue = 01111011.
There are no spaces between the three numbers, as this is a pattern of bits rather than
actually being three binary numbers, and computers don’t have any such concept of a
space between bit patterns anyway --- everything must be a 0 or a 1. You could write
it with spaces to make it easier to read, and to represent the idea that they are likely to
be stored in 3 8-bit bytes, but inside the computer memory there is just a sequence of
high and low voltages, so even writing 0 and 1 is an arbitrary notation.
Also, all leading and trailing 0’s on each part are kept --- without them, it would be
representing a shorter number. If there were 256 different possible values for each
primary colour, then the final representation must be 24 bits long.
The computer won’t ever convert the number into decimal, as it works with the binary
directly --- most of the process that takes the bits and makes the right pixels appear is
typically done by a graphics card or a printer. We just started with decimal, because it
is easier for humans to understand. The main point about knowing this representation
is to understand the trade-off that is being made between the accuracy of colour (which
should ideally be beyond human perception) and the amount of storage (bits) needed
(which should be as little as possible).
What if we were to use fewer than 24 bits to represent each colour? How much space
will be saved, compared to the impact on the image?
An image represented using 24 bit colour would have 24 bits per pixel. In 600 x 800
pixel image (which is a reasonable size for a photo), this would
contain 600×800=480,0000 pixels, and thus would use 480,000×24bits=11,520,000. This
works out to around 1.44 megabytes. If we use 8-bit colour instead, it will use a third
of the memory, so it would save nearly a megabyte of storage. Or if the image is
downloaded then a megabyte of bandwidth will be saved.
8 bit colour is not used much anymore, although it can still be helpful in situations such
as accessing a computer desktop remotely on a slow internet connection, as the image
of the desktop can instead be sent using 8 bit colour instead of 24 bit colour. Even
though this may cause the desktop to appear a bit strange, it doesn’t stop you from
getting whatever it was you needed to get done, done. Seeing your desktop in 24 bit
colour would not be very helpful if you couldn't get your work done!
© The Independent Institute of Education (Pty) Ltd 2021 Page 303 of 332
IIE Module Manual MAPC5112
In some countries, mobile internet data is very expensive. Every megabyte that is
saved will be a cost saving. There are also some situations where colour doesn’t matter
at all, for example diagrams, and black and white printed images.
If space really is an issue, then this crude method of reducing the range of colours isn't
usually used; instead, compression methods such as JPEG, GIF and PNG are used.
These make much more clever compromises to reduce the space that an image takes,
without making it look so bad, including choosing a better palette of colours to use
rather than just using the simple representation discussed above. However,
compression methods require a lot more processing, and images need to be decoded
to the representations discussed in this chapter before they can be displayed.
The ideas in this present chapter more commonly come up when designing systems
(such as graphics interfaces) and working with high-quality images (such as RAW
photographs), and typically the goal is to choose the best representation possible
without wasting too much space.
RESOURCES
• Understanding TCP/IP addressing and subnetting basics:
https://support.microsoft.com/en-
za/help/164015/understanding-tcp-ip-addressing-and-
subnetting-basics [Date Accessed: 01 May 2017].
• Panchotraining, 2007. Cisco Training CCNA IP
Addressing - Part 1 of 5. [Video online]. Available at:
http://www.youtube.com/watch?v=UXN5XrmsaV8 [Date
Accessed: 01 May 2017]
• Panchotraining, 2007. Cisco Training CCNA IP
Addressing - Part 2 of 5. [Video online]. Available at:
http://www.youtube.com/watch?v=H7YHjssOdUg [Date
Accessed: 01 May 2017]
• Panchotraining, 2007. Cisco Training CCNA IP
Addressing - Part 3 of 5. [Video online]. Available at:
http://www.youtube.com/watch?v=DWRBJkyIpkM [Date
Accessed: 01 May 2017]
• Panchotraining, 2007. Cisco Training CCNA IP
Addressing - Part 4 of 5. [Video online]. Available at:
http://www.youtube.com/watch?v=_Jc9GQjkiMk [Date
Accessed: 01 May 2017]
• Panchotraining, 2007. Cisco Training CCNA IP
Addressing - Part 5 of 5. [Video online]. Available at:
http://www.youtube.com/watch?v=0i5O19j_kuQ [Date
Accessed: 01 May 2017]
• Panchotraining, 2008. Cisco Training CCNA IP
Addressing - Part 6. [Video online] Available at:
© The Independent Institute of Education (Pty) Ltd 2021 Page 304 of 332
IIE Module Manual MAPC5112
http://www.youtube.com/watch?v=HgLZYcCfE4g [Date
Accessed: 01 May 2017]
• Panchotraining, 2008. Cisco Training CCNA IP
Addressing - Part 7. [Video online]. Available at:
http://www.youtube.com/watch?v=GT6tTZd648M [Date
Accessed: 01 May 2017]
• Panchotraining, 2008. Cisco Training CCNA IP
Addressing - Part 8. [Video online]. Available at:
http://www.youtube.com/watch?v=6IzX1yYBtWs [Date
Accessed: 01 May 2017]
• Panchotraining, 2008. Cisco Training CCNA IP
Addressing - Part 9. [Video online]. Available at:
http://www.youtube.com/watch?v=2cz7_vQvXyM [Date
Accessed: 01 May 2017]
Bogart, K., Drysdale, S., Stein, C., and Kenneth Bogart, P. (2004). Discrete Math for
Computer Science Students.
10 Activities
Complete the activities on IIELearn.
11 Exercises
Refer to the workbook for exercises.
© The Independent Institute of Education (Pty) Ltd 2021 Page 305 of 332
IIE Module Manual MAPC5112
For example, if I told you that a particular real-valued function was continuous on the
interval [0, 1], and f (0) = −1 and f (1) = 5, can we conclude that there is some point
between [0, 1] where the graph of the function crosses the x-axis? Yes, we can, thanks
to the Intermediate Value Theorem from Calculus.
Can we conclude that there is exactly one point? No. Whenever we find an “answer”
in math, we really have a (perhaps hidden) argument. Mathematics is really about
proving general statements (like the Intermediate Value Theorem), and this too is
done via an argument, usually called a proof. We start with some given conditions,
the premises of our argument, and from these we find a consequence of interest, our
conclusion.
© The Independent Institute of Education (Pty) Ltd 2021 Page 306 of 332
IIE Module Manual MAPC5112
The problem is, as you no doubt know from arguing with friends, not all arguments are
good arguments. A “bad” argument is one in which the conclusion does not follow
from the premises, i.e., the conclusion is not a consequence of the premises. Logic
is the study of what makes an argument good or bad. In other words, logic aims to
determine in which cases a conclusion is, or is not, a consequence of a set of premises.
By the way, “argument” is actually a technical term in math (and philosophy, another
discipline which studies logic):
Arguments
An argument is a set of statements, one of which is called the conclusion and the
rest of which are called premises. An argument is said to be valid if the conclusion
must be true whenever the premises are all true. An argument is invalid if it is not
valid; it is possible for all the premises to be true and the conclusion to be false.
Are these arguments valid? Hopefully, you agree that the first one is but the second
one is not. Logic tells us why by analysing the structure of the statements in the
argument. Notice the two arguments above look almost identical. Edith and Florence
both eat their vegetables. In both cases there is a connection between the eating of
vegetables and cookies. But we claim that it is valid to conclude that Edith gets a cookie,
but not that Florence does. The difference must be in the connection between eating
vegetables and getting cookies. We need to be skilled at reading and comprehending
these sentences. Do the two sentences mean the same thing? Unfortunately, in
everyday language we are often sloppy, and you might be tempted to say they are
equivalent. But notice that just because Florence must eat her vegetables, we have
not said that doing so would be enough (she might also need to clean her room, for
example). In everyday (non-mathematical) practice, you might be tempted to say this
“other direction” is implied. In mathematics, we never get that luxury.
© The Independent Institute of Education (Pty) Ltd 2021 Page 307 of 332
IIE Module Manual MAPC5112
The goal now is to see what mathematical tools we can develop to better analyse
these, and then to see how this helps read and write proofs.
Propositional Logic
Truth Tables
If you get more doubles than any other player then you will lose, or if you lose then
you must have bought the most properties.
True or false?
We will answer this question, and won’t need to know anything about Monopoly.
Instead we will look at the logical form of the statement.
Enter truth tables. The idea is this: on each row, we list a possible combination of
T’s and F’s (for true and false) for each of the sentential variables, and then mark
down whether the statement in question is true or false in that case. We do this for
every possible combination of T’s and F’s. Then we can clearly see in which cases
the statement is true or false. For complicated statements, we will first fill in values for
each part of the statement, as a way of breaking up our task into smaller, more
manageable pieces.
Since the truth value of a statement is completely determined by the truth values of
its parts and how they are connected, all you really need to know is the truth tables for
each of the logical connectives. Here they are:
© The Independent Institute of Education (Pty) Ltd 2021 Page 308 of 332
IIE Module Manual MAPC5112
EXAMPLE
Make a truth table for the statement ¬P ∨ Q.
SOLUTION
Note that this statement is not ¬(P ∨ Q ), the
negation belongs to P alone. Here is the truth table:
P Q ¬P ¬P ∨ Q
T T F T
T F F F
F T T T
F F T T
EXAMPLE
Analyse the statement, “if you get more doubles than
any other player you will lose, or that if you lose you
must have bought the most properties,” using truth
tables.
SOLUTION
Represent the statement in symbols as (P → Q ) ∨ (Q →
R), where P is the statement “you get more doubles
than any other player,” Q is the statement “you will
lose,” and R is the statement “you must have bought
the most properties.” Now make a truth table.
© The Independent Institute of Education (Pty) Ltd 2021 Page 309 of 332
IIE Module Manual MAPC5112
P Q R P→Q Q→R (P → Q ) ∨ (Q → R )
T T T T T T
T T F T F T
T F T F T T
T F F F T T
F T T T T T
F T F T F T
F F T T T T
F F F T T T
Logical Equivalence
You might have noticed that the final column in the truth table from ¬P ∨ Q is identical
to the final column in the truth table for P → Q:
P Q P→Q ¬P ∨ Q
T T T T
T F F F
F T T T
F F T T
This says that no matter what P and Q are, the statements ¬P ∨ Q and P → Q either
both true or both false. We therefore say these statements are logically equivalent.
© The Independent Institute of Education (Pty) Ltd 2021 Page 310 of 332
IIE Module Manual MAPC5112
To verify that two statements are logically equivalent, you can make a truth table for each
and check whether the columns for the two statements are identical.
EXAMPLE
Are the statements, “it will not rain or snow” and “it
will not rain and it will not snow” logically equivalent?
SOLUTION
We want to know whether ¬(P ∨ Q ) is logically equivalent to
¬P ∧ ¬Q. Make a truth table which includes both statements:
P Q ¬(P ∨ Q ) ¬P ∧ ¬Q
T T F F
T F F F
F T F F
F F T T
Notice that this example gives us a way to “distribute” a negation over a disjunction (an
“or”). We have a similar rule for distributing over conjunctions (“and”s):
De Morgan’s Laws
¬(P ∧ Q ) is logically equivalent to ¬P ∨ ¬Q.
¬ (P ∨ Q ) is logically equivalent to ¬P ∧ ¬Q.
This suggests there might be a sort of “algebra” you could apply to statements (okay,
there is: it is called Boolean algebra) to transform one statement into another. We can
start collecting useful examples of logical equivalence, and apply them in succession
to a statement, instead of writing out a complicated truth table. We will probably also
want a way to deal with double negation:
© The Independent Institute of Education (Pty) Ltd 2021 Page 311 of 332
IIE Module Manual MAPC5112
Double Negation
Example:
“It is not the case that c is not odd” means “c is odd.”
Let’s see how we can apply the equivalences we have encountered so far.
EXAMPLE
Prove that the statements ¬(P → Q ) and P ∧ ¬Q are
logically equivalent without using truth tables.
SOLUTION
We want to start with one of the statements, and transform
it into the other through a sequence of logically equivalent
statements. Start with ¬(P → Q ). We can rewrite the
implication as a disjunction this is logically equivalent to
¬(¬P ∨ Q ).
¬¬P ∧ ¬Q.
Notice that the above example illustrates that the negation of an implication is NOT
an implication: it is a conjunction!
To verify that two statements are logically equivalent, you can use truth tables or a
sequence of logically equivalent replacements. The truth table method, although
cumbersome, has the advantage that it can verify that two statements are NOT
logically equivalent.
EXAMPLE
Are the statements (P ∨ Q) → R and
(P → R) ∨ (Q → R) logically
equivalent?
SOLUTION
Note that while we could start rewriting these statements
with logically equivalent replacements in the hopes of
© The Independent Institute of Education (Pty) Ltd 2021 Page 312 of 332
IIE Module Manual MAPC5112
P Q R (P ∨ Q ) → R (P → R ) ∨ (Q → R )
T T T T T
T T F F F
T F T T T
T F F F T
F T T T T
F T F F T
F F T T T
F F F T T
Deductions
If Edith eats her vegetables, then she can have a cookie. Edith ate her vegetables.
Therefore, Edith gets a cookie.
How do we know this is valid? Let’s look at the form of the statements. Let P denote
“Edith eats her vegetables” and Q denote “Edith can have a cookie.” The logical form
of the argument is then:
P→Q
P
∴ Q
This is an example of a deduction rule, an argument form which is always valid. This
one is a particularly famous rule called modus ponens. Are you convinced that it is a
valid deduction rule? If not, consider the following truth table:
© The Independent Institute of Education (Pty) Ltd 2021 Page 313 of 332
IIE Module Manual MAPC5112
P Q P→Q
T T T
T F F
F T T
F F T
This is just the truth table for P → Q, but what matters here is that all the lines in
the deduction rule have their own column in the truth table. Remember that an
argument is valid provided the conclusion must be true given that the premises are
true. The premises in this case are P → Q and P. Which rows of the truth table
correspond to both of these being true? P is true in the first two rows, and of those,
only the first row has P → Q true as well. And low-and-behold, in this one case, Q is
also true. So if P → Q and P are both true, we see that Q must be true as well.
EXAMPLE
Show that
P→Q
¬P →Q
∴ Q
SOLUTION
We make a truth table which contains all the lines of the
argument form:
P Q P→Q ¬P ¬P → Q
T T T F T
T F F F T
F T T T T
F F T T F
© The Independent Institute of Education (Pty) Ltd 2021 Page 314 of 332
IIE Module Manual MAPC5112
EXAMPLE
Decide whether
P→R
Q→R
R
∴ P∨Q
SOLUTION
Let’s make a truth table containing all four statements.
P→R
Q→R
P ∨Q
∴ R
2 Proofs
Anyone who doesn’t believe there is creativity in mathematics clearly has not tried
to write proofs. Finding a way to convince the world that a particular statement is
necessarily true is a mighty undertaking and can often be quite challenging. There is
not a guaranteed path to success in the search for proofs. For example, in the summer
of 1742, a German mathematician by the name of Christian Goldbach wondered
whether every even integer greater than 2 could be written as the sum of two primes.
Centuries later, we still don’t have a proof of this apparent fact (computers have
© The Independent Institute of Education (Pty) Ltd 2021 Page 315 of 332
IIE Module Manual MAPC5112
checked that “Goldbach’s Conjecture” holds for all numbers less than 4 × 1018 , which
leaves only infinitely many more numbers to check).
Writing proofs is a bit of an art. Like any art, to be truly great at it, you need some sort
of inspiration, as well as some foundational technique. Just as musicians can learn
proper fingering, and painters can learn the proper way to hold a brush, we can look
at the proper way to construct arguments. A good place to start might be to study a
classic
Proof. Suppose this were not the case. That is, suppose there are only finitely many
primes. Then there must be a last, largest prime, call it p. Consider the number
N = p! + 1 = ( p · (p − 1) · · · · 3 · 2 · 1) + 1.
Now N is certainly larger than p. Also, N is not divisible by any number less than or
equal to p, since every number less than or equal to p divides p!. Thus the prime
factorization of N contains prime numbers (possibly just N itself) all greater than p. So
p is not the largest prime, a contradiction. Therefore, there are infinitely many primes.
3. Let N = p! + 1.
[basically just notation, although this is the inspired part of the proof; looking at p! + 1 is the key
insight.]
4. N is larger than p.
[by the definition of p!]
8. This is a contradiction.
[from line 2 and line 7: the largest prime is p and there is a prime larger than p.]
© The Independent Institute of Education (Pty) Ltd 2021 Page 316 of 332
IIE Module Manual MAPC5112
We should say a bit more about the last line. Up through line 8, we have a valid
argument with the premise “there are only finitely many primes” and the conclusion
“there is a prime larger than the largest prime.” This is a valid argument as each line
follows from previous lines. So if the premises are true, then the conclusion must be
true. However, the conclusion is NOT true. The only way out: the premise must be
false.
The sort of line-by-line analysis we did above is a great way to really understand
what is going on. Whenever you come across a proof in a textbook, you really should
make sure you understand what each line is saying and why it is true. Additionally,
it is equally important to understand the overall structure of the proof. This is where
using tools from logic is helpful. Luckily there are a relatively small number of
standard proof styles that keep showing up again and again. Being familiar with these
can help understand proof, as well as give ideas of how to write your own.
Direct Proof
The simplest (from a logic perspective) style of proof is a direct proof. Often all that
is required to prove something is a systematic explanation of what everything means.
Direct proofs are especially useful when proving implications. The general format to
prove P → Q is this:
EXAMPLE
Prove: For all integers n, if n is even, then n 2 is even.
SOLUTION
Explain, explain, explain. Therefore, n 2 is even.
© The Independent Institute of Education (Pty) Ltd 2021 Page 317 of 332
IIE Module Manual MAPC5112
EXAMPLE
Prove: For all integers a, b, and c, if a|b and b|c then
a|c.
SOLUTION
Even before we know what the divides symbol means,
we can set up a direct proof for this statement. It will go
something like this: Let a, b, and c be arbitrary integers.
Assume that a | b and b | c. Dot dot dot. Therefore a | c.
Proof by Contrapositive
directly. This is all that proof by contrapositive does. It gives a direct proof of the
contrapositive of the implication. This is enough because the contrapositive is
logically equivalent to the original implication.
© The Independent Institute of Education (Pty) Ltd 2021 Page 318 of 332
IIE Module Manual MAPC5112
The skeleton of the proof of P → Q by contrapositive will always look roughly like this:
As before, if there are variables and quantifiers, we set them to be arbitrary elements
of our domain. Here are a couple examples:
EXAMPLE
Is the statement “for all
integers n, if n 2 is even,
then n is even” true?
SOLUTION
This is the converse of the statement we proved above
using a direct proof. From trying a few examples, this
statement definitely appears this is true. So let’s prove it.
© The Independent Institute of Education (Pty) Ltd 2021 Page 319 of 332
IIE Module Manual MAPC5112
EXAMPLE
Prove: for all integers a and
b, if a + b is odd, then a is
odd or b is odd.
SOLUTION
The problem with trying a direct proof is that it will be hard to
separate a and b from knowing something about a + b. On
the other hand, if we know something about a and b separately,
then combining them might give us information about a + b.
The contrapositive of the statement we are trying to prove is:
for all integers a and b, if a and b are even, then a + b is even.
Thus our proof will have the following format:
We have seen how to prove some statements in the form of implications: either directly
or by contrapos- itive. Some statements are not written as implications to begin with.
EXAMPLE
Consider the statement, for every prime number p,
either p = 2 or p is odd. We can rephrase this: for
every prime number p, if p t:: 2, then p is odd. Now
try to prove it.
SOLUTION
Let p be an arbitrary prime number. Assume p is not odd. So
p is divisible by 2. Since p is prime, it must have exactly two
divisors, and it has 2 as a divisor, so p must be divisible by
only 1 and 2. Therefore p = 2. This completes the proof (by
contrapositive).
© The Independent Institute of Education (Pty) Ltd 2021 Page 320 of 332
IIE Module Manual MAPC5112
Proof by Contradiction
EXAMPLE
Prove: There are
no integers x and
y such that x 2 = 4y
+ 2.
SOLUTION
Proof. We proceed by contradiction. So suppose there are
integers x and y such that x 2 = 4y + 2 = 2(2y + 1). So x 2 is
even. We have seen that this implies that x is even. So
x = 2k for some integer k. Then x 2 = 4k 2 . This in turn
gives 2k 2 = (2y + 1). But 2k 2 is even, and 2y + 1 is odd,
so these cannot be equal. Thus we have a contradiction,
so there must not be any integers x and y such that x 2 =
4y + 2.
EXAMPLE
The Pigeonhole Principle: If more than n pigeons fly into
n pigeon holes, then at least one pigeon hole will contain
at least two pigeons. Prove this!
SOLUTION
Proof. Suppose, contrary to stipulation, that each of the
pigeon holes contain at most one pigeon. Then at most, there
will be n pigeons. But we assumed that there are more than n
pigeons, so this is impossible. Thus there must be a
pigeonhole with more than one pigeon.
© The Independent Institute of Education (Pty) Ltd 2021 Page 321 of 332
IIE Module Manual MAPC5112
It is almost NEVER okay to prove a statement with just an example. Certainly, none of
the statements proved above can be proved through an example. This is because in
each of those cases we are trying to prove that something holds of all integers. We claim
that n 2 being even implies that n is even, no matter what integer n we pick. Showing that
this works for n = 4 is not even close to enough.
This cannot be stressed enough. If you are trying to prove a statement of the form
∀xP (x ), you absolutely
CANNOT prove this with an example.1
However, existential statements can be proven this way. If we want to prove that
there is an integer n such that n 2 − n + 41 is not prime, all we need to do is find one.
This might seem like a silly thing to want to prove until you try a few values for n.
So far we have gotten only primes. You might be tempted to conjecture, “For all
positive integers n, the number n 2 − n + 41 is prime.” If you wanted to prove this, you
would need to use a direct proof, a proof by contrapositive, or another style of proof,
but certainly it is not enough to give even 7 examples. In fact, we can prove this
conjecture is false by proving its negation: “There is a positive integer n such that n 2
− n + 41 is not prime.” Since this is an existential statement, it suffices to show that
there does indeed exist such a number.
In fact, we can quickly see that n = 41 will give 412 which is certainly not prime. You
might say that this is a counterexample to the conjecture that n 2 − n + 41 is always
prime. Since so many statements in mathematics are universal, making their
negations existential, we can often prove that a statement is false (if it is) by providing
a counterexample.
EXAMPLE
Above we proved, “for all integers a and b, if a + b is
odd, then a is odd or b is odd.” Is the converse true?
SOLUTION
The converse is the statement, “for all integers a and b, if
a is odd or b is odd, then a + b is odd.” This is false! How
do we prove it is false? We need to prove the negation of
the converse. Let’s look at the symbols. The converse is
© The Independent Institute of Education (Pty) Ltd 2021 Page 322 of 332
IIE Module Manual MAPC5112
Proof by Cases
We could go on and on and on about different proof styles (we haven’t even
mentioned induction or combinatorial proofs here), but instead we will end with one
final useful technique: proof by cases. The idea is to prove that P is true by proving
that Q → P and ¬Q → P for some statement Q. So no matter what, whether or not Q
is true, we know that P is true. In fact, we could generalize this. Suppose we want
to prove P. We know that at least one of the statements Q1 , Q2 , . . . , Q n are true. If we
can show that Q1 → P and Q2 → P and so on all the way to Q n → P, then we can
conclude P. The key thing is that we want to be sure that one of our cases (the Q i ’s)
must be true no matter what.
If that last paragraph was confusing, hopefully an example will make things better.
EXAMPLE
For any
integer n, the
number (n 3 −
n) is even.
SOLUTION
It is hard to know where to start this, because we don’t
know much of anything about n. We might be able to
© The Independent Institute of Education (Pty) Ltd 2021 Page 323 of 332
IIE Module Manual MAPC5112
n 3 − n = 8k 3 − 2k
= 2(4k 2 − k),
and since 4k 2 − k
is an integer, this
says that
n3 − n
is even.
Case 2:
n is odd. Then n = 2k + 1 for some integer k. This gives
and since
4k 3 + 3k 2 + 2k
is even again.
© The Independent Institute of Education (Pty) Ltd 2021 Page 324 of 332
IIE Module Manual MAPC5112
mathematical statements have a particular logical form, and analysing that form can
help make sense of the statement.
At the most basic level, a statement might combine simpler statements using logical
connectives. We often make use of variables, and quantify over those variables. How
to resolve the truth or falsity of a statement based on these connectives and quantifiers
is what logic is all about. From this, we can decide whether two statements are logically
equivalent or if one or more statements (logically) imply another.
When writing proofs (in any area of mathematics) our goal is to explain why a
mathematical statement is true. Thus, it is vital that our argument implies the truth of
the statement. To be sure of this, we first must know what it means for the statement
to be true, as well as ensure that the statements that make up the proof correctly
imply the conclusion. A firm understanding of logic is required to check whether a
proof is correct.
There is, however, another reason that understanding logic can be helpful.
Understanding the logical structure of a statement often gives clues as how to write a
proof of the statement.
This is not to say that writing proofs is always straight forward. Consider again the
Goldbach conjecture: Every even number greater than 2 can be written as the sum of
two primes.
We are not going to try to prove the statement here, but we can at least say what a proof
might look like, based on the logical form of the statement. Perhaps we should write
the statement in an equivalent way which better highlights the quantifiers and
connectives:
For all integers n, if n is even and greater than 2, then there exists integers p and q
such that p and q are prime and n = p + q.
What would a direct proof look like? Since the statement starts with a universal
quantifier, we would start by, “Let n be an arbitrary integer." The rest of the statement
is an implication. In a direct proof we assume the “if” part, so the next line would be,
“Assume n is greater than 2 and is even.” I have no idea what comes next, but
eventually, we would need to find two prime numbers p and q (depending on n) and
explain how we know that
n = p + q.
There is an integer n such that n is even and greater than 2, but for all integers p and
q, either p or q is not prime or n t:: p + q.
© The Independent Institute of Education (Pty) Ltd 2021 Page 325 of 332
IIE Module Manual MAPC5112
A proof by contradiction would start by assuming it was and eventually conclude with
a contradiction, proving that our assumption of truth was incorrect. And if you can find
such a contradiction, you will have proved the most famous open problem in
mathematics.
Bogart, K., Drysdale, S., Stein, C., and Kenneth Bogart, P. (2004). Discrete Math for
Computer Science Students.
4 Activities
Complete the activities on IIELearn.
5 Exercises
Refer to the workbook for exercises.
© The Independent Institute of Education (Pty) Ltd 2021 Page 326 of 332
IIE Module Manual MAPC5112
Bibliography
Bogart, K., Drysdale, S., Stein, C., and Kenneth Bogart, P. 2004. Discrete Math for
Computer Science Students.
Grossman, P. 2009. Discrete mathematics for computing. (3rd ed) New York (NY):
Palgrave Macmillian.
MITE, and Lippman, D. Arithmetic for College Student. [Online]. Available at:
http://www.opentextbookstore.com/details.php?id=13 [Accessed 30 May 2017].
© The Independent Institute of Education (Pty) Ltd 2021 Page 327 of 332
IIE Module Manual MAPC5112
Tom Leighton, and Marten Dijk. 6.042J Mathematics for Computer Science. Fall
2010. Massachusetts Institute of Technology: MIT
OpenCourseWare, https://ocw.mit.edu.
© The Independent Institute of Education (Pty) Ltd 2021 Page 328 of 332
IIE Module Manual MAPC5112
Intellectual Property
Plagiarism occurs in a variety of forms. Ultimately though, it refers to the use of the
words, ideas or images of another person without acknowledging the source using the
required conventions. The IIE publishes a Quick Reference Guide that provides more
detailed guidance, but a brief description of plagiarism and referencing is included
below for your reference. It is vital that you are familiar with this information and the
Intellectual Integrity Policy before attempting any assignments.
What is ‘Plagiarism’?
‘Plagiarism’ is the act of taking someone’s words or ideas and presenting them as your
own.
What is ‘Referencing’?
‘Referencing’ is the act of citing or giving credit to the authors of any work that you
have referred to or consulted. A ‘reference’ then refers to a citation (a credit) or the
actual information from a publication that is referred to.
Referencing is the acknowledgment of any work that is not your own, but is used by
you in an academic document. It is simply a way of giving credit to and acknowledging
the ideas and words of others.
When writing assignments, students are required to acknowledge the work, words or
ideas of others through the technique of referencing. Referencing occurs in the text at
the place where the work of others is being cited, and at the end of the document, in
the bibliography.
The bibliography is a list of all the work (published and unpublished) that a writer has
read in the course of preparing a piece of writing. This includes items that are not
directly cited in the work.
© The Independent Institute of Education (Pty) Ltd 2021 Page 329 of 332
IIE Module Manual MAPC5112
It is standard practice in the academic world to recognise and respect the ownership
of ideas, known as intellectual property, through good referencing techniques.
However, there are other reasons why referencing is useful.
Sources
What You Need to Document from the Hard Copy Source You
are Using
(Not every detail will be applicable in every case. However, the following lists provide
a guide to what information is needed.)
© The Independent Institute of Education (Pty) Ltd 2021 Page 330 of 332
IIE Module Manual MAPC5112
Referencing Systems
There are a number of referencing systems in use and each has its own consistent
rules. While these may differ from system-to-system, the referencing system followed
needs to be used consistently, throughout the text. Different referencing systems
cannot be mixed in the same piece of work!
© The Independent Institute of Education (Pty) Ltd 2021 Page 331 of 332
IIE Module Manual MAPC5112
Usually, all of the above examples would not be referenced. The equation 𝐸 = 𝑚𝑐 2
is Einstein’s famous equation for calculations of total energy and has become so
familiar that it is not referenced to Einstein.
Sometimes what we think is ‘common knowledge’, is not. For example, the above
statement about the sky being blue is only partly true. The light from the sun looks
white, but it is actually made up of all the colours of the rainbow. Sunlight reaches the
Earth's atmosphere and is scattered in all directions by all the gases and particles in
the air. The smallest particles are by coincidence the same length as the wavelength
of blue light. Blue is scattered more than the other colours because it travels as shorter,
smaller waves. It is not entirely accurate then to claim that the sky is blue. It is thus
generally safer to always check your facts and try to find a reputable source for your
claim.
The IIE respects the intellectual property of other people and requires its students to
be familiar with the necessary referencing conventions. Please ensure that you seek
assistance in this regard before submitting work if you are uncertain.
If you fail to acknowledge the work or ideas of others or do so inadequately this will be
handled in terms of the Intellectual Integrity Policy (available in the library) and/ or the
Student Code of Conduct – depending on whether or not plagiarism and/ or cheating
(passing off the work of other people as your own by copying the work of other students
or copying off the Internet or from another source) is suspected.
Your campus offers individual and group training on referencing conventions – please
speak to your librarian or ADC/ Campus Co-Navigator in this regard.
Please ask for assistance prior to submitting work if you are at all unsure.
© The Independent Institute of Education (Pty) Ltd 2021 Page 332 of 332