Lesson 12 of 15

Ring Homomorphisms

Ring Homomorphisms

A ring homomorphism ϕ:RS\phi: R \to S is a function that preserves both operations:

ϕ(a+b)=ϕ(a)+ϕ(b)\phi(a + b) = \phi(a) + \phi(b) ϕ(ab)=ϕ(a)ϕ(b)\phi(a \cdot b) = \phi(a) \cdot \phi(b)

If RR and SS have unity, we also require ϕ(1R)=1S\phi(1_R) = 1_S.

The Natural Projection

The map ϕ:ZmZn\phi: \mathbb{Z}_m \to \mathbb{Z}_n defined by ϕ(a)=amodn\phi(a) = a \bmod n is a ring homomorphism whenever nn divides mm.

For example, ϕ:Z12Z4\phi: \mathbb{Z}_{12} \to \mathbb{Z}_4 with ϕ(a)=amod4\phi(a) = a \bmod 4:

  • ϕ(7+8)=ϕ(3)=3\phi(7 + 8) = \phi(3) = 3 and ϕ(7)+ϕ(8)=3+0=3\phi(7) + \phi(8) = 3 + 0 = 3 in Z4\mathbb{Z}_4
  • ϕ(35)=ϕ(3)=3\phi(3 \cdot 5) = \phi(3) = 3 and ϕ(3)ϕ(5)=31=3\phi(3) \cdot \phi(5) = 3 \cdot 1 = 3 in Z4\mathbb{Z}_4

Kernel of a Ring Homomorphism

ker(ϕ)={aR:ϕ(a)=0S}\ker(\phi) = \{a \in R : \phi(a) = 0_S\}

The kernel is always an ideal of RR. For ϕ:Z12Z4\phi: \mathbb{Z}_{12} \to \mathbb{Z}_4, the kernel is {0,4,8}\{0, 4, 8\}.

Image

im(ϕ)={ϕ(a):aR}\text{im}(\phi) = \{\phi(a) : a \in R\}

The image is a subring of SS.

Your Task

Implement is_ring_hom(phi, m, n) that checks if a function (given as a list) is a ring homomorphism from ZmZn\mathbb{Z}_m \to \mathbb{Z}_n, ring_kernel(phi, m) for the kernel, and ring_image(phi, m) for the image.

Pyodide loading...
Loading...
Click "Run" to execute your code.