# Building Root Data

## `sub<R | a>: RootDtm, SetEnum -> RootDtm`

The root subdatum of the root datum $R$ generated by the roots $\alpha_{a_1},\dots,\alpha_{a_k}$ where $a=\{a_1,\dots,a_k\}$ is a set of integers.

## `sub<R | s>: RootDtm, SetEnum -> RootDtm`

The root subdatum of the root datum $R$ generated by the roots $\alpha_{s_1},\dots,\alpha_{s_k}$ where $s=[s_1,\dots,s_k]$ is a *sequence* of integers. In this version the roots must be simple in the root subdatum (i.e. none of them may be a summand of another) otherwise an error is signalled. The simple roots will appear in the subdatum in the given order.

## `Example: Root Subdata (ex-dc9697)`

```magma
> R := RootDatum("A4");
> PositiveRoots(R);
{@
    (1 0 0 0),
    (0 1 0 0),
    (0 0 1 0),
    (0 0 0 1),
    (1 1 0 0),
    (0 1 1 0),
    (0 0 1 1),
    (1 1 1 0),
    (0 1 1 1),
    (1 1 1 1)
@}
> s := sub< R | [6,1,4] >;
> s;
Root datum of type A3
> PositiveRoots(s);
{@
    (0 1 1 0),
    (1 0 0 0),
    (0 0 0 1),
    (1 1 1 0),
    (0 1 1 1),
    (1 1 1 1)
@}
> s := sub< R | [1,5] >;
Error: The given roots are not simple in a subdatum
> s := sub< R | {1,5} >;
> s;
Root datum of type A2
> PositiveRoots(s);
{@
    (1 0 0 0),
    (0 1 0 0),
    (1 1 0 0)
@}

```

## `R1 subset R2: RootDtm, RootDtm -> BoolElt, .`

Returns `true` if and only if the root datum $R_1$ is a subset of the root datum $R_2$. If true, returns an injection as sequence of roots as second return value.

## `R1 + R2: RootDtm, RootDtm -> RootDtm`

## `DirectSum(R1, R2): RootDtm, RootDtm -> RootDtm`

The external direct sum of the root data $R_1$ and $R_2$. The full (co)root space of the result is the direct sum of the full (co)root spaces of $R_1$ and $R_2$.

## `R1 join R2: RootDtm, RootDtm -> RootDtm`

The internal direct sum of the root data $R_1$ and $R_2$. The root data must have the same full (co)root space, which will also be the full (co)root space of the result. The root data must have disjoint (co)root spaces.

## `Example: Root Dtm Sums (ex-67182b)`

```magma
> R  := RootDatum("A1A1");
> R1 := sub<R|[1]>;
> R2 := sub<R|[2]>;
> R1 + R2;
Root datum of dimension 4 of type A1 A1
> R1 join R2;
R: Adjoint root datum of dimension 2 of type A1 A1

```

## `DirectSumDecomposition(R): RootDtm -> [], RootDtm, Map`

## `IndecomposableSummands(R): RootDtm -> [], RootDtm, Map`

Returns a sequence $Q$ of irreducible root data, a root datum $S$ which is the direct sum of the terms of $Q$, and an isogeny map $\phi:S\to R$. The root datum $R$ must be semisimple. Note that a semisimple root datum $R$ need not be a direct sum of simple root data, but it is isogenous to a direct sum of root data $S$.

## `Example: Root Dtm Decomp (ex-7e44ad)`

If the root datum in adjoint or simply connected, then it is a direct sum of simples. In this case we get $S=R$.

```magma
> R := RootDatum("A4B5" : Isogeny:="SC");
> Q, S := DirectSumDecomposition( R );
> R eq S;
true
> R eq Q[1] join Q[2];
true

```

The join of the summands of the direct sum decomposition is the original root datum again:

```magma
> R eq &join DirectSumDecomposition(R);
true
> R eq &+    DirectSumDecomposition(R);
false

```

```magma
> R1 := RootDatum("A3T2B4T3");
> R2 := RootDatum("T3G2T4BC3");
> R1 + R2;
Adjoint root datum of dimension 24 of type A3 B4 G2 BC3
> R1 join R2;
Root datum of dimension 12 of type A3 B4 G2 BC3

```

Here is an example of a semisimple root datum which is not a direct sum of simple subdata. Note that a simple root datum of type $A_1$ is either simply connected or adjoint.

```magma
> G<a,b>:=FundamentalGroup("A1A1");
> _,inj:=sub<G|a*b>;
> R:=RootDatum("A1A1":Isogeny:=inj);
> ad := RootDatum( "A1" : Isogeny:="Ad" );
> sc := RootDatum( "A1" : Isogeny:="SC" );
> IsIsomorphic( R, DirectSum(ad,ad) );
false
> IsIsomorphic( R, DirectSum(ad,sc) );
false
> IsIsomorphic( R, DirectSum(sc,sc) );
false
> Q, S := DirectSumDecomposition( R );
> R eq S;
false

```

## `Dual(R): RootDtm -> RootDtm, Map`

The dual of the root datum $R$, obtained by swapping the roots and coroots. The second value returned is the dual morphism from $R$ to its dual.

## `SimplyConnectedVersion(R): RootDtm -> RootDtm, Map`

The simply connected version of the root datum $R$. If $R$ is semisimple then the injection of the simply connected version into $R$ is returned as the second value.

## `AdjointVersion(R): RootDtm -> RootDtm, Map`

The adjoint version of the root datum $R$. If $R$ is semisimple then the projection from $R$ to its adjoint version is returned as the second value.

## `IndivisibleSubdatum(R): RootDtm -> RootDtm`

The root datum consisting of all indivisible roots of the root datum $R$.

## `Radical(R): RootDtm -> RootDtm`

The radical of the root datum $R$, ie, the toral subdatum whose root (resp. coroot) space consists of the vectors perpendicular to every coroot (resp. root).

## `Example: Direct Sum Dual Radical (ex-187258)`

An adjoint or simply connected root datum is always a direct sum of irreducible subdata. In these cases we take $S=R$.

```magma
> R1 := RootDatum("A5");
> R2 := RootDatum("B4");
> R := DirectSum(R1, Dual(R2));
> DirectSumDecomposition(R);
{
    Root datum of type A5 ,
    Root datum of type C4
}

```

```magma
> R := RootDatum("BC2");
> I := IndivisibleSubdatum(R); I;
I: Root datum of type B2
> I subset R;
true [ 1, 2, 3, 5, 7, 8, 9, 11 ]

```

```magma
> R := StandardRootDatum("A", 3);
> Radical(R);
Toral root datum of dimension 1

```

## `TwistedRootDatum(R): RootDtm -> RootDtm`

## `TwistedRootDatum(N): MonStgElt -> RootDtm`

```magma
Twist: Any                    Default: 1
```

Create a twisted root datum from the root datum $R$, or from the semisimple root datum with Cartan name $N$. The twist may be specified in any of the following ways:

- An integer, specifying the order of the twist;

- A permutation, specifying the action of the primitive roots;

- A pair $<D, i>$, where $D$ is a set of distinguished orbits as sets of integers, and $i$ is the order of the Dynkin diagram symmetry;

- A pair $<\Gamma, Q>$, where $\Gamma$ is the acting group, and $Q$ is a sequence containing the permutation of the primitive roots for each of the generators of $\Gamma$;

- A homomorphism from $\Gamma$ to the symmetric group whose order is the number of roots of $R$, describing how the acting group $\Gamma$ acts on the roots.

## `Example: Direct Sum Dual Radical (ex-4dc407)`

We construct a twisted root datum in a number of ways.

```magma
> S := TwistedRootDatum("D4" : Twist := 3);
> S;
S: Twisted adjoint root datum of dimension 4 of type 3D4,2

> R := RootDatum("A1A3");
> DynkinDiagram(R);

A1    1

A3    2 - 3 - 4
> S := TwistedRootDatum(R : Twist := Sym(4)!(2,4));
> S;
S: Twisted adjoint root datum of dimension 4 of type 2(A1 A3)4,3

> S := TwistedRootDatum("A4" : Twist := <{{1,4},{2,3}}, 2>);
> S;
S: Twisted adjoint root datum of dimension 4 of type 2A4,2

> R := RootDatum("E6" : Isogeny := "SC");
> DynkinDiagram(R);

E6    1 - 3 - 4 - 5 - 6
              |
              2
> S := TwistedRootDatum(R : Twist := <Sym(2) ,[ Sym(6)!(1,6)(3,5) ]>);
> S;
S: Twisted simply connected root datum of dimension 6 of type 2E6,4

> R := RootDatum("D4");
> DynkinDiagram(R);

D4    3
     /
1 - 2
     \\
      4
> Gamma := Sym(3);
> Gamma.1, Gamma.2;
(1, 2, 3)
(1, 2)
> S := TwistedRootDatum(R : Twist := <Gamma, [ Sym(4) | (1,3,4), (1,4) ]>);
> S;
S: Twisted adjoint root datum of dimension 4 of type 6D4,2

> R := RootDatum("A2");
> DynkinDiagram(R);

A2    1 - 2
> Roots(R);
{@
    (1 0),
    (0 1),
    (1 1),
    (-1  0),
    ( 0 -1),
    (-1 -1)
@}
> S6 := Sym(#Roots(R));
> phi := hom<Sym(2) -> S6 | S6!(1,2)(4,5)>;
> S := TwistedRootDatum(R : Twist := phi);

```

## `UntwistedRootDatum(R): RootDtm -> RootDtm`

## `SplitRootDatum(R): RootDtm -> RootDtm`

The split version of the (twisted) root datum $R$.
