What is this group, $A_n = \langle a_1,\ldots a_n \,|\, a_i a_j = a_ja_i \mbox{ if } |i-j| \geq 2\rangle$? I came across the group with a presentation $A_n = \langle a_1,\ldots a_n \,|\, a_i a_j = a_ja_i \mbox{ if } |i-j| >= 2\rangle$. E.g. $A_1$ and $A_2$ are free groups. Do these groups have a name or are they special cases of some classes of groups? I would like to know as much as possible about it. It's somehow connected to the symmetric group I guess. 
 A: I'll add my comment above as an answer and include some context, incorporating others' comments.
Given an undirected graph $\Gamma$, the group $A(\Gamma)$ is defined by the presentation 
$$ \langle v \in V(\Gamma) \mid vw = wv \text{ for each } vw \in E(\Gamma) \rangle, $$
where $V(\Gamma)$ and $E(\Gamma)$ are the vertex and edge sets and $vw$ denotes an edge with end vertices $v$ and $w$.  A group admitting such a presentation for some such graph is known by any of the following names: right-angled Artin group (RAAG), graph group, partially commutative group, free partially commutative group.
The group in the OP's question is a graph group.  More precisely, we can identify the underlying graph as follows.
Let $P_n$ be the path graph on $n$ vertices: $V(P_n) = \{1, \dots, n\}$ and $E(P_n) = \{ ij \mid |i-j| = 1\}$.  Let $\overline{P_n}$ be the opposite (or complement) graph of $P_n$.  This means that $V(\overline{P_n}) = V(P_n)$ and $E(\overline{P_n}) = \{ij \mid |i-j| \neq 1\}$.
Comparing the presentations, we see that $A(\overline{P_n})$ is the group in the original post.
Of possible interest: a graph which defines a graph group is intrinsic to the group.  What I mean is that if $A(\Gamma_1) \cong A(\Gamma_2)$, then $\Gamma_1 \cong \Gamma_2$.  So, in principal, everything one might want to know about the group is encoded in the graph and vice versa.  This statement was proved by Droms.  This also follows from the work of Kim, Makar-Limanov, Neggers, and Roush on graph algebras, the group algebra (over some field) of a graph group.
If one adds the relations $v^2=1$ for each $v \in V(\Gamma)$, then the resulting presentation defines (by definition) a right-angled Coxeter group $W(\Gamma)$.  Symmetric groups are Coxeter groups, but they are not right-angled Coxeter groups.  So, the OP's group is not related to a symmetric group in any direct way.  The group $W(\overline{P_n})$ is infinite for $n \geq 5$ and seems to be as difficult to analyze as the original group $A(\overline{P_n})$.
