  Using a maximum entropy principle to assign a statistical weight to any
graph, we introduce a model of random graphs with arbitrary degree distribution
in the framework of standard statistical mechanics. We compute the free energy
and the distribution of connected components. We determine the size of the
percolation cluster above the percolation threshold. The conditional degree
distribution on the percolation cluster is also given. We briefly present the
analogous discussion for oriented graphs, giving for example the percolation
criterion.
