Posts

Showing posts from January, 2025

Welcome to my website!

 This is intended to be somewhat of an informal CV/portfolio for me. In the posts, you will find updates on my work, along with some GAP coding work.

GAP: Function to iterate through Coxeter monoids to test which produce a finite Origami monoid

  # the function will try each monoid for arg4 seconds before moving on to the next. The relevant function is TestCoxeterOrigami NumberCombos:=function(m,n,lists,iteration) local i,j,list,list2,lists2; lists2:=[]; if iteration<m+1 then if lists=[] then for i in [0..n] do Add(lists2,[i]); od; else for list in lists do for i in [0..3] do list2:=ShallowCopy(list); Add(list2,Random([0..n])); Add(lists2, list2); od; od; fi; else return lists; fi; j:=iteration+1; return NumberCombos(m,n,lists2,j); end; CreateCoxeterInput := function(numGenerators, n, p) local generators, inputs, a, b, c, d, i, j, k, y, z, blank, range, ranges, pos, rel, numlists, blanker, numbers; # Generate generator names generators := List([1..numGenerators], i -> Concatenation("g", String(i))); # Create relations blank := []; for a in generators do for b in generators do if not a=b then rel:=[a,,b]; Add(blank,rel); fi; ...

GAP: Function to create Origami monoid of given finitely presented monoid with all idempotent generators

Mapper:=function(word,arg) local i, u, v, w, prod, monoid; w:=ExtRepOfObj(word); prod:=[]; if IsMonoid(arg) then monoid:=arg; for i in [1..(Length(w)/2)] do u:=monoid.(w[2*i-1])^(w[2*i]); Add(prod, u); od; elif IsSemigroup(arg) then monoid:=arg; for i in [1..(Length(w)/2)] do u:=monoid.(w[2*i-1])^(w[2*i]); Add(prod, u); od; else for i in [1..(Length(w)/2)] do u:=arg[(w[2*i-1])]^(w[2*i]); Add(prod, u); od; fi; v:=Product(prod); return v; end; OrigamiMonoidIdemp:=function(monoid) local gens, mgens, rels, newrels, mrels, agens, bgens, arels, brels, abgens, bagens, doublegens, doublerels, w, free, left, right, abrels, barels, M, rws, freeaddrules, creatingrules, i, j, n, generatorMap, fgens, pos, gens0, mapped, commrels; # Step 0: Check if M is a finitely presented monoid if not IsFpMonoid(monoid) then Print("Not a monoid. \n"); return fail; fi; gens:=[]; for i in [1..Size(GeneratorsOfMonoid(monoid))] do Add(gens...

GAP: Alternate function to create finitely presented Coxeter monoid of a given Coxeter matrix

  CoxeterMonoid:=function(D) # takes lists of relations of the form ["x",m,"y"] where x,y are generators and n is pos. int. local gens, rels, i, j, k, fm, f, n; gens := []; rels := []; # Collect generators from input D for i in D do Add(gens, i[1]); Add(gens, i[3]); od; gens := Set(gens); # Ensure gens contains unique elements fm := FreeMonoid(gens); # Construct relations based on triples in input D for i in D do j := Position(gens, i[1]); k := Position(gens, i[3]); n:=Int((i[2])/2); # Add matrix relations if n=i[2]/2 then Add(rels, [(fm.(k) * fm.(j))^(n), (fm.(j) * fm.(k))^(n)]); else Add(rels, [(fm.(k) * fm.(j))^(n)*fm.(k), (fm.(j) * fm.(k))^(n)*fm.(j)]); fi; # Add idempotence relations Add(rels, [fm.(j)^2,fm.(j)]); Add(rels, [fm.(k)^2,fm.(k)]); od; rels:=Set(rels); # Define finitely presented monoid with relations f := fm / rels; ...