\documentclass[11pt]{article}
\usepackage{amsmath,amsfonts}

\title{Solutions to Homework 4}
\date{}

\newcommand \C {\mathbb C}
\newcommand \Q {\mathbb Q}
\newcommand \R {\mathbb R}
\newcommand \Z {\mathbb Z}
\renewcommand \phi \varphi

\DeclareMathOperator \im {im}

\begin{document}
\maketitle

\begin{enumerate}

\item Let $R$ be a ring and $\phi\colon \Q \to R$ be a homomorphism.  Show that either $R = 0$ or $\phi$ is injective.  Hint: $\ker \phi$ is an ideal of $\Q$, and in lecture we described all of these.

{\bf Solution:} In lecture we saw that the only ideals of $\Q$ are $(0)$ and $(1)$.  If $\ker \phi = (0)$ then $\phi$ is injective.  If $\ker \phi = (1)$ then in particular $\phi(1) = 0$; but we also have $\phi(1) = 1$, so $1 = 0$ in $R$, so $R$ is the zero ring.

\item In lecture we saw that every ideal in $\Q[x]$ is \emph{principal}: that is, for every ideal $I \subset \Q[x]$ there is an $f \in \Q[x]$ such that $I = (f)$.  In contrast, show that $(2,x) \subset \Z[x]$ is not a principal.

{\bf Solution:} Suppose that $(2,x) \subseteq (f)$ for some $f \in \Z[x]$.  I claim that $f = \pm 1$.  Since $2 \in (f)$, we can write $2 = fg$ for some $g \in \Z[x]$.  Taking degrees, we get $0 = \deg f + \deg g$, so $\deg f = 0$, so $f$ is a constant polynomial, say $f = a$ with $a \in \Z$.  Since $x \in (f) = (a)$, we can write $x = ah$ for some $h \in \Z[x]$.  Plugging in $x = 1$ we get $1 = a \cdot h(1)$, so $a$ is a unit in $\Z$, that is, $a = \pm 1$.  So if $(2,x) \subset (f)$ then $f = \pm 1$, as claimed.  But then $(f)$ is all of $\Z[x]$, and we have seen in lecture that $(2,x)$ is the set of polynomials whose constant term is even, which is not all of $\Z[x]$.

\item
\begin{enumerate}
\item Show that there is no homomorphism $\phi\colon \Q[x] \to \Z[y]$.

{\bf Solution:} Suppose that there were such a $\phi$, and let $f = \phi(\frac12)$.  Then $2f = f + f = \phi(\frac12) + \phi(\frac12) = \phi(\frac12+\frac12) = \phi(1) = 1$.  Writing $f = a_0 + a_1 x + \dotsb + a_n x^n$, we find that $2a_0 = 1$ and $2 a_i = 0$ for $i > 0$.  But there is no $a_0 \in \Z$ with $2 a_0 = 1$.

Alternatively, you could let $i\colon \Q \to \Q[x]$ be the inclusion of the constant polynomials; then $\phi \circ i\colon \Q \to \Z[x]$ is injective by problem 1.  We have seen in lecture that a homomorphism takes units to units.  But there are infinitely many units in $\Q$, and we have seen that the units in $\Z[x]$ are just the constant polynomials $\pm 1$, and an infinite set cannot inject into a set with two elements.

\item Describe all homomorphisms $\psi\colon \Z[y] \to \Q[x]$.

{\bf Solution:} I claim that the map $\psi$ is determined by where it sends $y$.  Indeed, we must have $\psi(0) = 0$, and $\psi(1) = 1$, and
\[ \psi(2) = \psi(1+1) = \psi(1) + \psi(1) = 1 + 1 = 2, \]
and so on: $\psi(a) = a$ for all $a \in \Z$.  Thus for an arbitrary
\[ f = a_0 + a_1 y + a_2 y^2 + \dotsb + a_n y^n \in \Z[y] \]
we have
\[ \psi(f) = a_0 + a_1 \psi(y) + a_2 \psi(y)^2 + \dotsb + a_n \psi(y)^n. \]
So $\psi(y)$ determines $\psi(f)$ for every $f \in \Z[y]$.

On the other hand, for any $g \in \Q[x]$, the map
\[ \psi(a_0 + a_1 y + a_2 y^2 + \dotsb + a_n y^n) = a_0 + a_1 g + a_2 g^2 + \dotsb + a_n g^n \]
is a homomorphism.  So there is exactly one homomorphism $\psi\colon \Z[y] \to \Q[x]$ for every $g \in \Q[x]$.

\item Optional: Show that no such $\psi$ is surjective.

{\bf Solution:} Write $\psi(y) = b_0 + b_1 x + \dotsb + b_m x^m \in \Q[x]$, write $b_0 = p/q$ with $p, q \in \Z$, and let $\ell$ be a prime not dividing $q$.  I claim that $\frac{1}{\ell} \notin \im \psi$.  Indeed, for any
\[ f = a_0 + a_1 x + \dotsb + a_n x^n \in \Z[x] \]
we have
\[ \phi(f) = a_0 + a_1 g + a_2 g^2 + \dotsb + a_n g^n, \]
whose constant term is
\begin{multline*}
a_0 + a_1 b_0 + a_1 b_0^2 + \dotsb + a_n b_0^n \\
= (a_0 q^n + a_1 p q^{n-1} + a_2 p^2 q^{n-2} + \dotsb + a_n p^n)/q^n.
\end{multline*}
Since $\ell$ does not divide $q^n$, this cannot equal $1/\ell$.

Alternatively, consider the map $r\colon \Q[x] \to \Q$ given by $r(g) = g(0)$, which is a surjective homomorphism.  If $\phi\colon \Z[y] \to \Q[x]$ were a surjective homomorphism then $r \circ \phi\colon \Z[y] \to \Q$ would be a surjective homomorphism.  So it is enough to argue that there is no surjective homomorphism $\Z[x] \to \Q$, which is similar to the argument above but maybe a little cleaner.

\end{enumerate}

\item
\begin{enumerate}
\item Write down two or three elements of $\Q[x][y]$.

{\bf Solution:} I'll chose
\begin{gather*}
(x^2 + 4) y^2 + (2x + 3) y + (x^2 + 1) \\
x y^3 + (x^2 - 1) y + 2x
\end{gather*}

\item For any ring $R$, give an isomorphism $\phi\colon R[x][y] \to R[y][x]$.

{\bf Solution:} The point is that I want $\phi(x^p y^q) = y^q x^p$.  Given
\[ f = g_0 + g_1 y + g_2 y^2 + \dotsb + g_n y^n \in R[x][y], \]
let $m = \max \{\deg g_0, \deg g_1, \dotsc, \deg g_n \}$, and for each $i$ write
\[ g_i = a_{i0} + a_{i1} x + a_{i2} x^2 + \dotsb + a_{im} x^m \in R[x]. \]
I define
\[ \phi(f) = h_0 + h_1 x + h_2 x^2 + \dotsb + h_m x^m \in R[y][x], \]
where
\[ h_j = a_{0j} + a_{1j} y + a_{2j} y^2 + \dotsb + a_{nj} y^n \in R[y]. \]

\item Write down $\phi$ of your elements from part (a).

{\bf Solution:}
\begin{gather*}
(y^2 + 1) x^2 + (2y) x + (4y^2 + 3y + 1) \\
-y + (y^3 + 2)x + y x^2
\end{gather*}

\end{enumerate}

\newpage

\item Let $\phi\colon \R \to \R$ be a ring homomorphism.
\begin{enumerate}
\item Let $a \in \Z \subset \R$.  Show that $\phi(a) = a$.

{\bf Solution:} We have seen that $\phi(0) = 0$ and $\phi(1) = 1$.  Then
\[ \phi(2) = \phi(1+1) = \phi(1) + \phi(1) = 1 + 1 = 2, \]
and similarly $\phi(3) = 3$, $\phi(4) = 4$, and $\phi(a) = a$ for all $a > 0$.  (By induction if you like.)  If $a < 0$ then
\[ \phi(a) = \phi(-(-a)) = -\phi(-a) = -(-a) = a. \]

\item Let $a \in \Q \subset \R$.  Show that $\phi(a) = a$. \\
Hint: Write $a = p/q$, and consider $q \cdot \phi(a)$.

{\bf Solution:} Following the hint, we write $a = p/q$.  Then
\[ q  \cdot \phi(a) = \phi(q) \phi(a) = \phi(qa) = \phi(p) = p, \]
so $\phi(a) = p/q$ as desired.

\item Let $a \in \R$.  Show that if $a \ge 0$ then $\phi(a) \ge 0$. \\
Hint: Consider $\phi(\sqrt a)$.

{\bf Solution:} Following the hint, we observe that if $a \ge 0$ then there is a $b \in \R$ with $b^2 = a$.  Then
\[ \phi(a) = \phi(b^2) = \phi(b)^2 \ge 0. \]

\item Let $a, b \in \R$.  Show that if $a \le b$ then $\phi(a) \le \phi(b)$.

{\bf Solution:} If $a \le b$ then $b-a \ge 0$, so $\phi(b-a) \ge 0$ by the previous part, so $\phi(b) - \phi(a) \ge 0$, so $\phi(a) \le \phi(b)$.

\item Now let $a \in \R$ be arbitrary.  Show that $\phi(a) = a$. \\
Hint: Consider $\{ b \in \Q : b \le a \}$ and/or $\{ b \in \Q : b \ge a \}$. \\
You can use facts from analysis without proof.

{\bf Solution:} We ignore the hint, and instead take the suggestion that I e-mailed to the group.

Suppose on the contrary that there is an $a \in \R$ with $\phi(a) \ne a$.  If $\phi(a) < a$, then by the density of the rationals we can choose $b \in \Q$ with $\phi(a) < b < a$.  But then $\phi(b) \le \phi(a)$, so
\[ \phi(a) < b = \phi(b) \le \phi(a), \]
so $\phi(a) < \phi(a)$ which is impossible.  If $a < \phi(a)$ then we get a similar contradiction.  Thus $\phi(a) = a$ for all $a \in \R$.

\item In contrast, show that the map $\phi\colon \C \to \C$ given by \\ $\phi(a+bi) = a-bi$ is a homomorphism.

{\bf Solution:} First, $\phi(1) = 1$.

Next,
\begin{align*}
\phi((a + bi) + (a' + b'i))
&= \phi((a+a') + (b+b')i) \\
&= (a+a') - (b+b')i \\
&= (a-bi) + (a'-b'i) \\
&= \phi(a + bi) + \phi(a' + b'i).
\end{align*}

Finally,
\begin{align*}
\phi((a + bi)(a' + b'i))
&= \phi((aa' - bb') + (ab' + ba')i) \\
&= (aa' - bb') - (ab' + ba')i \\
&= (a-bi)(a'-b'i) \\
&= \phi(a + bi) \phi(a' + b'i).
\end{align*}

\end{enumerate}

\end{enumerate}

\end{document}
