Package sage :: Package algebras :: Module quatalg
[show private | hide private]
[frames | no frames]

Module sage.algebras.quatalg

Quaternion algebras:

    WORK IN PROGRESS!!!!  April 30, 2005  - William Stein -

Classes
Algebra  
Algebra_QQ  
Ideal  
Ideal_QQ  
Lattice  
Lattice_QQ  
Order  
Order_QQ  

Function Summary
  QuaternionAlgebra(K, a, b, c)
Returns the quaternion algebra over the field K with generators i and j and the following relations: i^2 = a j^2 = b i*j + j*i = c A third generator is set to k = i*j.
  QuaternionAlgebraRamifiedAt(N)
  QuaternionAlgebraWithDiscs(D1, D2, T)
The quaternion algebra over Q generated by i and j, where Z[i] and Z[j] are quadratic suborders of discriminant D_1 and D_2, respectively, and Z[ij - ji] is a quadratic suborder of discriminant D_3 = D_1 D_2 - T^2.
  QuaternionOrder_RamifiedAt(N, M)
  QuaternionOrderWithDiss(D1, D2, T)

Variable Summary
RationalField QQ = Rational Field
IntegerRing ZZ = Integer Ring

Function Details

QuaternionAlgebra(K, a, b, c=0)

Returns the quaternion algebra over the field K with generators
i and j and the following relations:

            i^2 = a
            j^2 = b
            i*j + j*i = c
            
A third generator is set to k = i*j.   


INPUT:
    K -- field
    a -- nonzero element of K
    b -- nonzero element of K
    b -- element of K

EXAMPLES:

We create quaternion algebras over several base fields.

    >>> QuaternionAlgebra(RationalField(), -1, -7)
    Quaternion Algebra over Rational Field

    >>> QuaternionAlgebra(NumberField(x**2-5), -1, -7)
    Quaternion Algebra over Number Field with defining polynomial x^2 - 5

    >>> QuaternionAlgebra(GF(3), -1, -7)
    Quaternion Algebra over Finite field of size 3

Note that both a and b must be nonzero:

    >>> QuaternionAlgebra(RationalField(), 1, 0)
    Traceback (most recent call last):
    ...
    ArithmeticError: Both i^2 (=1) and j^2 (=0) must be nonzero.

    >>> QuaternionAlgebra(GF(7), -1, -7)
    Traceback (most recent call last):
    ...
    ArithmeticError: Both i^2 (=6) and j^2 (=0) must be nonzero.

Note that K must be a field.  This is because we represent
elements of the quaternion algebra as vectors in a vector space,
and we support division.  Use the QuaternionOrder_... commands.

     >>> QuaternionAlgebra(IntegerRing(), -1, -1)
     Traceback (most recent call last):
     ...
     TypeError: K (=Integer Ring) must be a field

QuaternionAlgebraWithDiscs(D1, D2, T)

The quaternion algebra over Q generated by i and j, where Z[i] and
Z[j] are quadratic suborders of discriminant D_1 and D_2,
respectively, and Z[ij - ji] is a quadratic suborder of
discriminant D_3 = D_1 D_2 - T^2.

INPUT:
    D1 -- int
    D2 -- int
    T -- int
    
    The integers D_1, D_2 and T must all be even or all odd, and
    D_1, D_2 and D_3 must each be the discriminant of some
    quadratic order, i.e. nonsquare integers = 0, 1 (mod 4).
    
OUTPUT:
    A quaternion algebra.

EXAMPLES:
    >>> A = QuaternionAlgebraWithDiscs(-7,-47,1); A
    Quaternion Algebra over Rational Field
    >>> i, j, k = A.gens()
    >>> i**2
    -2 + i
    >>> j**2
    -12 + j
    >>> k**2
    -24 + k
    >>> i.minimal_polynomial()
    x^2 - x + 2
    >>> j.minimal_polynomial()
    x^2 - x + 12

THIS IS BROKEN:  (todo!!)
    >> k.minimal_polynomial()
    x^2 - x + 24
    >>> i*j
    k

Variable Details

QQ

Type:
RationalField
Value:
Rational Field                                                         

ZZ

Type:
IntegerRing
Value:
Integer Ring                                                           

Generated by Epydoc 2.1 on Mon May 9 17:57:03 2005 http://epydoc.sf.net