3 years, 56 days

## Automate Lie Algebra Computaitons...

Maple

Howdy,

I am trying to do explicit Lie algebra computations, and I am not sure the best way to automate these.

Suppose I have a Lie algebra with basis e1 through e8, and I have some linear functions:

f(e1,e2) = c1e1+c2e2+...+c8e8

Now suppose I want to compute something like

[e5, f] - f([e5,e1],e2) + f([e5,e2],e1), or more generally x.f with the typical module structure.

I can do this line by line - say [e5,e1] = -e1 and [e5,e2] = 0, then I can ask Maple for LieBracket(e5,f)+f(e1,e2)-0. However, I'd like to make an operator that does this for me. Can anyone please point me in the right direction?

Thanks!

## Lie algebra deformation question...

Maple

Hi,

I am having trouble with a Lie algebra cohomology computation. Suppose I have a poset on {1,2,3,4} where 1 < 3, 1 < 4, 2 < 3, and 2 < 4. I can express this as a matrix:

* 0 * *
0 * * *
0 0 * 0
0 0 0 *

where *'s mean "any entry in my ground field," say R or C, and 0s are 0s. Basically, if there is a relation between row i and column j, there is a *. This is why there is a * in row-1 and column 3, as 1<3, but a 0 in row-1 and column 2. I can make the collection of all of these matrices into a Lie algebra using the commutator, as it is closed, and can further suppose it is of trace 0 - that is, it is Type A.

My question is this: I know this algebra has non-trivial cohology, and deforms. However, I want to make Maple do this for me, so I can try it on bigger algebras - however it always tells me that the cohomology is dead zero. What am I doing wrong? My approach is this:

Let P equal the following collection of matrices - these form my basis:

Now I can run the basic commands to get started:

DGsetup(L);

I can now go straight to cohomology. If my algebra is named L, then I want to build my cochain complex C^*(L, L):

c := RelativeChains([e1,e2,e3,e4,e5,e6,e7]);

However, the answer is always that there are no non-trivial cochains: the answer is [[], []]. This will make it very difficult to have non-trivial cohomology.

I know this isn't true (see https://arxiv.org/pdf/1407.0428.pdf). I also tried the approach in the Maple documentation, where I work in the adjoint representation. This gave me non-trivial cochains, but the cohomolgy was 0.

Does anyone know what I'm doing wrong?

Thanks!

Maple

Howdy,

I am trying to understand various approaches to threading in Maple. I can naturally parallelize some computations, but only if I can figure out threading. The punchline is this - running something on a single core takes significantly longer when I break it into threads.

I picked a command that takes some time - suppose I have a Lie algebra G, and I want to know if H is a subalgebra. If I do this 16 times in a row, it takes about 3 seconds consistently. Here I made an array of 16 copies of H. Then I can simply ask which element is a subalgebra:

```is_subalgebra:=proc(list_of_algs) local i; for i in list_of algs do Query(i, "Subalgebra"); end do; end proc;```

```st := time(); is_subalgebra(my_list); time() - st;```

Suppose I want to run this on cores = 4 or 5 or...

`are_subalgebras_t := proc(list, cores)`

```local ...., mutex, threadlist; threadlist:= []; mutex := Threads[Mutex][Create](); <create cores chunks of list, call it sublist> for i in sublist do  Threads[Mutex][Lock](mutex);  threadlist:= [op(ts), Create(are_subalgebra(i))];  Threads[Mutex][Unlock](mutex); end do; Wait(op(threadlist)); return; end proc:```

The unecessary code is removed, but I:

1: Create a mutex

2: Chunk up my list into as many pieces as I want

3: Lock my mutex

4: Spawn a thread on the current chunk, save the thread id in a list

5: Unlock the mutex (I just want to add thread ids to my list safely)

6: Repeat 3-5 for each chunk

7: Wait until all threads are done

My machine has 16 cores, and if I run this on say 8 cores it takes almost 10 seconds. I can see that it starts executing the threads immediately - an example run shows I might spawn two threads, then the first thread starts, the third spawns, and then they complete in some order. Predictably, every run through is different. This tells me that I am getting parallelization, but at the detriment of runtime.

Can anyone tell me where my approach is going wrong? I was unable to get any Map functions to work at all.

Thanks!