Principles of Statistical Physics and Numerical Modeling