A Microworld for Learning Abstract Algebra

The authors describe their package for introducting students to the concepts of groups, rings, fields and morphisms.

by Kenneth Levasseur and Al Hibbard

AbstractAlgebra is a collection of Mathematica packages that enable one to work with concepts that are typically introduced in an undergraduate abstract algebra course. These topics include groups, rings, fields, and morphisms. A particular emphasis has been placed on creating an environment in which the packages can be used for pedagogical purposes. To this end, in addition to providing a computation, many functions have a Textual mode (providing an explanation of the resulting computation) and a Visual mode (providing a graphic to illustrate the computation). There are three basic Mathematica data structures used in AbstractAlgebra: the Groupoid, Ringoid, and Morphoid. These are generalizations of groups, rings and morphisms.

Our objective in this paper is to give an overview of the capabilities of the packages and our vision of how best to use them. The packages themselves, and much more information on this project, are available at http://www.central.edu/eaam.html.

The Basic Structures

Currently, the packages are capable of handling many of the types of objects encountered in a first-year undergraduate abstract algebra course. This includes working with (finite) groups, rings, fields, morphisms, and functions related to each of these objects. There are a large number of built-in groups. Among the standard groups are (Subscript[ℤ, n]), (Subscript[U, n]) (units of the ring (Subscript[ℤ, n])), (Subscript[S, n]), (Subscript[D, n]), as well as direct products and quotients of these. The rings include (Subscript[ℤ, n]), Boolean rings, and lattice rings, as well as polynomial, matrix, and function extension rings. One can also create functions between groups or rings and investigate whether they are morphisms.

The AbstractAlgebra packages are loaded with a single expression:

Needs["AbstractAlgebra`Master`"]

The functions FormGroupoid, FormRingoid, and FormMorphoid are the basic tools for forming the objects in these packages. For example, the multiplicative group of the complex fourth roots of unity may be formed by evaluating

G = FormGroupoid[{1, -1, I, -I}, (#1 #2) &]

This and many other standard groups, rings, and morphisms are already defined within the packages. For example, the group above may also be formed by evaluating RootsOfUnity[4].

Anyone who has taught abstract algebra will be familiar with the conundrum of distinguishing between the group and ring of integers modulo n. Normally, when the expression Z[n] is evaluated with a specific value for n, the result will be the group.

Z[12]

The function SwitchStructureTo may be used to change this behavior.

SwitchStructureTo[Ring];
Z[12]

One may also use the functions ZG and ZR to explicitly specify the group and ring, respectively.

{ZG[2], ZR[2]}

Direct products of groups or rings may be formed.

R = DirectProduct[ZR[3], ZR[4]]

The expression that defines an operation in a structure is often suppressed, but may be examined upon request.

Multiplication[R]

A typical introductory example of an isomorphism may be the one from (Subscript[ℤ, 12]) into \(TraditionalForm\`ℤ\_3×ℤ\_4\)where x, a residue modulo 12, is mapped to the pair (x mod 3,  x mod 4). This can done in Mathematica with the pure function {Mod[#,3],Mod[#,4]}&, where # represents the “input” and & indicates that the expression represents a function.

ϕ = 
      FormMorphoid[{Mod[#, 3], Mod[#, 4]} &,  ZR[12],  R]

Morphoids such as ϕ act as functions, but they also contain the structural information that is needed do further analysis.

ϕ[8]

MorphismQ[ϕ]

Kernel[ϕ]

Additionally, there are extensions to rings: polynomials, matrices and functions. These are somewhat different. Since the extension rings are either very large or infinite, they are treated differently and are not Ringoids.

RandomElement[PolynomialsOver[ZR[5]], 5]

RandomMatrix[ZR[5], 3, MatrixType -> GL] // MatrixForm

RandomElement[FunctionsOver[ZR[5]]]

Properties and Modes

Groups and rings can have a bewildering variety of properties to the typical undergraduate who is first learning the subject. One of the initial motivations of the packages was to provide a “microworld” in which these students can examine many examples and get a feel for the properties in a variety of settings. Virtually every situation that is encountered in an introductory course can also be found by exploring the packages. We will illustrate just a few of these here.

The Abelian Property

The distinction between abelian and nonabelian groups is encountered early in a typical curriculum.

{AbelianQ[ZG[6]], AbelianQ[S[3]]}

To those of us who have worked with the subject for some time, these boolean results are crystal clear, but students often need reinforcement. The Mode option is active for many of the AbstractAlgebra functions. The default value of Mode is Computational, which produces only the desired final result. Additional values, such as Visual and Textual, add side effects that provide more information related to the final computational result.

AbelianQ[S[3], Mode -> Visual]

Zero Divisors of a Ring

A student who is just learning the definition of zero divisor is unlikely to benefit from just computing the value of ZeroDivisors[R] for various values of R, but the Textual mode may be useful.

ZeroDivisors[ZR[12], Mode -> Textual]

In this case, the Visual mode complements the Textual mode.

ZeroDivisors[ZR[12], Mode -> Visual]

Cayley Tables

Many of the visual aides are built on the CayleyTable(s) output for the structures. The tables themselves can be generated as Mathematica arrays for computational work or as graphical aides. In the following, both results are produced. Removing the Mode option would suppress the graphics, while a semicolon at the end the expression would suppress the computational result.

CayleyTable[S[3], Mode -> Visual]

Normal Subgroups

Normal subgroups are a vital topic and the illustration of nonnormal subgroups is made easy by the packages. The dihedral groups are a convenient family to illustrate this topic.

DihedralGroup[5, Mode -> Visual]

The order of the reflection element is two and so it generates a subgroup of that order.

SubgroupQ[H = {1, Ref}, Dihedral[5]]

In order for H to be normal, its left and right cosets must be identical. That this is not true can be verified by examining these cosets.

LeftCosets[Dihedral[5], H]

RightCosets[Dihedral[5], H]

The Visual mode of either of the cosets functions provides an even more striking reason why H is not normal. Notice how the result of operating on elements with two specific color codings does not provide a consistent coloring.

LeftCosets[Dihedral[5], H, Mode -> Visual]

This contrasts with the result for a subgroup of order two in a different dihedral group.

LeftCosets[Dihedral[4], {1, (Rot^2)}, Mode -> Visual]

Of course, the simple boolean result, indicating whether a subgroup is normal, is also available for those of us who want to just compute.

NormalQ[{1, Ref}, Dihedral[5]]

The Morphism Property

Recall that ϕ was defined above as a morphism from the ring (Subscript[ℤ, 12]) into the direct product \(TraditionalForm\`ℤ\_3×ℤ\_4\). The function on which the Morphoid is based can be viewed.

VisualizeMorphoid[ϕ];

A visualization of the morphism property uses what should be a familiar diagram to most instructors of the course. Note that for rings, there are two diagrams, one for addition and one for multiplication.

PreservesQ[ϕ,  {8, 10},  Mode  ->  Visual]

Explorations & Extensions of the Packages

Further extensions of the AbstractAlgebra packages are encouraged. The generality of their design makes it possible to implement different pedagogical ideas and make use of Mathematica system improvements.

Pascal-like Triangles

Kathleen Shannon and Michael Bardzell (both at Salisbury State University) have explored “Pascal’s Triangle-like” configurations of group elements. Given (Subscript[g, 1]) and (Subscript[g, 2]) in a group, a triangular array T is defined by (Subscript[T, k, 0]) =  (Subscript[g, 1]) for all k ≥ 0, (Subscript[T, k, k]) = (Subscript[g, 2])for all k > 0 and (Subscript[T, j, k]) = 
        (Subscript[T, j - 1, k - 1])* (Subscript[T, j - 1, k]) for 0 < j < k. For G = (Subscript[ℤ, n]) and (Subscript[g, 1]) = (Subscript[g, 2]) =  1, this produces the mod n residues of the classical Pascal’s triangle. For other groups (particularly nonabelian groups) the arrays can be color coded and the patterns motivate a variety of questions. These figures can be produced quite easily with the AbstractAlgebra packages.

Pascal[1, 1, Z[5], 6]//TableForm

Pascal[{1, 3, 2}, {2, 3, 1}, S[3], 25, 
        Mode -> Visual];

The definition of Pascal is available in a separate notebook at http://www.central.edu/homepages/hibbarda/EAAM/interesting.html, but is being added to the next release of AbstractAlgebra.

The Interplay Between Types of Structures

One shortcoming of software that concentrates on only groups or rings is that it isn’t easy to explore the interplay between two types of structures. The AbstractAlgebra packages make this interplay possible.

For example, we start with a quotient ring of polynomials over the integer modulo 3.

P = PolynomialsOver[ZR[3]];
p = 
      Poly[ZR[3], 2 + x + (x^2), 
        PowersIncrease -> RightToLeft]

Notice that since this quadratic polynomial has no roots in the base ring, it is irreducible.

Map[PolynomialEvaluation[P, p, #] &, Elements[ZR[3]]]

We know that the ring of polynomials modulo p must be a field.

F = QuotientRing[ZR[3], p]

Since F is a field, the nonzero elements form a multiplicative group.

nonzeros = Rest[Elements[F]];
G = 
      FormGroupoid[nonzeros, Multiplication[F], 
        GroupoidName -> "G"]

Since G is cyclic, we can generate its complete automorphism group.

autos = AutomorphismGroup[G]

We might now ask what is special about the four elements x, 1 + x, 2  x, and 2 + 2  x. The following evaluations of these elements in the extension gives us a hint.

Map[
      EvaluationInExtension[F,  p,  #] &, {Poly[ZR[3], x], 
        Poly[ZR[3], 1 + x], Poly[ZR[3], 2  x], 
        Poly[ZR[3], 2 + 2  x]}]

The theory tells us that the two elements that are not roots of p are roots of the other irreducible quadratic polynomial over the integers modulo 3.

q = Poly[ZR[3], 2 + 2  x + (x^2)]
Map[PolynomialEvaluation[P, q, #] &, Elements[ZR[3]]]

Map[
      EvaluationInExtension[F,  q,  #] &, {Poly[ZR[3], x], 
        Poly[ZR[3], 1 + x], Poly[ZR[3], 2  x], 
        Poly[ZR[3], 2 + 2  x]}]

In addition to working with rings and fields, further structures such as vector spaces or boolean algebras could easily be constructed based on the current packages.

Palettes

Although the packages were initially developed with version 2.2, system improvements initiated in version 3.0, such as buttons and palettes, have been integrated into the project. A wide variety of palettes have been designed to facilitate the use of the packages. Palettes that do specialized calculations or to build morphisms are built “on the fly.” Here is the main palette, through which all others can be found.

By clicking on the Groupoids button above, the following palette is brought forth.

Similarly, by choosing Ring functions we have the following:

Another particularly interesting palette is one that allows for the creation of numerous group or ring calculators. By specifying the group or ring, one can either look at the properties of the elements (or of the structure as a whole) or create a calculator for doing computations within the structure. This can be obtained by clicking on the second to last button in the main AbstractAlgebra palette.

Labs

In addition to a free-wheeling approach to learning though exploration, we have provided a guided format to students through a collection of labs. These labs are available in [1]. They have been used in a variety of settings. They were initially developed and tested in traditional courses with a computer lab component. They have also been used in an internet course in which the labs make up roughly half of the assigned work, with “traditional” kinds of problems being the remaining work.

Some of the features of the packages that have not been described thus far are apparent from a list of summaries of the labs. This can be found at http://www.central.edu/homepages/hibbarda/EAAM/GroupLabsEAAM.html.

Limitations & Prospects

The original design of the packages as pedagogical tools mandated that we work not only with properties of structures but with the elements of the structures themselves. For example, the associativity property is based on an equation that must be true for all triples of elements, and we wanted to work from this “first principle” as much as possible. The idea was for students to see the whole structure and also its parts, as opposed to just a database of facts. Out of necessity, this forced us to limit the size of the structures with which we work. A natural question would be at what point when looking at increasingly large or complex systems does one start to run out of memory or time? Certainly it is not difficult to reach this point, but there are seemingly endless possibilities that are within the range of computability. Describing the boundary between feasible and nonfeasible is difficult to pin down even for a specific computer since it depends on what you try to do.

The original package that worked only with groups had a groupoid consisting of two arguments, a list of elements, and its Cayley table. The Cayley table was replaced with a pure function representing the binary operation. This resulted in large savings in space, sometimes at the expense of speed. A similar approach could be taken with the domain of a structure, replacing a list of elements with a function that has the potential to generate the elements.

References

[1] Allen C. Hibbard and Kenneth M. Levasseur, Exploring Abstract Algebra with Mathematica, Springer/TELOS: New York, 1999.

[2] Levasseur, K., "A Microworld for Elementary Group Theory", Mathematica in Education, 3 (Fall, 1994), pp. 5-10.

[3] Kathleen Shannon and Michael Bardzell (both at Salisbury State University), Group-theoretic Pascal’s Triangle, http://faculty.ssu.edu/~kmshanno/pascal/

About the authors

Professor, Department of Mathematical Sciences, 
University of Massachusetts Lowell 
Lowell, MA 01854 
Office: Olsen 211 
email: Kenneth_Levasseur@uml.edu 
Phone 978-934-2414

Allen C. Hibbard
Department of Mathematics and Computer Science
Central College
Pella, IA 50219
hibbarda@central.edu
641-628-5133 (office)
641-628-5316 (fax)

Electronic Subscriptions

Included in the distribution for each electronic subscription is the file Lavaseur93.nb containing Mathematica code for the material described in this article.