> < ^ Date: Wed, 24 Nov 1999 18:45:07 GMT
> < ^ From: Willem de Graaf <degraaf@math.uu.nl >
> < ^ Subject: Re: Semidirectproduct

Dear Jan,

You asked about semidirect products of Lie algebras in GAP.
At the moment a function for constructing those does not exist.
However, below is some code for this. If you encounter difficulties
with it, then please ask.

Best wishes,

Willem

sem_dir_prod:= function( L, hom, rad )

# here `hom' is a homomorphsim from `L' into `Der( rad )'.
# We assume that `hom( x )' is a matrix
# and that the columns of `hom( x )' contain the coefficients of
# the images of the basis vectors of `rad'.
# The function returns the semidirect product of `L' and `rad',
# where the action of `L' on `rad' is given by `hom'.

local   d,  n,  T,  B,  i,  j,  cf,  c,  k,  td, dlist, S;    

dlist:= List( Basis(L), x -> Image( hom, x ) );
d:= Length( dlist );
n:= Length( dlist ) + Dimension( rad );
F:= LeftActingDomain( L );
T:= EmptySCTable( n, Zero(F), "antisymmetric" );
S:= StructureConstantsTable( Basis( L ) );
B:= Basis( VectorSpace( Rationals, dlist ), dlist );

for i in [1..d] do
    for j in [1..d] do
       T[i][j]:= S[i][j];            
    od;
od;

td:= List( dlist, TransposedMat );
for i in [1..d] do
    for j in [1..Dimension( rad ) ] do
        cf:= td[i][j];
        c:=[];
        for k in [1..Length(cf)] do
            if cf[k] <> 0 then
                Add( c, cf[k] ); Add( c, k+d );
            fi;
        od;
        SetEntrySCTable( T, i, j+d, c );
    od;
od;

B:= Basis( rad );
for i in [1..Dimension(rad)] do
    for j in [i+1..Dimension(rad)] do
        cf:= Coefficients( B, B[i]*B[j] );
        c:=[];
        for k in [1..Length(cf)] do
            if cf[k] <> 0 then
                Add( c, cf[k] ); Add( c, k+d );
            fi;
        od;
        SetEntrySCTable( T, i+d, j+d, c );
    od;
od;

return LieAlgebraByStructureConstants( F, T );
end;

Miles-Receive-Header: reply


> < [top]