A ring R is represented by a record with the following entries.
isDomain:true.
isRing:true.
isCommutativeRing:true if the multiplication is known to be commutative,
false if the multiplication is known to be noncommutative, and
unbound otherwise.
isIntegralRing:true if R is known to be a commutative domain with 1
without zero divisor, false if R is known to lack one of
these properties, and unbound otherwise.
isUniqueFactorizationRing:true if R is known to be a domain with unique
factorization into primes, false if R is known to have a
nonunique factorization, and unbound otherwise.
isEuclideanRing:true if R is known to be a Euclidean domain, false if it
is known not to be a Euclidean domain, and unbound otherwise.
zero:
units:
size:
one:
integralBase:
As an example of a ring record, here is the definition of the ring record
Integers.
rec(# category components isDomain := true, isRing := true,
# identity components generators := [ 1 ], zero := 0, one := 1, name := "Integers",
# knowledge components size := "infinity", isFinite := false, isCommutativeRing := true, isIntegralRing := true, isUniqueFactorizationRing := true, isEuclideanRing := true, units := [ -1, 1 ],
# operations record operations := rec( ... IsPrime := function ( Integers, n ) return IsPrimeInt( n ); end, ... 'mod' := function ( Integers, n, m ) return n mod m; end, ... ) )
GAP 3.4.4