### 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 ~~matrix (or equivalently graph) ~~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 help