Source: https://www2.humusoft.cz/www/papers/tcp06/beranek.pdf