6.5 Comparisons of Field Elements

f = g
f < g

The equality operator = evaluates to true if the two field elements f and g are equal, and to false otherwise. The inequality operator < evaluates to true if the two field elements f and g are not equal, and to false otherwise. Note that any two field elements can be compared, even if they do not lie in compatible fields. In this case they cn, of course, never be equal. For each type of fields the equality of those field elements is given in the respective chapter.

Note that you can compare field elements with elements of other types; of course they are never equal.

f < g
f <= g
f g
f = g

The operators <, <=, , and = evaluate to true if the field element f is less than, less than or equal to, greater than, or greater than or equal to the field element g. For each type of fields the definition of the ordering of those field elements is given in the respective chapter. The ordering of field elements is as follows. Rationals are smallest, next are cyclotomics, followed by finite field elements.

Note that you can compare field elements with elements of other types; they are smaller than everything else.

Previous Up Top Next
Index

GAP 3.4.4
April 1997