ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Fri, 11 Jun 2021 22:36:56 +0200Finding generalised braid relations for finite Coxeter groups with Sagehttps://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/Let $S=\{x1,...,xn \}$ be a finite set and $A=(a_{xs,xt})$ a symmetric matrix, called Coxeter matrix, with $a_{xs,xs}=1$ and $a_{xs,xt} \in \{2,3,...,\infty \}$ for $xs \neq xt$.
To A one associates the graph $R_A$ with vertices the elements of $S$ and there is a unique edge between $xs $ and $xt$ whenever $a_{xs,xt} \geq 3$. The edge is between $xs$ and $xt$ is labeled by $a_{xs,xt}$ whenever $a_{xs,xt} \geq 4$.
To such a coxeter matrix A (or equivalently the graph) we associate the generalized braid group that is defined as the group with generators $x1,...,xn$ and relations of the form $xs * xt *xs....=xt * xs *xt....$ where there appear $a_{xs,xt}$ factors.
>Question: Given a Coxeter graph of Dynkin type. How can I obtain the relations of the braid group with Sage? I think there should be existing function to do this but I was not able to do it.
For example for the Dynkin type $A_3$ the output should look as follows:
[x1*x3-x3*x1,x1*x2*x1-x2*x1*x2,x2*x3*x2-x3*x2*x3].
(note that the output should be really in this form (so that the variables are called xi and there is a * inbetween) to make it readable for another program)
Thank you for any helpFri, 11 Jun 2021 14:21:06 +0200https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/Comment by tkarn for <p>Let $S={x1,...,xn }$ be a finite set and $A=(a_{xs,xt})$ a symmetric matrix, called Coxeter matrix, with $a_{xs,xs}=1$ and $a_{xs,xt} \in {2,3,...,\infty }$ for $xs \neq xt$.
To A one associates the graph $R_A$ with vertices the elements of $S$ and there is a unique edge between $xs $ and $xt$ whenever $a_{xs,xt} \geq 3$. The edge is between $xs$ and $xt$ is labeled by $a_{xs,xt}$ whenever $a_{xs,xt} \geq 4$.</p>
<p>To such a coxeter matrix A (or equivalently the graph) we associate the generalized braid group that is defined as the group with generators $x1,...,xn$ and relations of the form $xs * xt *xs....=xt * xs *xt....$ where there appear $a_{xs,xt}$ factors.</p>
<blockquote>
<p>Question: Given a Coxeter graph of Dynkin type. How can I obtain the relations of the braid group with Sage? I think there should be existing function to do this but I was not able to do it.</p>
</blockquote>
<p>For example for the Dynkin type $A_3$ the output should look as follows:</p>
<pre><code>[x1*x3-x3*x1,x1*x2*x1-x2*x1*x2,x2*x3*x2-x3*x2*x3].
</code></pre>
<p>(note that the output should be really in this form (so that the variables are called xi and there is a * inbetween) to make it readable for another program)</p>
<p>Thank you for any help</p>
https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/?comment=57550#post-id-57550[This link might also help](https://ask.sagemath.org/question/43599/what-is-a-coxetergroup/)Fri, 11 Jun 2021 22:36:56 +0200https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/?comment=57550#post-id-57550Comment by tkarn for <p>Let $S={x1,...,xn }$ be a finite set and $A=(a_{xs,xt})$ a symmetric matrix, called Coxeter matrix, with $a_{xs,xs}=1$ and $a_{xs,xt} \in {2,3,...,\infty }$ for $xs \neq xt$.
To A one associates the graph $R_A$ with vertices the elements of $S$ and there is a unique edge between $xs $ and $xt$ whenever $a_{xs,xt} \geq 3$. The edge is between $xs$ and $xt$ is labeled by $a_{xs,xt}$ whenever $a_{xs,xt} \geq 4$.</p>
<p>To such a coxeter matrix A (or equivalently the graph) we associate the generalized braid group that is defined as the group with generators $x1,...,xn$ and relations of the form $xs * xt *xs....=xt * xs *xt....$ where there appear $a_{xs,xt}$ factors.</p>
<blockquote>
<p>Question: Given a Coxeter graph of Dynkin type. How can I obtain the relations of the braid group with Sage? I think there should be existing function to do this but I was not able to do it.</p>
</blockquote>
<p>For example for the Dynkin type $A_3$ the output should look as follows:</p>
<pre><code>[x1*x3-x3*x1,x1*x2*x1-x2*x1*x2,x2*x3*x2-x3*x2*x3].
</code></pre>
<p>(note that the output should be really in this form (so that the variables are called xi and there is a * inbetween) to make it readable for another program)</p>
<p>Thank you for any help</p>
https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/?comment=57549#post-id-57549The first level of the list is each individual relation, and then the second level of the list is each term, so you should iterate over them. If a string is all you need, you might try using a list comprehension in conjunction with formatted strings. For example, you can get the list `['x_1', 'x_2', ..., 'x_5']` by `[f'x_{i}' for i in range(1,6)]`. Give that a try and post again if you need any help.
As for your second question, the `.braid_relations()` method is part of the `CoxeterGroup` category in Sage, so it should work for any Coxeter group, although I have not verified that myself.Fri, 11 Jun 2021 22:35:24 +0200https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/?comment=57549#post-id-57549Comment by klaaa for <p>Let $S={x1,...,xn }$ be a finite set and $A=(a_{xs,xt})$ a symmetric matrix, called Coxeter matrix, with $a_{xs,xs}=1$ and $a_{xs,xt} \in {2,3,...,\infty }$ for $xs \neq xt$.
To A one associates the graph $R_A$ with vertices the elements of $S$ and there is a unique edge between $xs $ and $xt$ whenever $a_{xs,xt} \geq 3$. The edge is between $xs$ and $xt$ is labeled by $a_{xs,xt}$ whenever $a_{xs,xt} \geq 4$.</p>
<p>To such a coxeter matrix A (or equivalently the graph) we associate the generalized braid group that is defined as the group with generators $x1,...,xn$ and relations of the form $xs * xt *xs....=xt * xs *xt....$ where there appear $a_{xs,xt}$ factors.</p>
<blockquote>
<p>Question: Given a Coxeter graph of Dynkin type. How can I obtain the relations of the braid group with Sage? I think there should be existing function to do this but I was not able to do it.</p>
</blockquote>
<p>For example for the Dynkin type $A_3$ the output should look as follows:</p>
<pre><code>[x1*x3-x3*x1,x1*x2*x1-x2*x1*x2,x2*x3*x2-x3*x2*x3].
</code></pre>
<p>(note that the output should be really in this form (so that the variables are called xi and there is a * inbetween) to make it readable for another program)</p>
<p>Thank you for any help</p>
https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/?comment=57548#post-id-57548Another small question: In the link the example is only for Weyl groups but there are some other Coxeter graphs not corresponding to Weyl groups like H4. Do you know how to obtain the braid relations in that case?Fri, 11 Jun 2021 18:04:31 +0200https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/?comment=57548#post-id-57548Comment by klaaa for <p>Let $S={x1,...,xn }$ be a finite set and $A=(a_{xs,xt})$ a symmetric matrix, called Coxeter matrix, with $a_{xs,xs}=1$ and $a_{xs,xt} \in {2,3,...,\infty }$ for $xs \neq xt$.
To A one associates the graph $R_A$ with vertices the elements of $S$ and there is a unique edge between $xs $ and $xt$ whenever $a_{xs,xt} \geq 3$. The edge is between $xs$ and $xt$ is labeled by $a_{xs,xt}$ whenever $a_{xs,xt} \geq 4$.</p>
<p>To such a coxeter matrix A (or equivalently the graph) we associate the generalized braid group that is defined as the group with generators $x1,...,xn$ and relations of the form $xs * xt *xs....=xt * xs *xt....$ where there appear $a_{xs,xt}$ factors.</p>
<blockquote>
<p>Question: Given a Coxeter graph of Dynkin type. How can I obtain the relations of the braid group with Sage? I think there should be existing function to do this but I was not able to do it.</p>
</blockquote>
<p>For example for the Dynkin type $A_3$ the output should look as follows:</p>
<pre><code>[x1*x3-x3*x1,x1*x2*x1-x2*x1*x2,x2*x3*x2-x3*x2*x3].
</code></pre>
<p>(note that the output should be really in this form (so that the variables are called xi and there is a * inbetween) to make it readable for another program)</p>
<p>Thank you for any help</p>
https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/?comment=57547#post-id-57547Thank you for the comment. This looks like exactly like what is needed but instead of [1, 2, 1], [2, 1, 2] the output should be a string as in the example. So [[[1, 2, 1], [2, 1, 2]]] should be displayed as [x1 * x2 * x1 - x2* x1 *x2]. Is there an easy way to do this?Fri, 11 Jun 2021 16:53:32 +0200https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/?comment=57547#post-id-57547Comment by tkarn for <p>Let $S={x1,...,xn }$ be a finite set and $A=(a_{xs,xt})$ a symmetric matrix, called Coxeter matrix, with $a_{xs,xs}=1$ and $a_{xs,xt} \in {2,3,...,\infty }$ for $xs \neq xt$.
To A one associates the graph $R_A$ with vertices the elements of $S$ and there is a unique edge between $xs $ and $xt$ whenever $a_{xs,xt} \geq 3$. The edge is between $xs$ and $xt$ is labeled by $a_{xs,xt}$ whenever $a_{xs,xt} \geq 4$.</p>
<p>To such a coxeter matrix A (or equivalently the graph) we associate the generalized braid group that is defined as the group with generators $x1,...,xn$ and relations of the form $xs * xt *xs....=xt * xs *xt....$ where there appear $a_{xs,xt}$ factors.</p>
<blockquote>
<p>Question: Given a Coxeter graph of Dynkin type. How can I obtain the relations of the braid group with Sage? I think there should be existing function to do this but I was not able to do it.</p>
</blockquote>
<p>For example for the Dynkin type $A_3$ the output should look as follows:</p>
<pre><code>[x1*x3-x3*x1,x1*x2*x1-x2*x1*x2,x2*x3*x2-x3*x2*x3].
</code></pre>
<p>(note that the output should be really in this form (so that the variables are called xi and there is a * inbetween) to make it readable for another program)</p>
<p>Thank you for any help</p>
https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/?comment=57545#post-id-57545The relations can be found [here](https://doc.sagemath.org/html/en/reference/categories/sage/categories/coxeter_groups.html#sage.categories.coxeter_groups.CoxeterGroups.ParentMethods.braid_relations).
It gives the output as a list of the subscripts you want. What are you looking for from the output? Is a string ok, or do you really need it to be an element of the Coxeter group (`WeylGroup`) in Sage?Fri, 11 Jun 2021 16:31:14 +0200https://ask.sagemath.org/question/57543/finding-generalised-braid-relations-for-finite-coxeter-groups-with-sage/?comment=57545#post-id-57545