  We establish three identities involving Dyck paths and alternating Motzkin
paths, whose proofs are based on variants of the same bijection. We interpret
these identities in terms of closed random walks on the halfline. We explain
how these identities arise from combinatorial interpretations of certain
properties of the $\beta$-Hermite and $\beta$-Laguerre ensembles of random
matrix theory. We conclude by presenting two other identities obtained in the
same way, for which finding combinatorial proofs is an open problem.
