%\input{tcilatex}


\documentclass[12pt]{amsart}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage{amsfonts}
\usepackage{float}
\usepackage{amsmath}
\usepackage{graphicx}

\setcounter{MaxMatrixCols}{10}
%TCIDATA{OutputFilter=LATEX.DLL}
%TCIDATA{Version=5.50.0.2960}
%TCIDATA{<META NAME="SaveForMode" CONTENT="1">}
%TCIDATA{BibliographyScheme=Manual}
%TCIDATA{LastRevised=Thursday, September 16, 2021 14:26:21}
%TCIDATA{<META NAME="GraphicsSave" CONTENT="32">}
%TCIDATA{CSTFile=amsart.cst}

\textwidth=6.45in
\textheight=10.0in
\oddsidemargin=0in
\evensidemargin=0in
\topmargin=-.750in
\setlength{\parskip}{.05in}
\setlength{\parindent}{0in}
\input{tcilatex}

\begin{document}

\begin{center}
\textbf{Math 3013} \\[0pt]
SOLUTION TO FIRST EXAM \\[0pt]
10:30 - 11:20pm, September 15, 2021
\end{center}

1. Let 
\begin{equation*}
\quad \mathbf{A}=\left[ 
\begin{array}{ccc}
2 & 0 & 1 \\ 
1 & -1 & 0%
\end{array}%
\right] \quad \mathbf{B}=\left[ 
\begin{array}{ccc}
1 & 0 & -1 \\ 
0 & 2 & 1 \\ 
-1 & 1 & 1%
\end{array}%
\right]
\end{equation*}%
Compute the matrix products $\mathbf{AB}$ and $\mathbf{BA}$ (if they exist).

\begin{itemize}
\item 
\begin{eqnarray*}
\mathbf{AB} &\mathbf{=}&\left[ 
\begin{array}{ccc}
2 & 0 & 1 \\ 
1 & -1 & 0%
\end{array}%
\right] \left[ 
\begin{array}{ccc}
1 & 0 & -1 \\ 
0 & 2 & 1 \\ 
-1 & 1 & 1%
\end{array}%
\right] \\
&=&\left[ 
\begin{array}{ccc}
2+0-1 & 0+0+1 & -2+0+1 \\ 
1+0+0 & 0-2+0 & -1-1+0%
\end{array}%
\right] \\
&=&\left[ 
\begin{array}{ccc}
1 & 1 & -1 \\ 
1 & -2 & -2%
\end{array}%
\right]
\end{eqnarray*}
\begin{equation*}
\mathbf{BA}\text{ is undefined since the \# of columns of the first factor }%
\neq \text{ \# columns of the second factor}
\end{equation*}
\end{itemize}

2. For each of the following augmented matrices, indicate

\begin{itemize}
\item the number of equations and the number of variables in the original
linear system

\item whether or not the corresponding linear system has a solution

\item if the corresponding linear system does have a solution, the number of
free variables in the solution.
\end{itemize}

Hint: note that these augmented matrices are already in row echelon form.

(a) $\left[ 
\begin{array}{cccc|c}
1 & 0 & 1 & 2 & 1 \\ 
0 & 0 & 0 & 1 & 2 \\ 
0 & 0 & 0 & 0 & 1%
\end{array}%
\right] $

\begin{itemize}
\item 3 equations in 4 variables

no solution (because of the pivot in last column of last row)
\end{itemize}

(b) $\left[ 
\begin{array}{ccccc|c}
1 & 0 & 0 & 0 & 1 & 3 \\ 
0 & 1 & 3 & 2 & 2 & 2 \\ 
0 & 0 & 0 & 1 & 2 & 1 \\ 
0 & 0 & 0 & 0 & 0 & 0%
\end{array}%
\right] $

\begin{itemize}
\item 4 equations in 5 variables

there is a solution

two free variables, $x_{3}$ and $x_{5}$ (because there are no pivots in the
corresponding columns on the L.H.S.)
\end{itemize}

(c) $\left[ 
\begin{array}{cccc|c}
1 & 2 & 1 & -1 & 1 \\ 
0 & 0 & 1 & 1 & 2 \\ 
0 & 0 & 0 & 1 & 1%
\end{array}%
\right] $

\begin{itemize}
\item 3 equation in 4 variables

there is a solution

1 free variable, $x_{2}$, because on the L.H.S. only the second column lacks
a pivot
\end{itemize}

\newpage

3. Consider the following linear system 
\begin{equation*}
\begin{array}{rcr}
3x_{2}+x_{3} & = & 0 \\ 
x_{1}-x_{2} & = & 1 \\ 
x_{1}+2x_{2}+x_{3} & = & 1%
\end{array}%
\end{equation*}%
Write down the corresponding augmented matrix and row reduce it to
row-echelon form.

\begin{itemize}
\item 
\begin{eqnarray*}
\left[ \mathbf{A}|\mathbf{b}\right] &=&\left[ 
\begin{array}{ccc|c}
0 & 3 & 1 & 0 \\ 
1 & -1 & 0 & 1 \\ 
1 & 2 & 1 & 1%
\end{array}%
\right] \quad \underrightarrow{\quad R_{1}\longleftrightarrow R_{3}\quad }%
\quad \left[ 
\begin{array}{ccc|c}
1 & 2 & 1 & 1 \\ 
1 & -1 & 0 & 1 \\ 
0 & 3 & 1 & 0%
\end{array}%
\right] \\
\underrightarrow{\quad R_{2}\rightarrow R_{2}-R_{1}\quad } &&\left[ 
\begin{array}{ccc|c}
1 & 2 & 1 & 1 \\ 
0 & -3 & -1 & 0 \\ 
0 & 3 & 1 & 0%
\end{array}%
\right] \quad \\
\underrightarrow{\quad R_{3}\rightarrow R_{3}-R_{2}\quad } && \left[ 
\begin{array}{ccc|c}
1 & 2 & 1 & 1 \\ 
0 & -3 & -1 & 0 \\ 
0 & 0 & 0 & 0%
\end{array}%
\right] =R.E.F.\left( \left[ \mathbf{A}|\mathbf{b}\right] \right)
\end{eqnarray*}
\end{itemize}

4. Row reduce the following augmented matrix to \textbf{reduced} row-echelon
form. 
\begin{equation*}
\left[ \mathbf{A}|\mathbf{b}\right] =\left[ 
\begin{array}{ccccc|c}
2 & 0 & 2 & 6 & 2 & 2 \\ 
0 & 0 & 2 & 2 & 2 & 4 \\ 
0 & 0 & 0 & 0 & -3 & 3 \\ 
0 & 0 & 0 & 0 & 0 & 0%
\end{array}%
\right]
\end{equation*}

\begin{itemize}
\item 
\begin{eqnarray*}
\underrightarrow{\quad 
\begin{array}{c}
R_{1}\rightarrow \frac{1}{2}R_{1} \\ 
R_{2}\rightarrow \frac{1}{2}R_{2} \\ 
R_{3}\rightarrow -\frac{1}{3}R_{3}%
\end{array}%
\quad } && \left[ 
\begin{array}{ccccc|c}
1 & 0 & 1 & 3 & 1 & 1 \\ 
0 & 0 & 1 & 1 & 1 & 2 \\ 
0 & 0 & 0 & 0 & 1 & -1 \\ 
0 & 0 & 0 & 0 & 0 & 0%
\end{array}%
\right] \\
\underrightarrow{\quad 
\begin{array}{c}
R_{1}-\rightarrow R_{1}-R_{3} \\ 
R_{2}\rightarrow R_{2}-R_{3}%
\end{array}%
\quad } && \left[ 
\begin{array}{ccccc|c}
1 & 0 & 1 & 3 & 0 & 2 \\ 
0 & 0 & 1 & 1 & 0 & 3 \\ 
0 & 0 & 0 & 0 & 1 & -1 \\ 
0 & 0 & 0 & 0 & 0 & 0%
\end{array}%
\right] \\
\underrightarrow{\quad R_{1}-\rightarrow R_{1}-R_{2}\quad } && \left[ 
\begin{array}{ccccc|c}
1 & 0 & 0 & 2 & 0 & -1 \\ 
0 & 0 & 1 & 1 & 0 & 3 \\ 
0 & 0 & 0 & 0 & 1 & -1 \\ 
0 & 0 & 0 & 0 & 0 & 0%
\end{array}%
\right] =R.R.E.F.\left( \left[ \mathbf{A}|\mathbf{b}\right] \right)
\end{eqnarray*}
\end{itemize}

\newpage

5. Suppose the augmented matrix below is the Reduced Row Echelon Form of an
augmented matrix of a linear system. Display the solution of the linear
system as a hyperplane (within the space of variables). 
\begin{equation*}
\left[ 
\begin{array}{ccccc|c}
1 & 0 & 0 & 2 & 0 & 1 \\ 
0 & 0 & 1 & -1 & 0 & 2 \\ 
0 & 0 & 0 & 0 & 1 & 2%
\end{array}%
\right]
\end{equation*}

\begin{itemize}
\item Columns $2$ and $4$ of the R.R.E.F. do not contain pivots, and so $%
x_{2}$ and $x_{4}$ will be free variables in the solution. \ Writing down
the equations corresponding to this augmented matrix, and moving the free
variables to the right hand side we have%
\begin{equation*}
\left. 
\begin{array}{r}
x_{1}+2x_{4}=1 \\ 
x_{3}-x_{4}=2 \\ 
x_{5}=2%
\end{array}%
\right\} \quad \Rightarrow \quad \left\{ 
\begin{array}{l}
x_{1}=1-2x_{4} \\ 
x_{3}=2+x_{4} \\ 
x_{5}=2%
\end{array}%
\right.
\end{equation*}%
And so a typical solution vector will be of the form%
\begin{equation*}
\mathbf{x}=\left[ 
\begin{array}{c}
1-2x_{4} \\ 
x_{2} \\ 
2+x_{4} \\ 
x_{4} \\ 
2%
\end{array}%
\right] =\left[ 
\begin{array}{c}
1 \\ 
0 \\ 
2 \\ 
0 \\ 
2%
\end{array}%
\right] +x_{2}\left[ 
\begin{array}{c}
0 \\ 
1 \\ 
0 \\ 
0 \\ 
0%
\end{array}%
\right] +x_{4}\left[ 
\begin{array}{c}
-2 \\ 
0 \\ 
1 \\ 
1 \\ 
0%
\end{array}%
\right]
\end{equation*}%
which displays the solution vectors as points on a $2$-dimensional plane.
\end{itemize}

6. Determine if the following matrix has an inverse. \ If the matrix does
have an inverse, determine its inverse. (Hint: a single row reduction
process can determine the answer to both parts of this problem.) 
\begin{equation*}
\mathbf{A}=\left[ 
\begin{array}{ccc}
-1 & 0 & -1 \\ 
2 & 1 & 1 \\ 
0 & -1 & 0%
\end{array}%
\right]
\end{equation*}

\begin{itemize}
\item 
\begin{eqnarray*}
\left[ \mathbf{A}|\mathbf{I}\right]  &=&\left[ 
\begin{array}{ccc|ccc}
-1 & 0 & -1 & 1 & 0 & 0 \\ 
2 & 1 & 1 & 0 & 1 & 0 \\ 
0 & -1 & 0 & 0 & 0 & 1%
\end{array}%
\right] \quad \underrightarrow{\quad R_{2}\rightarrow R_{2}+2R_{1}\quad }%
\quad \left[ 
\begin{array}{ccc|ccc}
-1 & 0 & -1 & 1 & 0 & 0 \\ 
0 & 1 & -1 & 2 & 1 & 0 \\ 
0 & -1 & 0 & 0 & 0 & 1%
\end{array}%
\right]  \\
\underrightarrow{\quad R_{3}\rightarrow R_{3}+R_{2}\quad } &&\left[ 
\begin{array}{ccc|ccc}
-1 & 0 & -1 & 1 & 0 & 0 \\ 
0 & 1 & -1 & 2 & 1 & 0 \\ 
0 & 0 & -1 & 2 & 1 & 1%
\end{array}%
\right] \quad \underrightarrow{%
\begin{array}{c}
\quad R_{1}\rightarrow -R_{1} \\ 
R_{3}\rightarrow -R_{3}\quad 
\end{array}%
}\quad \left[ 
\begin{array}{ccc|ccc}
1 & 0 & 1 & -1 & 0 & 0 \\ 
0 & 1 & -1 & 2 & 1 & 0 \\ 
0 & 0 & 1 & -2 & -1 & -1%
\end{array}%
\right]  \\
\underrightarrow{%
\begin{array}{c}
R_{1}\rightarrow R_{1}-R_{3} \\ 
R_{2}\rightarrow R_{2}+R_{3}%
\end{array}%
} &&\left[ 
\begin{array}{ccc|ccc}
1 & 0 & 0 & 1 & 1 & 1 \\ 
0 & 1 & 0 & 0 & 0 & -1 \\ 
0 & 0 & 1 & -2 & -1 & -1%
\end{array}%
\right] =R.R.E.F.\left( \left[ \mathbf{A}|\mathbf{I}\right] \right) 
\end{eqnarray*}%
Since the left hand side of the R.R.E.F. of $\left[ \mathbf{A}|\mathbf{I}%
\right] $ is the identity matrix, the right hand side must be $\mathbf{A}%
^{-1}$. \ Thus,%
\begin{equation*}
\mathbf{A}^{-1}=\left[ 
\begin{array}{ccc}
1 & 1 & 1 \\ 
0 & 0 & -1 \\ 
-2 & -1 & -1%
\end{array}%
\right] 
\end{equation*}
\end{itemize}

\end{document}
