Precalculus by Richard Wright

Previous Lesson Table of Contents Next Lesson

Are you not my student and
has this helped you?

This book is available
to download as an epub.


And he said: “Truly I tell you, unless you change and become like little children, you will never enter the kingdom of heaven. Therefore, whoever takes the lowly position of this child is the greatest in the kingdom of heaven.” Matthew 18:3-4 NIV

9-06 Applications of Matrices

Mr. Wright teaches the lesson.

Summary: In this section, you will:

SDA NAD Content Standards (2018): PC.7.3

Asymmetric cryptography
Asymmetric cryptography. (wikimedia/Tomasz "odder" Kozlowski)

Cryptographers look for ways to encode messages so that if someone intercepts the message, then they cannot read it. This is important to protect private information on the internet or to send secret messages between government and military offices. One method called the Hill Cipher uses a matrix to encode and decode messages. But first, some applications of determinants.

Cramer's Rule

Cramer's Rule uses determinants to solve a system of linear equations. Cramer's Rule is sometimes preferable to the other methods because Cramer's Rule can solve for one variable without solving for the others. For example, Cramer's Rule will let you find x without finding y or z.

Cramer's Rule

To use Cramer's Rule to solve a system of linear equations

  1. Set up the system of equations in standard form.
  2. Create a matrix of the coefficients of the system. The determinant of this is the denominator of Cramer's Rule.
  3. The numerator is the same as the denominator, but the column of the chosen variable is replaced by the constants. (See the blue columns below.)
  4. Find the determinants and simplify.

For a 2×2 system \(\left\{\begin{align} ax + by &= g \\ cx + dy &= h \end{align}\right.\)

$$ x = \frac{\left|\begin{matrix} \color{blue}{g} & b \\ \color{blue}{h} & d \end{matrix}\right|}{\left|\begin{matrix} a & b \\ c & d \end{matrix}\right|}; \quad y = \frac{\left|\begin{matrix} a & \color{blue}{g} \\ c & \color{blue}{h} \end{matrix}\right|}{\left|\begin{matrix} a & b \\ c & d \end{matrix}\right|} $$

For a 3×3 system \(\left\{\begin{align} ax + by + cz &= \ell \\ dx + ey + fz &= m \\ gx + hy + iz &= n \end{align}\right.\)

$$ x = \frac{\left|\begin{matrix} \color{blue}{\ell} & b & c \\ \color{blue}{m} & e & f \\ \color{blue}{n} & h & i \end{matrix}\right|}{\left|\begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix}\right|}; \quad y = \frac{\left|\begin{matrix} a & \color{blue}{\ell} & c \\ d & \color{blue}{m} & f \\ g & \color{blue}{n} & i \end{matrix}\right|}{\left|\begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix}\right|}; \quad z = \frac{\left|\begin{matrix} a & b & \color{blue}{\ell} \\ d & e & \color{blue}{m} \\ g & h & \color{blue}{n} \end{matrix}\right|}{\left|\begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix}\right|} $$

If the determinant of the coefficients (the denominator) is 0, then there are many solutions or no solution.

Cramer's Rule

Use Cramer's Rule to solve \(\left\{\begin{alignat}{4} x &+& 2y &-& z &=& -1 \\ x &-& && 2z &=& -1 \\ && y &+& z &=& 1 \end{alignat}\right.\)

Solution

Set up Cramer's Rule for one of the variables such as x. The coefficients are the denominator and the numerator is the same except for the chosen variable column is replaced by the constants.

$$ x = \frac{\left|\begin{matrix} \color{blue}{\ell} & b & c \\ \color{blue}{m} & e & f \\ \color{blue}{n} & h & i \end{matrix}\right|}{\left|\begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix}\right|} $$

$$ x = \frac{\left|\begin{matrix} \color{blue}{-1} & 2 & -1 \\ \color{blue}{-1} & 0 & -2 \\ \color{blue}{1} & 1 & 1 \end{matrix}\right|}{\left|\begin{matrix} 1 & 2 & -1 \\ 1 & 0 & -2 \\ 0 & 1 & 1 \end{matrix}\right|} $$

$$ x = \require{cancel} \frac{ \left|\begin{matrix} \color{blue}{\bcancel{\color{black}{-1}}} & \color{indigo}{\bcancel{\color{black}{2}}} & \color{purple}{\bcancel{\color{red}{\cancel{\color{black}{-1}}}}} \\ -1 & \color{blue}{\bcancel{\color{red}{\cancel{\color{black}{0}}}}} & \color{indigo}{\bcancel{\color{orange}{\cancel{\color{black}{-2}}}}} \\ \color{red}{\cancel{\color{black}{1}}} & \color{orange}{\cancel{\color{black}{1}}} & \color{blue}{\bcancel{\color{green}{\cancel{\color{black}{1}}}}} \end{matrix}\right| \begin{matrix} \color{orange}{\cancel{\color{black}{-1}}} & \color{green}{\cancel{\color{black}{2}}} \\ \color{purple}{\bcancel{\color{green}{\cancel{\color{black}{-1}}}}} & 0 \\ \color{indigo}{\bcancel{\color{black}{1}}} & \color{purple}{\bcancel{\color{black}{1}}} \end{matrix} }{ \left|\begin{matrix} \color{blue}{\bcancel{\color{black}{1}}} & \color{indigo}{\bcancel{\color{black}{2}}} & \color{purple}{\bcancel{\color{red}{\cancel{\color{black}{-1}}}}} \\ 1 & \color{blue}{\bcancel{\color{red}{\cancel{\color{black}{0}}}}} & \color{indigo}{\bcancel{\color{orange}{\cancel{\color{black}{-2}}}}} \\ \color{red}{\cancel{\color{black}{0}}} & \color{orange}{\cancel{\color{black}{1}}} & \color{blue}{\bcancel{\color{green}{\cancel{\color{black}{1}}}}} \end{matrix}\right| \begin{matrix} \color{orange}{\cancel{\color{black}{1}}} & \color{green}{\cancel{\color{black}{2}}} \\ \color{purple}{\bcancel{\color{green}{\cancel{\color{black}{1}}}}} & 0 \\ \color{indigo}{\bcancel{\color{black}{0}}} & \color{purple}{\bcancel{\color{black}{1}}} \end{matrix} } $$

$$ x = \frac{ \color{blue}{(-1·0·1)} + \color{indigo}{(2·-2·1)} + \color{purple}{(-1·-1·1)} - \color{red}{(1·0·-1)} - \color{orange}{(1·-2·-1)} - \color{green}{(1·-1·2)} }{ \color{blue}{(1·0·1)} + \color{indigo}{(2·-2·0)} + \color{purple}{(-1·1·1)} - \color{red}{(0·0·-1)} - \color{orange}{(1·-2·1)} - \color{green}{(1·1·2)} } $$

$$ \require{enclose} x = \frac{-3}{-1} = \enclose{box}{3} $$

If you need to solve for more variables, set up the next one, y. In the first part, the denominator was already calculated, so that will be skipped in this step.

$$ y = \frac{\left|\begin{matrix} a & \color{blue}{\ell} & c \\ d & \color{blue}{m} & f \\ g & \color{blue}{n} & i \end{matrix}\right|}{\left|\begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix}\right|} $$

$$ y = \frac{\left|\begin{matrix} 1 & \color{blue}{-1} & -1 \\ 1 & \color{blue}{-1} & -2 \\ 0 & \color{blue}{1} & 1 \end{matrix}\right|}{\left|\begin{matrix} 1 & 2 & -1 \\ 1 & 0 & -2 \\ 0 & 1 & 1 \end{matrix}\right|} $$

$$ y = \require{cancel} \frac{ \left|\begin{matrix} \color{blue}{\bcancel{\color{black}{1}}} & \color{indigo}{\bcancel{\color{black}{-1}}} & \color{purple}{\bcancel{\color{red}{\cancel{\color{black}{-1}}}}} \\ 1 & \color{blue}{\bcancel{\color{red}{\cancel{\color{black}{-1}}}}} & \color{indigo}{\bcancel{\color{orange}{\cancel{\color{black}{-2}}}}} \\ \color{red}{\cancel{\color{black}{0}}} & \color{orange}{\cancel{\color{black}{1}}} & \color{blue}{\bcancel{\color{green}{\cancel{\color{black}{1}}}}} \end{matrix}\right| \begin{matrix} \color{orange}{\cancel{\color{black}{1}}} & \color{green}{\cancel{\color{black}{-1}}} \\ \color{purple}{\bcancel{\color{green}{\cancel{\color{black}{1}}}}} & -1 \\ \color{indigo}{\bcancel{\color{black}{0}}} & \color{purple}{\bcancel{\color{black}{1}}} \end{matrix} }{ -1 (\text{ from calculating } x) } $$

$$ y = \frac{ \color{blue}{(1·-1·1)} + \color{indigo}{(-1·-2·0)} + \color{purple}{(-1·1·1)} - \color{red}{(0·-1·-1)} - \color{orange}{(1·-2·1)} - \color{green}{(1·1·-1)} }{ -1 } $$

$$ \require{enclose} y = \frac{1}{-1} = \enclose{box}{-1} $$

Finally solve for z. In the first part, the denominator was already calculated, so that will be skipped in this step.

$$ z = \frac{\left|\begin{matrix} a & b & \color{blue}{\ell} \\ d & e & \color{blue}{m} \\ g & h & \color{blue}{n} \end{matrix}\right|}{\left|\begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix}\right|} $$

$$ z = \frac{\left|\begin{matrix} 1 & 2 & \color{blue}{-1} \\ 1 & 0 & \color{blue}{-1} \\ 0 & 1 & \color{blue}{1} \end{matrix}\right|}{\left|\begin{matrix} 1 & 2 & -1 \\ 1 & 0 & -2 \\ 0 & 1 & 1 \end{matrix}\right|} $$

$$ z = \require{cancel} \frac{ \left|\begin{matrix} \color{blue}{\bcancel{\color{black}{1}}} & \color{indigo}{\bcancel{\color{black}{2}}} & \color{purple}{\bcancel{\color{red}{\cancel{\color{black}{-1}}}}} \\ 1 & \color{blue}{\bcancel{\color{red}{\cancel{\color{black}{0}}}}} & \color{indigo}{\bcancel{\color{orange}{\cancel{\color{black}{-1}}}}} \\ \color{red}{\cancel{\color{black}{0}}} & \color{orange}{\cancel{\color{black}{1}}} & \color{blue}{\bcancel{\color{green}{\cancel{\color{black}{1}}}}} \end{matrix}\right| \begin{matrix} \color{orange}{\cancel{\color{black}{1}}} & \color{green}{\cancel{\color{black}{2}}} \\ \color{purple}{\bcancel{\color{green}{\cancel{\color{black}{1}}}}} & 0 \\ \color{indigo}{\bcancel{\color{black}{0}}} & \color{purple}{\bcancel{\color{black}{1}}} \end{matrix} }{ -1 \text{ from calculating } x } $$

$$ z = \frac{ \color{blue}{(1·0·1)} + \color{indigo}{(2·-1·0)} + \color{purple}{(-1·1·1)} - \color{red}{(0·0·-1)} - \color{orange}{(1·-1·1)} - \color{green}{(1·1·2)} }{ -1 } $$

$$ \require{enclose} z = \frac{-2}{-1} = \enclose{box}{2} $$

So the solution, (3, −1, 2), is found by simply finding four determinants.

Solve using Cramer's Rule \(\left\{\begin{align} 2x - y &= 8 \\ -3x + 4y &= -17 \end{align}\right.\)

Answer

(3, −2)

Area of a Triangle

The area of a triangle can be found with using \(\frac{1}{2} bh\) if you know the base and height or Heron's formula if you know the lengths of all the sides. But what if only the coordinates of the vertices are known. One way is to use the distance formula to find the side lengths and then Heron's formula, but that would be long. It turns out a simple determinant will give you the area of the triangle.

Area of a Triangle

The area of a triangle with vertices (x1, y1), (x2, y2), (x3, y3)

$$ Area = ±\frac{1}{2} \left|\begin{matrix} x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \\ x_3 & y_3 & 1 \end{matrix}\right| $$

Where the + or − is chosen to make the area positive.

Area of a Triangle

Find the area of the triangle with vertices (2, −3), (4, 2), and (−1, 1).

Solution

Fill in the formula with the vertices. The order of the vertices does not matter.

$$ Area = ±\frac{1}{2} \left|\begin{matrix} x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \\ x_3 & y_3 & 1 \end{matrix}\right| $$

$$ Area = ±\frac{1}{2} \left|\begin{matrix} 2 & -3 & 1 \\ 4 & 2 & 1 \\ -1 & 1 & 1 \end{matrix}\right| $$

$$ \require{cancel} Area = ±\frac{1}{2} \left|\begin{matrix} \color{blue}{\bcancel{\color{black}{2}}} & \color{indigo}{\bcancel{\color{black}{-3}}} & \color{purple}{\bcancel{\color{red}{\cancel{\color{black}{1}}}}} \\ 4 & \color{blue}{\bcancel{\color{red}{\cancel{\color{black}{2}}}}} & \color{indigo}{\bcancel{\color{orange}{\cancel{\color{black}{1}}}}} \\ \color{red}{\cancel{\color{black}{-1}}} & \color{orange}{\cancel{\color{black}{1}}} & \color{blue}{\bcancel{\color{green}{\cancel{\color{black}{1}}}}} \end{matrix}\right| \begin{matrix} \color{orange}{\cancel{\color{black}{2}}} & \color{green}{\cancel{\color{black}{-3}}} \\ \color{purple}{\bcancel{\color{green}{\cancel{\color{black}{4}}}}} & 2 \\ \color{indigo}{\bcancel{\color{black}{-1}}} & \color{purple}{\bcancel{\color{black}{1}}} \end{matrix} $$

$$ Area = ±\frac{1}{2} \left(\color{blue}{(2·2·1)} + \color{indigo}{(-3·1·-1)} + \color{purple}{(1·4·1)} - \color{red}{(-1·2·1)} - \color{orange}{(1·1·2)} - \color{green}{(1·4·-3)}\right) $$

$$ Area = \frac{23}{2} $$

The determinant was 23, and because that was positive we chose the + from the ± to make the area positive. If the determinant was negative, we would have chosen the − to make the area positive.

Find the area of the triangle with vertices (−1, −2), (5, 1), and (2, 6).

Answer

\(\frac{39}{2}\)

Lines in a Plane

Three points in a plane form a triangle unless they are in a straight line. If the three points form a straight line, then the area of the "triangle" formed by the points is 0. Using the area of a triangle determinant, collinearness of points and equations of lines can be found. Because the area of lines is 0, the \(±\frac{1}{2}\) is not needed in the following formulas.

Determine if Three Points are Collinear

Three points are collinear if the area of the triangle formed is 0.

If \(\left|\begin{matrix} x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \\ x_3 & y_3 & 1 \end{matrix}\right| = 0\), then the points are collinear.

Equation of a Line

To find the equation of a line given 2 points (x1, y1) and (x2, y2), substitute the points and simplify

$$ \left|\begin{matrix} x & y & 1 \\ x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \end{matrix}\right| = 0 $$

Find the Equation of a Line

Find the equation of the line passing through (3, 1) and (−2, 4).

Solution

Fill the points into the determinant. x and y stay as variables.

$$ \left|\begin{matrix} x & y & 1 \\ x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \end{matrix}\right| = 0 $$

$$ \left|\begin{matrix} x & y & 1 \\ 3 & 1 & 1 \\ -2 & 4 & 1 \end{matrix}\right| = 0 $$

Calculate the determinant.

$$ \require{cancel} \left|\begin{matrix} \color{blue}{\bcancel{\color{black}{x}}} & \color{indigo}{\bcancel{\color{black}{y}}} & \color{purple}{\bcancel{\color{red}{\cancel{\color{black}{1}}}}} \\ 3 & \color{blue}{\bcancel{\color{red}{\cancel{\color{black}{1}}}}} & \color{indigo}{\bcancel{\color{orange}{\cancel{\color{black}{1}}}}} \\ \color{red}{\cancel{\color{black}{-2}}} & \color{orange}{\cancel{\color{black}{4}}} & \color{blue}{\bcancel{\color{green}{\cancel{\color{black}{1}}}}} \end{matrix}\right| \begin{matrix} \color{orange}{\cancel{\color{black}{x}}} & \color{green}{\cancel{\color{black}{y}}} \\ \color{purple}{\bcancel{\color{green}{\cancel{\color{black}{3}}}}} & 1 \\ \color{indigo}{\bcancel{\color{black}{-2}}} & \color{purple}{\bcancel{\color{black}{4}}} \end{matrix} = 0 $$

(x·1·1) + (y·1·−2) + (1·3·4)(−2·1·1)(4·1·x)(1·3·y) = 0

x + (−2y) + 12(−2)4x3y = 0

Rearrange the terms into an equation of a line.

−3x − 5y + 14 = 0

3x + 5y = 14

Find the equation of the line passing through (−2, −4) and (3, 2).

Answer

6x − 5y = 8

Cryptography: Hill Cipher

There are many reasons to want to send secret messages. One of the most adventurous is spies sending messages back and forth to their handlers. Or another use might be a young man using a code to ask a young lady out to the spring banquet. One method of encoding messages, the Hill Cipher, uses matrix multiplication. Even though the Hill Cipher looks complicated, it is no longer used politically or commercially because it is linear and thus easy to break if a few letters of the message are known.

Hill Cipher: Encoding a Message
  1. Convert the message into numbers such as
    _ = 0 I = 9 R = 18
    A = 1 J = 10 S = 19
    B = 2 K = 11 T = 20
    C = 3 L = 12 U = 21
    D = 4 M = 13 V = 22
    E = 5 N = 14 W = 23
    F = 6 O = 15 X = 24
    G = 7 P = 16 Y = 25
    H = 8 Q = 17 Z = 26
  2. Choose a square encoding matrix.
  3. Group the message numbers into matrices of 1 row and the same number of columns as the encoding matrix.
  4. Multiply the letter matrices with the encoding matrix.
  5. The encoded message is the list of numbers produced.
Decoding a Message

Multiply the numbers of the encoded message with the inverse of the encoding matrix

Hill Cipher Encoding

Encode the message SMILE using the encoding matrix \(\left[\begin{matrix} 3 & 1 \\ 2 & -2 \end{matrix}\right]\).

Solution

Change the letters into numbers.

S M I L E
19 13 9 12 5

Group the numbers into 1×2 matrices because the encoding matrix is 2×2. There are only five numbers so a 0 for space will be added onto the end.

[19 13] [9 12] [5 0]

Multiply each matrix with encoding matrix.

$$ \color{blue}{\left[\begin{matrix} 19 & 13 \end{matrix}\right]} \left[\begin{matrix} 3 & 1 \\ 2 & -2 \end{matrix}\right] = \left[\begin{matrix} 83 & -7 \end{matrix}\right] $$

$$ \color{red}{\left[\begin{matrix} 9 & 12 \end{matrix}\right]} \left[\begin{matrix} 3 & 1 \\ 2 & -2 \end{matrix}\right] = \left[\begin{matrix} 51 & -15 \end{matrix}\right] $$

$$ \color{purple}{\left[\begin{matrix} 5 & 0 \end{matrix}\right]} \left[\begin{matrix} 3 & 1 \\ 2 & -2 \end{matrix}\right] = \left[\begin{matrix} 15 & 10 \end{matrix}\right] $$

The encoded message is 83, −7, 51, −15, 15, 10

Hill Cipher Decoding

Decode the message 27, −15, 64, 0, 51, -31 using the inverse of \(\left[\begin{matrix} 3 & 1 \\ 2 & -2 \end{matrix}\right]\).

Solution

Start by finding the inverse of the encoding matrix to form the decoding matrix.

$$ \left[\begin{matrix} 3 & 1 \\ 2 & -2 \end{matrix}\right]^{-1} = \frac{1}{3(-2) - 2(1)} \left[\begin{matrix} -2 & -1 \\ -2 & 3 \end{matrix}\right] $$

$$ = \left[\begin{matrix} \frac{1}{4} & \frac{1}{8} \\ \frac{1}{4} & -\frac{3}{8} \end{matrix}\right] $$

Group the message numbers into 1×2 matrices because the encoding matrix is 2×2.

[27 −15], [64 0], [51 -31]

Multiply the matrices with the decoding matrix.

$$ \color{blue}{\left[\begin{matrix} 27 & -15 \end{matrix}\right]} \left[\begin{matrix} \frac{1}{4} & \frac{1}{8} \\ \frac{1}{4} & -\frac{3}{8} \end{matrix}\right] = \left[\begin{matrix} 3 & 9 \end{matrix}\right] $$

$$ \color{red}{\left[\begin{matrix} 64 & 0 \end{matrix}\right]} \left[\begin{matrix} \frac{1}{4} & \frac{1}{8} \\ \frac{1}{4} & -\frac{3}{8} \end{matrix}\right] = \left[\begin{matrix} 16 & 8 \end{matrix}\right] $$

$$ \color{purple}{\left[\begin{matrix} 51 & -31 \end{matrix}\right]} \left[\begin{matrix} \frac{1}{4} & \frac{1}{8} \\ \frac{1}{4} & -\frac{3}{8} \end{matrix}\right] = \left[\begin{matrix} 5 & 18 \end{matrix}\right] $$

The decoded numbers are 3, 9, 16, 8, 5, 18. Convert these into numbers into letters, CIPHER.

Encode the message GOOD DAY using the encoding matrix \(\left[\begin{matrix} -1 & 2 \\ -3 & 1 \end{matrix}\right]\).

Answer

−52, 29, −27, 34, −12, 4, −76, 27

Lesson Summary

Cramer's Rule

To use Cramer's Rule to solve a system of linear equations

  1. Set up the system of equations in standard form.
  2. Create a matrix of the coefficients of the system. The determinant of this is the denominator of Cramer's Rule.
  3. The numerator is the same as the denominator, but the column of the chosen variable is replaced by the constants. (See the blue columns below.)
  4. Find the determinants and simplify.

For a 2×2 system \(\left\{\begin{align} ax + by &= g \\ cx + dy &= h \end{align}\right.\)

$$ x = \frac{\left|\begin{matrix} \color{blue}{g} & b \\ \color{blue}{h} & d \end{matrix}\right|}{\left|\begin{matrix} a & b \\ c & d \end{matrix}\right|}; \quad y = \frac{\left|\begin{matrix} a & \color{blue}{g} \\ c & \color{blue}{h} \end{matrix}\right|}{\left|\begin{matrix} a & b \\ c & d \end{matrix}\right|} $$

For a 3×3 system \(\left\{\begin{align} ax + by + cz &= \ell \\ dx + ey + fz &= m \\ gx + hy + iz &= n \end{align}\right.\)

$$ x = \frac{\left|\begin{matrix} \color{blue}{\ell} & b & c \\ \color{blue}{m} & e & f \\ \color{blue}{n} & h & i \end{matrix}\right|}{\left|\begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix}\right|}; \quad y = \frac{\left|\begin{matrix} a & \color{blue}{\ell} & c \\ d & \color{blue}{m} & f \\ g & \color{blue}{n} & i \end{matrix}\right|}{\left|\begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix}\right|}; \quad z = \frac{\left|\begin{matrix} a & b & \color{blue}{\ell} \\ d & e & \color{blue}{m} \\ g & h & \color{blue}{n} \end{matrix}\right|}{\left|\begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix}\right|} $$

If the determinant of the coefficients (the denominator) is 0, then there are many solutions or no solution.


Area of a Triangle

The area of a triangle with vertices (x1, y1), (x2, y2), (x3, y3)

$$ Area = ±\frac{1}{2} \left|\begin{matrix} x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \\ x_3 & y_3 & 1 \end{matrix}\right| $$

Where the + or − is chosen to make the area positive.


Determine if Three Points are Collinear

Three points are collinear if the area of the triangle formed is 0.

If \(\left|\begin{matrix} x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \\ x_3 & y_3 & 1 \end{matrix}\right| = 0\), then the points are collinear.


Equation of a Line

To find the equation of a line given 2 points (x1, y1) and (x2, y2), substitute the points and simplify

$$ \left|\begin{matrix} x & y & 1 \\ x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \end{matrix}\right| = 0 $$


Hill Cipher: Encoding a Message
  1. Convert the message into numbers such as
    _ = 0 I = 9 R = 18
    A = 1 J = 10 S = 19
    B = 2 K = 11 T = 20
    C = 3 L = 12 U = 21
    D = 4 M = 13 V = 22
    E = 5 N = 14 W = 23
    F = 6 O = 15 X = 24
    G = 7 P = 16 Y = 25
    H = 8 Q = 17 Z = 26
  2. Choose a square encoding matrix.
  3. Group the message numbers into matrices of 1 row and the same number of columns as the encoding matrix.
  4. Multiply the letter matrices with the encoding matrix.
  5. The encoded message is the list of numbers produced.
Decoding a Message

Multiply the numbers of the encoded message with the inverse of the encoding matrix

Helpful videos about this lesson.

Practice Exercises

  1. Solve the system of equations using Cramer's Rule.
  2. \(\left\{\begin{align} x + 2y &= -2 \\ -x + 4y &= 5 \end{align}\right.\)
  3. \(\left\{\begin{align} 2x - y &= 5 \\ 3x + 2y &= 4 \end{align}\right.\)
  4. \(\left\{\begin{align} x + y &= -1 \\ 2x - 3z &= 8 \\ y + 3z &= -5 \end{align}\right.\)
  5. \(\left\{\begin{align} x + 2y - 2z &= 7 \\ -2x + 3y - z &= -6 \\ x - y - z &= 7 \end{align}\right.\)
  6. Use a determinant to find the area of the triangle with the given vertices.
  7. (2, 3), (4, 6), (0, 1)
  8. (4, 1), (−2, 2), (3, 5)
  9. (−1, −1), (3, 1), (4, 6)
  10. Determine if points are collinear.
  11. (−2, −5), (1, 1), (3, 5)
  12. (−4, 14), (−1, 5), (2, −4)
  13. Use a determinant to find the equation of the line through the given points.
  14. (2, −1), (6, 2)
  15. (−4, 7), (1, 2)
  16. (1, 3), (−8, 2)
  17. Hill Cipher
  18. Encode the message MATH FUN using \(\left[\begin{matrix} 2 & -3 \\ -2 & 1 \end{matrix}\right]\).
  19. Decode the message 18, −27, 16, −54, 28, −42, −22, −7 using the inverse of \(\left[\begin{matrix} 2 & -3 \\ -2 & 1 \end{matrix}\right]\).
  20. Problem Solving
  21. Frankie is designing a new backyard. Part of the landscaping is a triangular garden plot that needs 2 inches of top soil. The coordinates of the vertices of the garden on the diagram of the backyard are (2, 5), (3, 6), and (2.5, 10) where the grid is measured in feet. How much top soil does Frankie need in cubic inches?
  22. Mixed Review
  23. (9-05) Evaluate \(\left|\begin{matrix} 3 & -3 \\ 2 & 1 \end{matrix}\right|\).
  24. (9-05) Evaluate using expansion by cofactors \(\left|\begin{matrix} -4 & 2 & 0 \\ 1 & 3 & 0 \\ 4 & 0 & 2 \end{matrix}\right|\).
  25. (9-04) Use an inverse matrix to solve \(\left\{\begin{align} 3x - 2y &= 14 \\ 7x + 5y &= 23 \end{align}\right.\).
  26. (9-03) \(\left[\begin{matrix} 2 & 0 & -1 \\ 2 & -3 & 5 \end{matrix}\right] \left[\begin{matrix} 1 & 1 \\ 0 & 2 \\ -2 & -1 \end{matrix}\right]\)
  27. (9-02) Put the matrix in reduced-row echelon form \(\left[\begin{matrix} 1 & 3 & -2 & 1 \\ 0 & 1 & -2 & 3 \\ 0 & 0 & 1 & 4 \end{matrix}\right]\).

Answers

  1. \(\left(-3, \frac{1}{2}\right)\)
  2. (2, −1)
  3. (4, −5, 0)
  4. (3, −1, −3)
  5. 1
  6. \(\frac{23}{2}\)
  7. 9
  8. Yes
  9. Yes
  10. 3x − 4y = 10
  11. x + y = 3
  12. x − 9y = −26
  13. 24, −38, 24, −52, −12, 6, 14, −49
  14. I WON IT
  15. 648 in3
  16. 9
  17. −28
  18. (4, −1)
  19. \(\left[\begin{matrix} 4 & 3 \\ -8 & -9 \end{matrix}\right]\)
  20. \(\left[\begin{matrix} 1 & 0 & 0 & -24 \\ 0 & 1 & 0 & 11 \\ 0 & 0 & 1 & 4 \end{matrix}\right]\)