\documentclass[12pt]{article}
\usepackage[margin=0.5in,foot=0.1in]{geometry}
\usepackage{amsmath,amssymb,graphicx,txfonts,multicol,soul}
\usepackage[setpagesize=false]{hyperref}
\usepackage[usenames,dvipsnames]{xcolor}
% Following http://tex.stackexchange.com/a/847/22475:
\usepackage[setpagesize=false]{hyperref}\hypersetup{colorlinks,
  linkcolor={blue!50!black},
  citecolor={blue!50!black},
  urlcolor=blue
}

\def\myurl{http://www.math.toronto.edu/~drorbn/}

\def\red{\color{red}}

\def\bbC{{\mathbb C}}
\def\bbF{{\mathbb F}}
\def\bbQ{{\mathbb Q}}
\def\bbR{{\mathbb R}}
\def\bbV{{\mathbb V}}
\def\bbZ{{\mathbb Z}}
\def\calS{{\mathcal S}}
\def\Aut{\operatorname{Aut}}

\def\problempage{{
  \newpage\noindent\parbox{0.5\linewidth}{
    \footnotesize Solve all 5 problems. Write your solutions only where indicated, or write explicitly, ``continued on page $k$''.
    \newline{\bf Neatness counts! Language counts!}
  }
  \vskip 2mm
  }\parshape 4 0in 0.5\linewidth 0in 0.5\linewidth 0in 0.5\linewidth 0in \linewidth}
\def\yoursolution#1{{
  \vskip 2mm \noindent{\bf Your solution of Problem #1.}
  \newpage\noindent\hfill{\bf Your solution of Problem #1, continued.}
}}
\def\scratchright{{
  \newpage\noindent\hfill\parbox{0.35\linewidth}{\bf
    Scratch work --- this page will not be read unless you explicitly request it.
  }
}}
\def\scratchleft{{
  \newpage\noindent\parbox{0.35\linewidth}{\bf
    Scratch work --- this page will not be read unless you explicitly request it.
  }
}}
\def\scratchboth{{\scratchleft\scratchright}}

% Comment out the following line for the Crowdmark version:
\pagestyle{empty} \def\problempage{} \def\yoursolution#1{\vfill} \def\scratchright{} \def\scratchleft{} \def\scratchboth{}

\begin{document}
\noindent{\small
  \url{http://drorbn.net/25-347}
  \newline\href{\myurl}{Dror Bar-Natan}:
  \href{\myurl/classes/}{Classes}:
  \href{\myurl/classes/\#2526}{2025-26}:
}

\vskip 4mm
\noindent{\bf Do not open this notebook until instructed.}
\vskip 4mm
\begin{center}
  \href{http://drorbn.net/24-327}{\large MAT 347 Groups, Rings, Fields}
  \vskip 4mm
  {\LARGE Term Test 2}
  \vskip 4mm
  University of Toronto, February 3, 2026
  \vskip 5mm{\bf Solve all 5 problems in this booklet. }\\
  The problems are of equal weight.\\
  You have an hour and fifty minutes to write this test.
\end{center}

\vskip 9cm

\noindent{\bf Notes}
\begin{itemize}
\item No outside material allowed other than stationery, minimal hydration and snacks, and stuffed animals.
\item Write your solution to each problem on its page and on the back of that page. If you run out of space you may continue into the scratch pages, but you {\bf must} indicate this on the problem page or else the scratch pages will not be read.
\item {\bf Neatness counts! Language counts!} The {\em ideal} written solution to a problem looks like a page from a textbook -- neat and clean and consisting of complete and grammatical sentences. Definitely phrases like ``there exists'' or ``for every'' cannot be skipped. Lectures are mostly made of spoken words, and so the blackboard part of proofs given during lectures often omits or shortens key phrases. The ideal written solution to a problem does not do that.
\item Please return this booklet intact, without tearing out any pages. If you use some of the pages as scratch, mark them SCRATCH and return them too.
%\item {\red {\bf In Red.} Added after the test took place.}
\end{itemize}

\vfill\begin{center} {\bf Good Luck!} \end{center}\vfill\eject

\scratchright

\problempage
\noindent{\bf Problem 1. } Prove that if the group $\bbZ^r$ is isomorphic to the group $\bbZ^s$, then $r=s$.

\vskip 2mm
\par\noindent{\small {\bf Tip. } As always in math exams, when proving a theorem you may freely assume anything that preceded it but you may not assume anything that followed it.}

\par\noindent{\small {\bf Tip. } Don't start working! Read the whole exam first. You may wish to start with the questions that are easiest for you.}

\par\noindent{\small {\bf Tip. } Neatness, cleanliness and organization count, here and everywhere else!}

\yoursolution{1}

\problempage
\noindent{\bf Problem 2. } Let $R$ be a commutative domain. Let $a,b\in R$. You can worry less and assume that they are both non-zero.
\begin{enumerate}
\item Define ``a greatest common divisor'' of $a$ and $b$.
\item Prove that if a greatest common divisor of $a$ and $b$ exists, it is unique up to a unit.
\item In $R=\bbQ[x]$, compute the greatest common divisor of $a=2 x^3+x^2+x-1$ and $b=x^3-x^2-x-2$.
\end{enumerate}

\yoursolution{2}

\problempage
\noindent{\bf Problem 3. } Let $R$ be a commutative domain.
\begin{enumerate}
\item Define ``$R$ is a UFD'' and ``$R$ is a PID''.
\item If $R$ is a UFD in which for any two non-zero elements $a,b$ you can find two elements $s,t$ such that $\gcd(a,b)=sa+tb$, prove that $R$ is a PID.
    \par {\em Hint.} Fish an element with a minimal number of factors.
\end{enumerate}

\yoursolution{3} 

\problempage
\noindent{\bf Problem 4. } Show that the element ``$2\otimes 1$'' is zero in $\bbZ\otimes_\bbZ(\bbZ/2)$ but non-zero in $(2\bbZ)\otimes_\bbZ(\bbZ/2)$.

\yoursolution{4}

\problempage
\noindent{\bf Problem 5. } Let $F$ be any field, let $\lambda\in F$, let $0<s\in\bbZ$ and let $V=F[x]/\langle(x-\lambda)^s\rangle$, regarded both as an $F[x]$-module and as a vector space over $F$.
\begin{enumerate}
\item What is $\dim_F V$? Justify your answer.
\item Show that with the right choice of basis, the matrix representing the linear transformation $T\colon V\to V$ given by $Tv\coloneqq x\cdot v$ is the ``Jordan block'' matrix $A$ --- the matrix that has $\lambda$'s along its main diagonal, $1$'s along the diagonal below the main diagonal, and $0$'s everywhere else.
\end{enumerate}

\par\noindent{\small {\bf Tip. } Once you have finished writing an exam, if you have time left, it is always a good idea to go back and re-read and improve everything you have written, and perhaps even completely rewrite any parts that came out messy.}

\yoursolution{5}

\scratchboth
\scratchboth
\scratchboth
\scratchboth
\scratchboth

\end{document}

