# Linear Algebra/Topic: Cramer's Rule/Solutions

## Solutions

Problem 1

Use Cramer's Rule to solve each for each of the variables.

1. ${\displaystyle {\begin{array}{*{2}{rc}r}x&-&y&=&4\\-x&+&2y&=&-7\end{array}}}$
2. ${\displaystyle {\begin{array}{*{2}{rc}r}-2x&+&y&=&-2\\x&-&2y&=&-2\end{array}}}$
1. ${\displaystyle x=1}$, ${\displaystyle y=-3}$
2. ${\displaystyle x=-2}$, ${\displaystyle y=-2}$
Problem 2

Use Cramer's Rule to solve this system for ${\displaystyle z}$.

${\displaystyle {\begin{array}{*{4}{rc}r}2x&+&y&+&z&=&1\\3x&&&+&z&=&4\\x&-&y&-&z&=&2\end{array}}}$

${\displaystyle z=1}$

Problem 3

Prove Cramer's Rule.

Determinants are unchanged by pivots, including column pivots, so ${\displaystyle \det(B_{i})=\det({\vec {a}}_{1},\dots ,x_{1}{\vec {a}}_{1}+\dots +x_{i}{\vec {a}}_{i}+\dots +x_{n}{\vec {a}}_{n},\dots ,{\vec {a}}_{n})}$ is equal to ${\displaystyle \det({\vec {a}}_{1},\dots ,x_{i}{\vec {a}}_{i},\dots ,{\vec {a}}_{n})}$ (use the operation of taking ${\displaystyle -x_{1}}$ times the first column and adding it to the ${\displaystyle i}$-th column, etc.). That is equal to ${\displaystyle x_{i}\cdot \det({\vec {a}}_{1},\dots ,{\vec {a}}_{i},\dots ,{\vec {a}}_{n})=x_{i}\cdot \det(A)}$, as required.

Problem 4

Suppose that a linear system has as many equations as unknowns, that all of its coefficients and constants are integers, and that its matrix of coefficients has determinant ${\displaystyle 1}$. Prove that the entries in the solution are all integers. (Remark. This is often used to invent linear systems for exercises. If an instructor makes the linear system with this property then the solution is not some disagreeable fraction.)

Because the determinant of ${\displaystyle A}$ is nonzero, Cramer's Rule applies and shows that ${\displaystyle x_{i}=\left|B_{i}\right|/1}$. Since ${\displaystyle B_{i}}$ is a matrix of integers, its determinant is an integer.

Problem 5

Use Cramer's Rule to give a formula for the solution of a two equations/two unknowns linear system.

The solution of

${\displaystyle {\begin{array}{*{2}{rc}r}ax&+by&=&e\\cx&+dy&=&f\end{array}}}$

is

${\displaystyle x={\frac {ed-fb}{ad-bc}}\qquad y={\frac {af-ec}{ad-bc}}}$

provided of course that the denominators are not zero.

Problem 6

Can Cramer's Rule tell the difference between a system with no solutions and one with infinitely many?

Of course, singular systems have ${\displaystyle \left|A\right|}$ equal to zero, but the infinitely many solutions case is characterized by the fact that all of the ${\displaystyle \left|B_{i}\right|}$ are zero as well.

Problem 7

The first picture in this Topic (the one that doesn't use determinants) shows a unique solution case. Produce a similar picture for the case of infintely many solutions, and the case of no solutions.

${\displaystyle {\begin{array}{*{2}{rc}r}x_{1}&+&2x_{2}&=&6\\x_{1}&+&2x_{2}&=&c\end{array}}}$
where ${\displaystyle c=6}$ of course yields infinitely many solutions, and any other value for ${\displaystyle c}$ yields no solutions. The corresponding vector equation
${\displaystyle x_{1}\cdot {\begin{pmatrix}1\\1\end{pmatrix}}+x_{2}\cdot {\begin{pmatrix}2\\2\end{pmatrix}}={\begin{pmatrix}6\\c\end{pmatrix}}}$
gives a picture of two overlapping vectors. Both lie on the line ${\displaystyle y=x}$. In the ${\displaystyle c=6}$ case the vector on the right side also lies on the line ${\displaystyle y=x}$ but in any other case it does not.