\documentclass[10pt]{article}

\usepackage{systeme}

\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{amssymb}
%\usepackage{palatino}
\usepackage{setdeck}

\usepackage{xcolor}

%\usepackage[textheight=8.5in, margin=1.6in]{geometry}
\usepackage[total={6in,8in}]{geometry}

\usepackage{tikz}
\usetikzlibrary{cd}
\tikzset{
      labr/.style={anchor=north, rotate=90, inner sep=.7mm}
    }
\tikzset{
      labl/.style={anchor=south, rotate=90, inner sep=.7mm}
    }

%\usepackage{pgfplots}
%\tikzstyle{ball} = [circle,shading=ball, ball color=black,
%    minimum size=1mm,inner sep=1.3pt]
%\usetikzlibrary{arrows.meta}
%\tikzset{>={Latex[length=2mm,width=1.5mm]}}

%\usepackage{graphicx}

\usepackage{needspace}  % <-- to prevent bad pagebreak over environment titles
% Use:  \Needspace{3\baselineskip} before opening an environment

\usepackage[shortlabels]{enumitem}
\setlist[enumerate]{leftmargin=*,label=(\alph*)}

%\usepackage[colorlinks=true,citecolor=black,linkcolor=black,urlcolor=blue]{hyperref}

\newcommand{\N}{\mathbb{N}}
\newcommand{\Z}{\mathbb{Z}}
\newcommand{\Q}{\mathbb{Q}}
\newcommand{\R}{\mathbb{R}}
\newcommand{\C}{\mathbb{C}}
\newcommand{\sn}{\mathfrak{S}}
\newcommand{\PP}{\mathbb{P}}
\newcommand{\ve}{\varepsilon}
\newcommand{\ips}[2]{\langle{#1}, {#2}\rangle}
\DeclareMathOperator{\tr}{tr}
\DeclareMathOperator{\Span}{\mathrm{Span}}
\DeclareMathOperator{\rk}{\mathrm{rank}}
\DeclareMathOperator{\rspace}{\mathrm{rowspace}}
\DeclareMathOperator{\cspace}{\mathrm{colspace}}
\DeclareMathOperator{\trace}{\mathrm{tr}}
\DeclareMathOperator{\im}{\mathrm{im}}
\DeclareMathOperator{\Sym}{\mathrm{Sym}}
\DeclareMathOperator{\Hom}{\mathrm{Hom}}
\DeclareMathOperator{\diag}{\mathrm{diag}}
\DeclareMathOperator{\glb}{\mathrm{glb}}
\DeclareMathOperator{\lub}{\mathrm{lub}}

\parskip = 0.05in
\parindent = 0.0in

%\pagestyle{empty}

\allowdisplaybreaks

\begin{document}
\centerline{Math 201 lecture for Wednesday, Week 9}
\bigskip

\centerline{\textbf{Determinants and volume}}  
\medskip

The \emph{parallelogram spanned by~$v,w\in\R^{2}$} is
\[
  P = \left\{\lambda v+\mu w\colon \lambda,\mu\in[0,1]\right\}
\]
where $[0,1]=\left\{x\in\R\colon 0\leq x\leq1\right\}$:
\begin{center}
  \begin{tikzpicture}[scale=0.8]
    \node at (0,0) (0) {};
    \node at (4,0.3) (v) {};
    \node at (1,2) (w) {};
    \node[label={right:$v+w$}] at (5,2.3) (v+w) {};
    \draw[->] (0.center)--node[below right] {$v$} (v.center);
    \draw[->] (0.center)--node[left] {$w$} (w.center);
    \draw[densely dashed] (v.center)--(v+w.center);
    \draw[densely dashed] (w.center)--(v+w.center);
    \draw[fill,blue,opacity=0.1] (0.center)--(v.center)--(v+w.center)--(w.center)--cycle;
  \end{tikzpicture}
\end{center}

\textbf{Theorem.} Let $A(v,w)$ be the area of the parallelogram spanned
by~$v,w\in\R^{2}$.  Then
\[
  A(v,w) = |\det(v,w)|,
\]
where $\det(v,w)$ is the determinant of the matrix with rows~$v$ and~$w$.
\medskip

\textbf{Note:} Since the determinant of a square matrix and its transpose are the
same, $A(v,w)$ is also the absolute value of the matrix whose \emph{columns}
are~$v$ and~$w$.

\begin{proof}[Proof of theorem.]
  Define~$SA(v,w)$ to be the signed area defined in the worksheet.  We show
  that~$SA$ satisfies the properties required of a determinant function.  Then,
  since the determinant is unique, it follows that~$SA(v,w)=\det(v,w)$ and the
  result follows since~$A(v,w)=|SA(v,w)|$.

  \begin{itemize}
    \item \textbf{Normalized.} We have $SA(e_1,e_2)=1$:
      \begin{center}
        \begin{tikzpicture}
          \draw[->] (0,0)--(2,0);
          \draw[->] (0,0)--(0,2);
          \draw[dashed] (2,0)--(2,2);
          \draw[dashed] (0,2)--(2,2);
	  \node at (3,0) {$e_1=(1,0)$.};
	  \node at (0,2.3) {$e_2=(0,1)$};
	  \draw[->] (0.5,0.1) to[out=90, in=0] (0.1,0.5);
	  \node at (0.7,0.7) {$\frac{\pi}{2}$};
        \end{tikzpicture}
      \end{center}
      The sign is positive since the angle from~$e_{1}$ to~$e_{2}$ is less
      than~$\pi$.
    \item \textbf{Alternating.} We have~$SA(v,v)=0$ since in this case, the
      corresponding parallelogram is degenerate.
      \newpage 
    \item \textbf{Multilinear.}
      \begin{itemize}
	\item $SA(cv,w)=cSA(v,w)$ and~$SA(v,cw)=cSA(v,w)$:
	  \medskip

	  $c>0$
	  \begin{center}
	    \begin{tikzpicture}[scale=0.8]
	      \node at (0,0) (0) {};
	      \node at (3,0) (v) {};
	      \node at (1,2) (w) {};
	      \draw[->] (0.center)-- node[midway,below] {$v$} (v.center);
	      \draw[->] (0.center)-- node[midway,left] {$w$} (w.center);
	      \draw[dashed] (w.center)--(4,2);
	      \draw[dashed] (v.center)--(4,2);
	      \draw[->,blue] (v.center)-- node[midway,below] {$cv$} (5,0);
	      \draw[dashed,blue] (5,0)--(6,2);
	      \draw[dashed,blue] (4,2)--(6,2);
	    \end{tikzpicture}
	  \end{center}
	  $c<0$
	  \begin{center}
	    \begin{tikzpicture}[scale=0.8]
	      \node at (0,0) (0) {};
	      \node at (3,0) (v) {};
	      \node at (-3,0) (-v) {};
	      \node at (1,2) (w) {};
	      \draw[->] (0.center)-- node[midway,below] {$v$} (v.center);
	      \draw[->] (0.center)-- node[midway,left] {$w$} (w.center);
	      \draw[dashed] (w.center)--(4,2);
	      \draw[dashed] (v.center)--(4,2);
	      \draw[->] (0.center)-- node[midway,below] {$-v$} (-v.center);
	      \draw[->,blue] (-v.center)-- node[midway,below] {$cv$} (-5,0);
	      \draw[dashed] (w.center)--(-2,2);
	      \draw[dashed] (-2,2)--(-v.center);
	      \draw[dashed,blue] (-2,2)--(-4,2);
	      \draw[dashed,blue] (-5,0)--(-4,2);
	    \end{tikzpicture}
	  \end{center}
      The areas are scaled by~$|c|$ in either case since the base is scaled
      by~$|c|$ and the height does not change.  The drawing assumes that the
      angle from~$v$ to~$w$ is less than~$\pi$.  There is a similar drawing for
      the case where the angle is greater than~$\pi$.  Either way, in the case where~$c<0$
      note that although $SA(cv,w)$ and~$SA(v,w)$ have opposite signs,
      $SA(cv,w)$ and~$cSA(v,w)$ have the same sign.

      Similar drawings show that~$SA(v,cw)=cSA(v,w)$.
    \item $SA(v+u,w)=SA(v,w)+SA(u,w)$:
      \begin{center}
        \begin{tikzpicture}
	  \node at (0,0) (0) {};
	  \node at (4,0) (v) {};
	  \node at (2,1) (u) {};
	  \node at (1,3) (w) {};
	  \node at (6,1) (v+u) {};
	  \node at (5,3) (v+w) {};
	  \node at (3,4) (u+w) {};
	  \node at (7,4) (v+u+w) {};
          \draw[->,densely dashed] (0.center)-- node[midway,below] {$v$} (v.center);
          \draw[->,densely dashed] (0.center)-- node[pos=1.15] {$u$} (u.center);
          \draw[->] (0.center)-- node[midway,left] {$w$} (w.center);
          \draw[->] (0.center)-- node[pos=1.1] {$v+u$} (v+u.center);
	  \draw[densely dashed] (w.center)--(v+u+w.center);
	  \draw[densely dashed] (v+u.center)--(v+u+w.center);
	  \draw[densely dashed] (w.center)--(u+w.center);
	  \draw[densely dashed] (u.center)--(u+w.center);
	  \draw[densely dashed] (v.center)--(v+w.center);
	  \draw[densely dashed] (w.center)--(v+w.center);
	  \draw[densely dashed] (u.center)--(2-0.24*1,1-0.24*3);
	  \draw[fill,blue,opacity=0.1] (0.center)--(v+u.center)--(v+u+w.center)--(w.center)--cycle;
	  \draw[fill,green,opacity=0.3] (0.center)--(v.center)--(v+w.center)--(w.center)--cycle;
	  \draw[fill,yellow,opacity=0.5] (0.center)--(u.center)--(u+w.center)--(w.center)--cycle;
	  \draw[densely dashed] (v+w.center)--(5+0.23*1,3+0.23*3);
	  \node at (2.4,3.45) {$a$};
	  \node at (1.4,0.45) {$a'$};
	  \node at (4.4,3.25) {$b'$};
	  \node at (3.4,0.25) {$b$};
        \end{tikzpicture}
      \end{center}
  Note how to dissect the $u$-$w$ and $v$-$w$ parallelograms to get
  the~$(v+u)$-$w$ parallelogram:  Cut section~$a$ in the $u$-$w$ parallelogram
  and place it at section~$a'$, then cut section~$b$ in the $v$-$w$
  parallelogram and place it at section~$b'$.  The result is two parallelograms
  that can exactly cover the $(v+u)$-$w$ parallelogram.

  Of course, our drawing is just one case among the many possible angles between
  pairs of~$v$, $u$, and~$w$.
      \end{itemize}
  \end{itemize}
\end{proof}
\newpage

  \textbf{Definition.}  The \emph{parallelepided spanned
  by~$v_{1},\ldots,v_{n}\in\R^{n}$} is
  \[
    P=
    \left\{\lambda_{1}v_1+\cdots+\lambda_{n}v_{n}: \lambda_{i}\in[0,1]\text{ for
    $i=1,\ldots,n$}\right\},
  \]
 \begin{center}
   \begin{tikzpicture}[scale=0.4]
\draw [->, line width=.4mm] (0,0) node {}  --  (1,2) ;
\draw [->, line width=.4mm] (0,0) node {}  --  (3,1) ;
\draw [->, line width=.4mm] (0,0) node {}  --  (-2,2) ;
\draw [line width=.2mm] (3,1) node {}  --  (4,3) ;
\draw [line width=.2mm] (3,1) node {}  --  (1,3) ;
\draw [line width=.2mm] (1,2) node {}  --  (4,3) ;
\draw [line width=.2mm] (1,2) node {}  --  (-1,4) ;
\draw [line width=.2mm] (-2,2) node {}  --  (-1,4) ;
\draw [line width=.2mm] (-2,2) node {}  --  (1,3) ;
\draw [line width=.2mm] (4,3) node {}  --  (2,5) ;
\draw [line width=.2mm] (1,3) node {}  --  (2,5) ;
\draw [line width=.2mm] (-1,4) node {}  --  (2,5) ;
\node at (4,0) {.};
\end{tikzpicture}
\end{center}

It turns out that the volume of $P$ is given by the determinant of the matrix
whose row (or columns) are~$v_1,\ldots,v_n$:
\[
  \mathrm{vol}(P)=|\det(v_{1},\ldots,v_{n})|.
\]

Note that one of the vertices of~$P$ is the origin (set
$\lambda_{1}=\cdots=\lambda_{n}=0$).  To get an arbitrary parallelepiped
in~$\R^{n}$ we can just translate by any vector~$u\in\R^{n}$:
\[
  P+u:=\left\{p+u:p\in P\right\}
  = \left\{\lambda_{1}v_1+\cdots+\lambda_{n}v_{n}+u: 0\leq\lambda_{i}\leq 1\text{ for $i=1,\ldots,n$}\right\}.
\]
The volume does not change:
\[
  \mathrm{vol}(P+u)=|\det(v_{1},\ldots,v_{n})|.
\]
\medskip

\textbf{Theorem.}  Let~$P$ be the parallelepided spanned
by~$v_{1},\ldots,v_{n}\in\R^{n}$.  Let~$A\in M_{n\times n}(\R)$, and
let~$L_{A}\colon\R^{n}\to\R^{n}$ be the corresponding linear function,
$L_{A}(x)=Ax$.  Then~$L_A(P)$ is the parallelepiped spanned by
the vectors $Av_{1},\ldots,Av_{n}$, and
\[
  \mathrm{vol}(L_A(P))=|\det(A)|\mathrm{vol}(P).
\]
Moreover, $L_{A}(P+u)=L_{A}(P)+L_{A}(u)$.  Thus, \emph{application of~$L_A$ scales the
volumes of parallelepipeds in~$\R^{n}$ be a factor of $|\det(A)|$}.
\begin{proof}
  We have~$x\in L_{A}(P)$ if and only if there
  exist~$\lambda_{1},\ldots,\lambda_{n}\in[0,1]$ such that
  \[
    x
    =A(\lambda_{1}v_{1}+\cdots+\lambda_{n}v_{n})
    =\lambda_{1}Av_{1}+\cdots+\lambda_{n}Av_{n},
  \]
  i.e., if and only if~$x$ is in the parallelepiped determined
  by~$Av_{1},\ldots,Av_{n}$.

  Let~$B$ be the matrix with columns~$v_{1},\ldots,v_{n}$.
  Then~$\mathrm{vol}(P)=|\det(B)|$,  Note that~$AB$ is the matrix whose columns
  are $Av_{1},\ldots,Av_{n}$.  It follows that
  \[
    \textrm{vol}(L_{A}(P))=|\det(AB)|=|\det(A)||\det(B)|.
  \]

  We have $L_{A}(P+u)=L_{A}(P)+L_{A}(u)$ since~$L_{A}$ is linear.
\end{proof}

\textbf{Remark.} To approximate the volume of an arbitrary shape in~$\R^{n}$,
one can try to dissect the shape into a union of parallelepipeds.  One
definition of the volume of an arbitrary shape is derived by taking limits of
such approximations.  One can then ask how the volume of a shape~$S$ changes
under the application of a function~$f\colon\R^{n}\to\R^{n}$.  If the function
is ``nice'' (differentiable), then at each point~$p$ in the shape, one creates a
linear approximation~$Df(p)$ of the function~$f$ (called the \emph{derivative
of~$f$ at~$p$}), akin to $L_A$, above.  Further assuming that~$f$ is injective,
the volume of the image of the shape is then given by the \emph{change of
variables} formula in multivariable calculus:
\[
  \mathrm{vol}(f(S))=\int_{p\in S}|\det(Df(p))|.
\]
In light of the theorem we just proved, the determinant~$|Df(p)|$ should be
thought of as a scaling factor.  It tells us how much $f$ scales volumes
(infinitesimally) at~$p$.
\end{document}  
