# ApCoCoA-1:Quaternion group

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

### Quaternion group

#### Description

This particular group is non-abelian with the order 8. The Quaternion group Q has a special property: it is Hamiltonian, that means that every subgroup of Q is a normal subgroup. An efficient representation with generators and relations is given by:

``` Q_8 = <a,b | a^4 = 1, a^2 = b^2, b^{-1}ab = a^{-1}>
```

#### Reference

P.R. Girard (1984), "The quaternion group and modern physics", European Journal of Physics 5:25–32.

Coxeter, H. S. M. and Moser, W. O. J. (1980), Generators and Relations for Discrete Groups. New York: Springer-Verlag

#### Computation

``` /*Use the ApCoCoA package ncpoly.*/

Use ZZ/(2)[x,y];
NC.SetOrdering("LLEX");

Define CreateRelationsQuaternion()
Relations:=[];
// add the relation  x^4 = 1
Append(Relations,[[x^4],]);

// add the relation x^2 = y^2
Append(Relations,[[x^2],[y^2]]);

// add the relation y^{-1}xy = x^{-1}
Append(Relations,[[y^3,x,y],[x^3]]);

Return Relations;
EndDefine;

Relations:=CreateRelationsQuaternion();
Gb:=NC.GB(Relations);
Gb;
```