Statistical Mechanics and Stochastic Geometry