This is a question, or really more like a cloud of questions, I wanted to ask awhile ago based on [this SBS post](http://sbseminar.wordpress.com/2008/09/10/a-curious-speculation/) and [this post I wrote](http://qchu.wordpress.com/2009/06/07/the-catalan-numbers-regular-languages-and-orthogonal-polynomials/) inspired by it, except that Math Overflow didn't exist then. 


As the SBS post describes, the Catalan numbers can be obtained as the moments of the trace of a random element of $SU(2)$ with respect to the Haar measure. This is equivalent to the integral identity
$$\int\_{0}^{1} (2 \cos \pi x)^{2k} (2 \sin^2 \pi x) \, dx = C\_k.$$


I can prove this identity "combinatorially" as follows: let $A\_n$ denote the Dynkin diagram with $n$ vertices and $n-1$ undirected edges connecting those vertices in sequence. The adjacency matrix of $A\_n$ has eigenvectors $\mathbf{v}\\_i$ with entries $\mathbf{v}\\_{i,j} = \sin \frac{\pi ij}{n+1}$ with corresponding eigenvalues $2 \cos \frac{\pi i}{n+1}$. If $k \le n-1$, then a straightforward computation shows that the number of closed walks from one end of $A\_n$ to itself of length $2k$ is
$$\frac{1}{n+1} \sum\_{i=1}^{n} \left( 2 \cos \frac{\pi i}{n+1} \right)^{2k} 2 \sin^2 \frac{\pi}{n+1} = C\_k$$


by the combinatorial definition of the Catalan numbers. Taking the limit as $n \to \infty$ gives the integral identity; in other words, the integral identity is in some sense equivalent to the combinatorial definition of the Catalan numbers in terms of closed walks on the "infinite path graph" $A\_{\infty}$. (Is this the correct notation? I mean the infinite path graph with one end.)


Now, closed walks of length $2k$ from one end of $A\_n$ to itself can be put in bijection with **ordered rooted trees** of depth at most $n$ and $k$ non-root vertices. (Recall that the Catalan numbers also count ordered rooted trees of arbitrary depth.) The generating function $P\_n$ of ordered rooted trees of depth at most $n$ satisfies the recursion
$$P\_1(x) = 1, P\_n(x) = \frac{1}{1 - x P\_{n-1}(x)}.$$


This is because an ordered rooted tree of depth $n$ is the same thing as a sequence of ordered rooted trees of depth $n-1$ together with a new root. (Recall that the generating function of the Catalan numbers satisfies $C(x) = \frac{1}{1 - x C(x)}$. In other words, $C(x)$ has a continued fraction representation, and $P\_n$ is its sequence of convergents.) On the other hand, since $P\_n(x)$ counts walks on the graph $A\_n$, it is possible to write down the generating function $P\_n$ explicitly in terms of the characteristic polynomials of the corresponding adjacency matrices, and these polynomials have roots the eigenvalues $2 \cos \frac{\pi i}{n+1}$. This implies that they must be the **Chebyshev polynomials** of the second kind, i.e. the ones satisfying
$$q\_n(2 \cos x) = \frac{\sin (n+1) x}{\sin x}.$$


But the Chebyshev polynomials of the second kind are none other than the characters of the irreducible finite-dimensional representations of $SU(2)$! In particular, they're orthogonal with respect to the Haar measure. 


The overarching question I have is: *how does this sequence of computations generalize, and what conceptual framework ties it together?* But I should probably ask more specific sub-questions.


**Question 1:** I remember hearing that the relationship between the Catalan numbers and the Chebyshev polynomials generalizes to some relation between moments, continued fractions, and orthogonal polynomials with respect to some measure. Where can I find a good reference for this? 


**Question 2:** I believe that adding another edge and considering the family of cycle graphs gives the sequence ${2k \choose k}$ and the Chebyshev polynomials of the **first** kind, both of which are related to $SO(2)$. According to the SBS post, this is a "type B" phenomenon, whereas the Catalan numbers are "type A." What exactly does this mean? What would happen if I repeated the above computations for other Dynkin diagrams? Do I get continued fractions for the other infinite families? 


**Question 3:** Related to the above, in what sense is it natural to relate walks on the Dynkin diagram $A\_n$ to representations of $SU(2)$? This seems to have something to do with [question #16026](https://mathoverflow.net/questions/16026/the-finite-subgroups-of-sl2-c). How do the eigenvectors of the adjacency matrices fit into the picture? I want to think of the eigenvectors as "discrete harmonics"; does this point of view make sense? Does it generalize?


As you can see, I'm very confused, so I would greatly appreciate any clarification.



How does this relationship between the Catalan numbers and SU(2) generalize?
The Catalan numbers enumerate (amongst everything else!) the bases of the Temperley-Lieb algebras. These algebras $TL\_n(q)$ are exactly $\operatorname{End}\_{U\_q \mathfrak{su}\_2}(V^{\otimes n})$ where $V$ is the standard representation.


If $q$ is a $2k+4$-th root of unity, the semisimplified representation theory of $U\_q \mathfrak{su}\_2$ becomes '$A\_{k+1}$': that is, it has $k+1$ simples, and the principal graph for tensor product with the standart is $A\_{k+1}$. The algebra $\operatorname{End}\_{U\_q \mathfrak{su}\_2}(V^{\otimes n})$ is now smaller (some of the summands of the tensor power cancel out when you use the quantum Racah rule), and in fact it is enumerated by loops on $A\_{k+1}$ based at the first vertex. You can pick out a subset of the entire Temperley-Lieb that gives a basis: just use your description of paths as trees, and take the dual graph.


Since we're looking at a unitary tensor category, the dimension of the standard object is exactly the Frobenius-Perron eigenvalue (largest real eigenvalue of the adjacency matrix) of the principal graph.


