Controlled Markovian dynamics of graphs: unbiased generation of random   graphs with prescribed topological properties
  We analyze the properties of degree-preserving Markov chains based on elementary edge switchings in undirected and directed graphs. We give exact yet simple formulas for the mobility of a graph (the number of possible moves) in terms of its adjacency matrix. This formula allows us to define acceptance probabilities for edge switchings, such that the Markov chains become controlled Glauber-type detailed balance processes, designed to evolve to any required invariant measure (representing the asymptotic frequencies with which the allowed graphs are visited during the process). 
E. S. Roberts, A. Annibale and A. C. C. Coolen
cond-mat.dis-nn