17 Cyclotomic Numbers

GAP admits computations in abelian extension fields of the rational number field Q, that is fields with abelian Galois group over Q. These fields are subfields of cyclotomic fields Q(en) where en = e2pi/n is a primitive complex n--th root of unity. The elements of these fields are called cyclotomics.

Information concerning operations for fields of cyclotomics, for example certain integral bases, can be found in chapter Abelian Number Fields. For more general operations that take a field extension as a ---possibly optional--- argument, e.g., Trace or Coefficients, see Chapter Fields and division rings.

Sections

  1. Operations for Cyclotomics
  2. Infinity
  3. Comparisons of Cyclotomics
  4. ATLAS Irrationalities
  5. Galois Conjugacy of Cyclotomics
  6. Internally Represented Cyclotomics

17.1 Operations for Cyclotomics

  • E( n ) F

    E returns the primitive n-th root of unity en = e2pi/n. Cyclotomics are usually entered as sums of roots of unity, with rational coefficients, and irrational cyclotomics are displayed in the same way. (For special cyclotomics, see ATLAS irrationalities.)

    gap> E(9); E(9)^3; E(6); E(12) / 3;
    -E(9)^4-E(9)^7
    E(3)
    -E(3)^2
    -1/3*E(12)^7
    
    A particular basis is used to express cyclotomics, see Integral Bases for Abelian Number Fields; note that E(9) is not a basis element, as the above example shows.

  • Cyclotomics V

    is the field of all cyclotomics (in GAP).

    gap> E(9) in Cyclotomics; 37 in Cyclotomics; true in Cyclotomics;
    true
    true
    false
    

    As the cyclotomics are field elements the usual arithmetic operators +,-,* and / (and ^ to take powers by integers) are applicable. Note that ^ does not denote the conjugation of group elements, so it is not possible to explicitly construct groups of cyclotomics. (However, it is possible to compute the inverse and the multiplicative order of a nonzero cyclotomic.) Also, taking the k-th power of a cyclotomic is a Galois automorphism if and only if k is coprime to the conductor of the cyclotomic.

    gap> E(5) + E(3); (E(5) + E(5)^4) ^ 2; E(5) / E(3); E(5) * E(3);
    -E(15)^2-2*E(15)^8-E(15)^11-E(15)^13-E(15)^14
    -2*E(5)-E(5)^2-E(5)^3-2*E(5)^4
    E(15)^13
    E(15)^8
    gap> Order( E(5) ); Order( 1+E(5) );
    5
    infinity
    

  • IsCyclotomic( obj ) C
  • IsCyc( obj ) C

    Every object in the family CyclotomicsFamily lies in the category IsCyclotomic. This covers integers, rationals, proper cyclotomics, the object infinity (see Infinity), and unknowns (see Chapter Unknowns). All these objects except infinity and unknowns lie also in the category IsCyc, infinity lies in (and can be detected from) the category IsInfinity, and unknowns lie in IsUnknown.

    gap> IsCyclotomic(0); IsCyclotomic(1/2*E(3)); IsCyclotomic( infinity );
    true
    true
    true
    gap> IsCyc(0); IsCyc(1/2*E(3)); IsCyc( infinity );
    true
    true
    false
    

  • IsIntegralCyclotomic( obj ) P

    A cyclotomic is called integral or a cyclotomic integer if all coefficients of its minimal polynomial over the rationals are integers. Since the underlying basis of the external representation of cyclotomics is an integral basis (see Integral Bases for Abelian Number Fields), the subring of cyclotomic integers in a cyclotomic field is formed by those cyclotomics for which the external representation is a list of integers. For example, square roots of integers are cyclotomic integers (see ATLAS irrationalities), any root of unity is a cyclotomic integer, character values are always cyclotomic integers, but all rationals which are not integers are not cyclotomic integers.

    gap> r:= ER( 5 );            # The square root of 5 is a cyclotomic
    E(5)-E(5)^2-E(5)^3+E(5)^4    # integer, it has integral coefficients.
    gap> IsIntegralCyclotomic( r );
    true
    gap> r2:= 1/2 * r;           # This is not a cyclotomic integer,
    1/2*E(5)-1/2*E(5)^2-1/2*E(5)^3+1/2*E(5)^4
    gap> IsIntegralCyclotomic( r2 );
    false
    gap> r3:= 1/2 * r - 1/2;  # but this is one.
    E(5)+E(5)^4
    gap> IsIntegralCyclotomic( r3 );
    true
    

    The operation IntindexInt!for cyclotomics can be used to find a cyclotomic integer near to an arbitrary cyclotomic. For rationals, Int returns the largest integer smaller or equal to the argument.

    gap> Int( E(5)+1/2*E(5)^2 ); Int( 2/3*E(7)+3/2*E(4) );
    E(5)
    E(4)
    

    The operation StringindexString!for cyclotomics returns for a cyclotomic a string corresponding to the way the cyclotomic is printed by ViewObj and PrintObj.

    gap> String( E(5)+1/2*E(5)^2 ); String( 17/3 );
    "E(5)+1/2*E(5)^2"
    "17/3"
    

  • Conductor( cyc ) A
  • Conductor( C ) A

    For an element cyc of a cyclotomic field, Conductor returns the smallest integer n such that cyc is contained in the n-th cyclotomic field. For a collection C of cyclotomics (for example a dense list of cyclotomics or a field of cyclotomics), Conductor returns the smallest integer n such that all elements of C are contained in the n-th cyclotomic field.

    gap> Conductor( 0 ); Conductor( E(10) ); Conductor( E(12) );
    1
    5
    12
    

  • RoundCyc( cyc ) O

    is a cyclotomic integer z (see IsIntegralCyclotomic) near to the cyclotomic cyc in the sense that the i-th coefficient in the external representation (see CoeffsCyc) of z is Int( c+1/2 ) where c is the i-th coefficient in the external representation of cyc. Expressed in terms of the Zumbroich basis (see Integral Bases for Abelian Number Fields), the coefficients of cyc w.r.t. this basis are rounded.

    gap> RoundCyc( E(5)+1/2*E(5)^2 ); RoundCyc( 2/3*E(7)+3/2*E(4) );
    E(5)+E(5)^2
    -2*E(28)^3+E(28)^4-2*E(28)^11-2*E(28)^15-2*E(28)^19-2*E(28)^23
     -2*E(28)^27
    

  • CoeffsCyc( cyc, N ) F

    Let cyc be a cyclotomic with conductor n. If N is not a multiple of n then CoeffsCyc returns fail because cyc cannot be expressed in terms of N-th roots of unity. Otherwise CoeffsCyc returns a list of length N with entry at position j equal to the coefficient of e2 pi (j-1)/N if this root belongs to the N-th Zumbroich basis (see Integral Bases for Abelian Number Fields), and equal to zero otherwise. So we have cyc = CoeffsCyc(cyc,N) * List( [1..N], j -> E(N)^(j-1) ).

    gap> cyc:= E(5)+E(5)^2;  
    E(5)+E(5)^2
    gap> CoeffsCyc( cyc, 5 );  CoeffsCyc( cyc, 15 );  CoeffsCyc( cyc, 7 ); 
    [ 0, 1, 1, 0, 0 ]
    [ 0, -1, 0, 0, 0, 0, 0, 0, -1, 0, 0, -1, 0, -1, 0 ]
    fail
    

  • ExtRepOfObj(cyc)

    gap> ExtRepOfObj( E(5) ); CoeffsCyc( E(5), 15 );
    [ 0, 1, 0, 0, 0 ]
    [ 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, -1, 0 ]
    gap> CoeffsCyc( 1+E(3), 9 ); CoeffsCyc( E(5), 7 );
    [ 0, 0, 0, 0, 0, 0, -1, 0, 0 ]
    fail
    

  • DescriptionOfRootOfUnity( root ) F

    Given a cyclotomic root that is known to be a root of unity (this is not checked), DescriptionOfRootOfUnity returns a list [ n, e ] of coprime positive integers such that root = E(n)e holds.

    gap> E(9);  DescriptionOfRootOfUnity( E(9) );
    -E(9)^4-E(9)^7
    [ 9, 1 ]
    gap> DescriptionOfRootOfUnity( -E(3) );
    [ 6, 5 ]
    

  • IsGaussInt( x ) F

    IsGaussInt returns true if the object x is a Gaussian integer and false otherwise. Gaussian integers are of the form a + b*E(4), where a and b are integers.

  • IsGaussRat( x ) F

    IsGaussRat returns true if the object x is a Gaussian rational and false otherwise. Gaussian rationals are of the form a + b*E(4), where a and b are rationals.

    17.2 Infinity

  • IsInfinity( obj ) C
  • infinity V

    infinity is a special GAP object that lies in CyclotomicsFamily. It is larger than all other objects in this family. infinity is mainly used as return value of operations such as Size and Dimension for infinite resp. infinite dimensional domains.

    Note that no arithmetic operations are provided for infinity, in particular there is no problem to define what 0 * infinity or infinity - infinity means.

    Often it is useful to distinguish infinity from ``proper'' cyclotomics. For that, infinity lies in the category IsInfinity but not in IsCyc, and the other cyclotomics lie in the category IsCyc but not in IsInfinity.

    gap> s:= Size( Rationals );
    infinity
    gap> s = infinity; IsCyclotomic( s ); IsCyc( s ); IsInfinity( s );
    true
    true
    false
    true
    gap> s in Rationals; s > 17;
    false
    true
    gap> Set( [ s, 2, s, E(17), s, 19 ] );
    [ 2, 19, E(17), infinity ]
    

    17.3 Comparisons of Cyclotomics

    To compare cyclotomics, the operators <, <=, =, >=, > and <> can be used, the result will be true if the first operand is smaller, smaller or equal, equal, larger or equal, larger, or inequal, respectively, and false otherwise.

    Cyclotomics are ordered as follows: The relation between rationals is the natural one, rationals are smaller than irrational cyclotomics, and infinity is the largest cyclotomic. For two irrational cyclotomics with different conductors, the one with smaller conductor is regarded as smaller. Two irrational cyclotomics with same conductor are compared via their external representation.

    gap> E(5) < E(6);     # the latter value has conductor 3
    false
    gap> E(3) < E(3)^2;    # both have conductor 3, compare the ext. repr.
    false
    gap> 3 < E(3); E(5) < E(7);
    true
    true
    

    17.4 ATLAS Irrationalities

  • EB( n ) F
  • EC( n ) F
  • ED( n ) F
  • EE( n ) F
  • EF( n ) F
  • EG( n ) F
  • EH( n ) F

    For N a positive integer, let z = E(N ) = e2 pi / N. The following so-called atomic irrationalities (see Chapter 7, Section 10 of CCN85) can be entered using functions. (Note that the values are not necessary irrational.)

    EB(N )
    =
    bN
    =
    1
    2
    N-1
    å
    j = 1 
    zj2
    (N º 1 mod 2)
    EC(N )
    =
    cN
    =
    1
    3
    N-1
    å
    j = 1 
    zj3
    (N º 1 mod 3)
    ED(N )
    =
    dN
    =
    1
    4
    N-1
    å
    j = 1 
    zj4
    (N º 1 mod 4)
    EE(N )
    =
    eN
    =
    1
    5
    N-1
    å
    j = 1 
    zj5
    (N º 1 mod 5)
    EF(N )
    =
    fN
    =
    1
    6
    N-1
    å
    j = 1 
    zj6
    (N º 1 mod 6)
    EG(N )
    =
    gN
    =
    1
    7
    N-1
    å
    j = 1 
    zj7
    (N º 1 mod 7)
    EH(N )
    =
    hN
    =
    1
    8
    N-1
    å
    j = 1 
    zj8
    (N º 1 mod 8)

    (Note that in cN, ¼, hN, N must be a prime.)

  • EI( n ) F
  • ER( n ) F
  • Sqrt( rat ) F

    ER(N )
    =
    ÖN
    EI(N )
    =
    i ÖN
    =
      __
    Ö-N
     

    A probably more usual name for ER is Sqrt, it can be used to compute the positive square root of any rational number rat.

    From a theorem of Gauss we know that

    bN = ì
    ï
    ï
    í
    ï
    ï
    î
    1
    2
    (-1+ÖN)
    if
    N º 1
    mod 4
    1
    2
    (-1+iÖN)
    if
    N º -1
    mod 4
    ,
    so ÖN can be computed from bN. If N is a negative integer then ER(N) = EI(-N).

  • EY( n[, d] ) F
  • EX( n[, d] ) F
  • EW( n[, d] ) F
  • EV( n[, d] ) F
  • EU( n[, d] ) F
  • ET( n[, d] ) F
  • ES( n[, d] ) F

    For given N, let nk = nk(N) be the first integer with multiplicative order exactly k modulo N, chosen in the order of preference

    1, -1, 2, -2, 3, -3, 4, -4, ¼.

    We define

    EY(N )
    =
    yn
    =
    z+zn
    (n = n2)
    EX(N )
    =
    xn
    =
    z+zn+zn2
    (n = n3)
    EW(N )
    =
    wn
    =
    z+zn+zn2+zn3
    (n = n4)
    EV(N )
    =
    vn
    =
    z+zn+zn2+zn3+zn4
    (n = n5)
    EU(N )
    =
    un
    =
    z+zn+zn2+¼+zn5
    (n = n6)
    ET(N )
    =
    tn
    =
    z+zn+zn2+¼+zn6
    (n = n7)
    ES(N )
    =
    sn
    =
    z+zn+zn2+¼+zn7
    (n = n8)

  • EM( n[, d] ) F
  • EL( n[, d] ) F
  • EK( n[, d] ) F
  • EJ( n[, d] ) F

    EM(N )
    =
    mn
    =
    z-zn
    (n = n2)
    EL(N )
    =
    ln
    =
    z-zn+zn2-zn3
    (n = n4)
    EK(N )
    =
    kn
    =
    z-zn+¼-zn5
    (n = n6)
    EJ(N )
    =
    jn
    =
    z-zn+¼-zn7
    (n = n8)

  • NK( n, k, d ) F

    Let nk(d) = nk(d)(N) be the d+1-th integer with multiplicative order exactly k modulo N, chosen in the order of preference defined above; we write nk = nk(0),nk¢ = nk(1), nk¢¢ = nk(2) and so on. These values can be computed as NK(N,k,d) = nk(d)(N); if there is no integer with the required multiplicative order, NK returns fail.

    The algebraic numbers

    yN¢ = yN(1),yN¢¢ = yN(2),¼, xN¢,xN¢¢,¼, jN¢,jN¢¢,¼
    are obtained on replacing nk in the above definitions by nk¢,nk¢¢,¼; they can be entered as

    EY(N ,d )
    =
    yN(d)
    EX(N ,d )
    =
    xN(d)
    :
    EJ(N ,d )
    =
    jn(d)

    gap> EW(16,3); EW(17,2); ER(3); EI(3); EY(5); EB(9);
    0
    E(17)+E(17)^4+E(17)^13+E(17)^16
    -E(12)^7+E(12)^11
    E(3)-E(3)^2
    E(5)+E(5)^4
    1
    

    17.5 Galois Conjugacy of Cyclotomics

  • GaloisCyc( cyc, k ) O
  • GaloisCyc( list, k ) O

    For a cyclotomic cyc and an integer k, GaloisCyc returns the cyclotomic obtained by raising the roots of unity in the Zumbroich basis representation of cyc to the k-th power. If k is coprime to the integer n, GaloisCyc( ., k ) acts as a Galois automorphism of the n-th cyclotomic field (see GaloisGroup for Number Fields); to get the Galois automorphisms themselves, use GaloisGroup (see GaloisGroup.field).

    The complex conjugate of cyc is GaloisCyc( cyc, -1 ), which can also be computed using ComplexConjugate (see ComplexConjugate).

    For a list or matrix list of cyclotomics, GaloisCyc returns the list obtained by applying GaloisCyc to the entries of list.

    gap> GaloisCyc( E(5) + E(5)^4, 2 );
    E(5)^2+E(5)^3
    gap> GaloisCyc( E(5), -1 );           # the complex conjugate
    E(5)^4
    gap> GaloisCyc( E(5) + E(5)^4, -1 );  # this value is real
    E(5)+E(5)^4
    gap> GaloisCyc( E(15) + E(15)^4, 3 );
    E(5)+E(5)^4
    gap> ComplexConjugate( E(7) );
    E(7)^6
    

  • StarCyc( cyc ) F

    If the cyclotomic cyc is an irrational element of a quadratic extension of the rationals then StarCyc returns the unique Galois conjugate of cyc that is different from cyc, otherwise fail is returned. In the first case, the return value is often called cyc * (see Printing Character Tables).

    gap> StarCyc( EB(5) ); StarCyc( E(5) );
    E(5)^2+E(5)^3
    fail
    

  • Quadratic( cyc ) F

    Let cyc be a cyclotomic that lies in a quadratic extension field of the rationals. In this case, Quadratic calculates the representation cyc = ( a + b Ö{ root } ) / d and a (not necessarily shortest) representation ATLAS in terms of a combination of the ATLAS irrationalities broot, iroot, and rroot, and returns a record with the components a, b, root, d, ATLAS, and display, the latter being a string that expresses the cyc in GAP notation, corresponding to the ATLAS component.

    If cyc does not lie in a quadratic extension of the rationals then fail is returned.

    If the denominator d is 2, necessarily root is congruent to 1 mod 4, and rn, in are not possible; cyc = x + y * EB( root ) with y = b, x = ( a + b ) / 2.

    If the denominator d is 1, we have the possibilities in for root < -1, a + b * i for root = -1, a + b * rn for root > 0. Furthermore if root is congruent to 1 modulo 4, also cyc = (a+b) + 2 * b * EB( root ) is possible; the shortest string of these is taken as the value for the component ATLAS.

    gap> Quadratic( EB(5) ); Quadratic( EB(27) );
    rec(
      a := -1,
      b := 1,
      root := 5,
      d := 2,
      ATLAS := "b5",
      display := "(-1+ER(5))/2" )
    rec(
      a := -1,
      b := 3,
      root := -3,
      d := 2,
      ATLAS := "1+3b3",
      display := "(-1+3*ER(-3))/2" )
    gap> Quadratic(0); Quadratic( E(5) );
    rec(
      a := 0,
      b := 0,
      root := 1,
      d := 1,
      ATLAS := "0",
      display := "0" )
    fail
    

  • GaloisMat( mat ) A

    Let mat be a matrix of cyclotomics. GaloisMat calculates the complete orbits under the operation of the Galois group of the (irrational) entries of mat, and the permutations of rows corresponding to the generators of the Galois group.

    If some rows of mat are identical, only the first one is considered for the permutations, and a warning will be printed.

    GaloisMat returns a record with components mat, galoisfams, and generators

    mat:
    a list with initial segment being the rows of mat (not shallow copies of these rows); the list consists of full orbits under the action of the Galois group of the entries of mat defined above. The last rows in the list are those not contained in mat but must be added in order to complete the orbits; so if the orbits were already complete, mat and mat have identical rows.

    galoisfams:
    a list that has the same length as the mat component, its entries are either 1, 0, -1, or lists. galoisfams[i] = 1 means that mat[i] consists of rationals, i.e. [ mat[i] ] forms an orbit; galoisfams[i] = -1 means that mat[i] contains unknowns (see Chapter Unknowns); in this case [ mat[i] ] is regarded as an orbit, too, even if mat[i] contains irrational entries; if galoisfams[i] = [ l1, l2 ] is a list then mat[i] is the first element of its orbit in mat, l1 is the list of positions of rows that form the orbit, and l2 is the list of corresponding Galois automorphisms (as exponents, not as functions), so we have mat[ l1[j] ][k] = GaloisCyc( mat[i][k], l2[j] ); galoisfams[i] = 0 means that mat[i] is an element of a nontrivial orbit but not the first element of it.

    generators:
    a list of permutations generating the permutation group corresponding to the action of the Galois group on the rows of mat.

    gap> GaloisMat( [ [ E(3), E(4) ] ] );
    rec(
      mat := [ [ E(3), E(4) ], [ E(3), -E(4) ], [ E(3)^2, E(4) ],
          [ E(3)^2, -E(4) ] ],
      galoisfams := [ [ [ 1, 2, 3, 4 ], [ 1, 7, 5, 11 ] ], 0, 0, 0 ],
      generators := [ (1,2)(3,4), (1,3)(2,4) ] )
    gap> GaloisMat( [ [ 1, 1, 1 ], [ 1, E(3), E(3)^2 ] ] );
    rec(
      mat := [ [ 1, 1, 1 ], [ 1, E(3), E(3)^2 ], [ 1, E(3)^2, E(3) ] ],
      galoisfams := [ 1, [ [ 2, 3 ], [ 1, 2 ] ], 0 ],
      generators := [ (2,3) ] )
    

  • RationalizedMat( mat ) A

    returns the list of rationalized rows of mat, which must be a matrix of cyclotomics. This is the set of sums over orbits under the action of the Galois group of the entries of mat (see GaloisMat), so the operation may be viewed as a kind of trace on the rows.

    Note that no two rows of mat should be equal.

    gap> mat:=List(Irr(CharacterTable( "A5" )),ValuesOfClassFunction);
    [ [ 1, 1, 1, 1, 1 ], [ 3, -1, 0, -E(5)-E(5)^4, -E(5)^2-E(5)^3 ],
      [ 3, -1, 0, -E(5)^2-E(5)^3, -E(5)-E(5)^4 ], [ 4, 0, 1, -1, -1 ],
      [ 5, 1, -1, 0, 0 ] ]
    gap> RationalizedMat( mat );
    [ [ 1, 1, 1, 1, 1 ], [ 6, -2, 0, 1, 1 ], [ 4, 0, 1, -1, -1 ],
      [ 5, 1, -1, 0, 0 ] ]
    

    17.6 Internally Represented Cyclotomics

    The implementation of an internally represented cyclotomic is based on a list of length equal to its conductor. This means that the internal representation of a cyclotomic does not refer to the smallest number field but the smallest cyclotomic field containing it. The reason for this is the wish to reflect the natural embedding of two cyclotomic fields into a larger one that contains both. With such embeddings, it is easy to construct the sum or the product of two arbitrary cyclotomics as an element of a cyclotomic field.

    The disadvantage of this approach is that the arithmetical operations are quite expensive, so the use of internally represented cyclotomics is not recommended for doing arithmetics over number fields, such as calculations with matrices of cyclotomics. But internally represented cyclotomics are good enough for dealing with irrationalities in character tables (see chapter Character Tables).

    For the representation of cyclotomics one has to recall that the n-th cyclotomic field Q(en) is a vector space of dimension j(n) over the rationals where j denotes Euler's phi-function (see Phi).

    A special integral basis of cyclotomic fields is chosen that allows one to easily convert arbitrary sums of roots of unity into the basis, as well as to convert a cyclotomic represented w.r.t. the basis into the smallest possible cyclotomic field. This basis is accessible in GAP, see Integral Bases for Abelian Number Fields for more information and references.

    Note that the set of all n-th roots of unity is linearly dependent for n > 1, so multiplication is not the multiplication of the group ring Qáen ñ; given a Q-basis of Q(en) the result of the multiplication (computed as multiplication of polynomials in en, using (en)n = 1) will be converted to the basis.

    gap> E(5) * E(5)^2; ( E(5) + E(5)^4 ) * E(5)^2;
    E(5)^3
    E(5)+E(5)^3
    gap> ( E(5) + E(5)^4 ) * E(5);
    -E(5)-E(5)^3-E(5)^4
    

    An internally represented cyclotomic is always represented in the smallest cyclotomic field it is contained in. The internal coefficients list coincides with the external representation returned by ExtRepOfObj.

    Since the conductor of internally represented cyclotomics must be in the category IsSmallIntRep, the biggest possible (though not very useful) conductor is 65535. So the maximal cyclotomic field implemented in GAP is not really the field Qab.

    [Top] [Previous] [Up] [Next] [Index]

    GAP 4 manual
    July 1999